Blame view

3rdparty/boost_1_81_0/doc/html/conversion.html 7.39 KB
4b38bd9c   Hu Chunming   提交_GLIBCXX_USE_CX...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
  <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  <html>
  <head>
  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  <title>Chapter 9. The Conversion Library 1.7</title>
  <link rel="stylesheet" href="../../doc/src/boostbook.css" type="text/css">
  <meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
  <link rel="home" href="index.html" title="The Boost C++ Libraries BoostBook Documentation Subset">
  <link rel="up" href="libraries.html" title="Part I. The Boost C++ Libraries (BoostBook Subset)">
  <link rel="prev" href="container/release_notes.html" title="Release Notes">
  <link rel="next" href="conversion/polymorphic_casts.html" title="Polymorphic casts">
  </head>
  <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
  <table cellpadding="2" width="100%"><tr>
  <td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../boost.png"></td>
  <td align="center"><a href="../../index.html">Home</a></td>
  <td align="center"><a href="../../libs/libraries.htm">Libraries</a></td>
  <td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
  <td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
  <td align="center"><a href="../../more/index.htm">More</a></td>
  </tr></table>
  <hr>
  <div class="spirit-nav">
  <a accesskey="p" href="container/release_notes.html"><img src="../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="libraries.html"><img src="../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="conversion/polymorphic_casts.html"><img src="../../doc/src/images/next.png" alt="Next"></a>
  </div>
  <div class="chapter">
  <div class="titlepage"><div>
  <div><h2 class="title">
  <a name="conversion"></a>Chapter 9. The Conversion Library 1.7</h2></div>
  <div><div class="authorgroup">
  <div class="author"><h3 class="author">
  <span class="firstname">Bjarne</span> <span class="surname">Stroustrup</span>
  </h3></div>
  <div class="author"><h3 class="author">
  <span class="firstname">Dave</span> <span class="surname">Abrahams</span>
  </h3></div>
  <div class="author"><h3 class="author">
  <span class="firstname">Boris</span> <span class="surname">Rasin</span>
  </h3></div>
  <div class="author"><h3 class="author">
  <span class="firstname">Antony</span> <span class="surname">Polukhin</span>
  </h3></div>
  </div></div>
  <div><p class="copyright">Copyright © 2001 Beman Dawes</p></div>
  <div><p class="copyright">Copyright © 2014-2022 Antony
        Polukhin</p></div>
  <div><div class="legalnotice">
  <a name="conversion.legal"></a><p>
          Distributed under the Boost Software License, Version 1.0. (See accompanying
          file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
        </p>
  </div></div>
  </div></div>
  <div class="toc">
  <p><b>Table of Contents</b></p>
  <dl class="toc">
  <dt><span class="section"><a href="conversion.html#conversion.description">Description</a></span></dt>
  <dt><span class="section"><a href="conversion/polymorphic_casts.html">Polymorphic casts</a></span></dt>
  <dd><dl>
  <dt><span class="section"><a href="conversion/polymorphic_casts.html#conversion.polymorphic_casts.polymorphic_downcast">polymorphic_downcast</a></span></dt>
  <dt><span class="section"><a href="conversion/polymorphic_casts.html#conversion.polymorphic_casts.polymorphic_cast">polymorphic_cast</a></span></dt>
  <dt><span class="section"><a href="conversion/polymorphic_casts.html#conversion.polymorphic_casts.polymorphic_pointer_cast">polymorphic_pointer_cast</a></span></dt>
  </dl></dd>
  <dt><span class="section"><a href="conversion/synopsis.html">Synopsis</a></span></dt>
  <dt><span class="section"><a href="conversion/history.html">History</a></span></dt>
  </dl>
  </div>
  <div class="section">
  <div class="titlepage"><div><div><h2 class="title" style="clear: both">
  <a name="conversion.description"></a><a class="link" href="conversion.html#conversion.description" title="Description">Description</a>
  </h2></div></div></div>
  <p>
        The Conversion Library improves program safety and clarity by performing otherwise
        messy conversions. It includes cast-style function templates designed to complement
        the C++ Standard's built-in casts.
      </p>
  <p>
        To reduce coupling, particularly to standard library IOStreams, the Boost Conversion
        Library is supplied by several headers:
      </p>
  <div class="orderedlist"><ol class="orderedlist" type="1">
  <li class="listitem">
            The <a href="../../boost/polymorphic_cast.hpp" target="_top">boost/polymorphic_cast.hpp</a>
            header provides <a class="link" href="conversion/polymorphic_casts.html#polymorphic_cast"><code class="computeroutput"><span class="identifier">polymorphic_cast</span><span class="special">&lt;&gt;</span></code></a> and <a class="link" href="conversion/polymorphic_casts.html#polymorphic_downcast"><code class="computeroutput"><span class="identifier">polymorphic_downcast</span><span class="special">&lt;&gt;</span></code></a>
            to perform safe casting between polymorphic types.
          </li>
  <li class="listitem">
            The <a href="../../boost/polymorphic_pointer_cast.hpp" target="_top">boost/polymorphic_pointer_cast.hpp</a>
            header provides <a class="link" href="conversion/polymorphic_casts.html#polymorphic_pointer_cast"><code class="computeroutput"><span class="identifier">polymorphic_pointer_cast</span><span class="special">&lt;&gt;</span></code></a>
            and <a class="link" href="conversion/polymorphic_casts.html#polymorphic_pointer_cast"><code class="computeroutput"><span class="identifier">polymorphic_pointer_downcast</span><span class="special">&lt;&gt;</span></code></a>
          </li>
  <li class="listitem">
            The <a href="../../boost/implicit_cast.hpp" target="_top">boost/implicit_cast.hpp</a>
            header provides <code class="computeroutput"><span class="identifier">implicit_cast</span><span class="special">&lt;&gt;</span></code> to perform implicit casts only
            (no down-cast, no void*-&gt;T*, no U-&gt;T if T has only explicit constructors
            for U).
          </li>
  <li class="listitem">
            The <a href="../../boost/lexical_cast.hpp" target="_top">boost/lexical_cast.hpp</a>
            header provides <a href="../../doc/libs/release/libs/lexical_cast/" target="_top"><code class="computeroutput"><span class="identifier">lexical_cast</span><span class="special">&lt;&gt;</span></code></a>
            general literal text conversions, such as an <code class="computeroutput"><span class="keyword">int</span></code>
            represented as a <code class="computeroutput"><span class="identifier">string</span></code>,
            or vice-versa.
          </li>
  </ol></div>
  </div>
  </div>
  <table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
  <td align="left"></td>
  <td align="right"><div class="copyright-footer"></div></td>
  </tr></table>
  <hr>
  <div class="spirit-nav">
  <a accesskey="p" href="container/release_notes.html"><img src="../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="libraries.html"><img src="../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="conversion/polymorphic_casts.html"><img src="../../doc/src/images/next.png" alt="Next"></a>
  </div>
  </body>
  </html>