File: classSimpleDB_1_1StringColumn.html

package info (click to toggle)
simpledb 1.5-1.4
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k, lenny, squeeze
  • size: 888 kB
  • ctags: 238
  • sloc: cpp: 529; makefile: 127; perl: 23; sh: 9
file content (213 lines) | stat: -rw-r--r-- 10,791 bytes parent folder | download
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
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>Simple&amp;nbsp;C++&amp;nbsp;ODBC&amp;nbsp;Database&amp;nbsp;API: SimpleDB::StringColumn Class Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.4.2 -->
<div class="qindex"><a class="qindex" href="main.html">Main&nbsp;Page</a> | <a class="qindex" href="namespaces.html">Namespace List</a> | <a class="qindex" href="hierarchy.html">Class&nbsp;Hierarchy</a> | <a class="qindex" href="annotated.html">Class&nbsp;List</a> | <a class="qindex" href="files.html">File&nbsp;List</a> | <a class="qindex" href="functions.html">Class&nbsp;Members</a> | <a class="qindex" href="pages.html">Related&nbsp;Pages</a> | <a class="qindex" href="examples.html">Examples</a></div>
<div class="nav">
<a class="el" href="namespaceSimpleDB.html">SimpleDB</a>::<a class="el" href="classSimpleDB_1_1StringColumn.html">StringColumn</a></div>
<h1>SimpleDB::StringColumn Class Reference</h1>Class representing string values.  
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="Column_8h-source.html">Column.h</a>&gt;</code>
<p>
Inheritance diagram for SimpleDB::StringColumn:<p><center><img src="classSimpleDB_1_1StringColumn__inherit__graph.png" border="0" usemap="#SimpleDB_1_1StringColumn__inherit__map" alt="Inheritance graph"></center>
<map name="SimpleDB_1_1StringColumn__inherit__map">
<area href="classSimpleDB_1_1Column.html" shape="rect" coords="25,9,158,33" alt="">
</map>
<center><font size="2">[<a target="top" href="graph_legend.html">legend</a>]</font></center>Collaboration diagram for SimpleDB::StringColumn:<p><center><img src="classSimpleDB_1_1StringColumn__coll__graph.png" border="0" usemap="#SimpleDB_1_1StringColumn__coll__map" alt="Collaboration graph"></center>
<map name="SimpleDB_1_1StringColumn__coll__map">
<area href="classSimpleDB_1_1Column.html" shape="rect" coords="25,9,158,33" alt="">
</map>
<center><font size="2">[<a target="top" href="graph_legend.html">legend</a>]</font></center><a href="classSimpleDB_1_1StringColumn-members.html">List of all members.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classSimpleDB_1_1StringColumn.html#a0">StringColumn</a> (const int bufferSize)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Constructor to allocate memory for this column.  <a href="#a0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="a1" doxytag="SimpleDB::StringColumn::~StringColumn"></a>
&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classSimpleDB_1_1StringColumn.html#a1">~StringColumn</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Destructor frees allocated memory. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">std::ostream &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classSimpleDB_1_1StringColumn.html#a2">oStream</a> (std::ostream &amp;oStream)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Function called to write a column value to the output stream.  <a href="#a2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classSimpleDB_1_1StringColumn.html#a3">bind</a> (SQLHSTMT statementHandle, int columnNumber)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">This abstract function is called by <a class="el" href="classSimpleDB_1_1Query.html">Query</a> when the <a class="el" href="classSimpleDB_1_1Query.html#a2">Query.bind</a> function is invoked.  <a href="#a3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">std::string&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classSimpleDB_1_1StringColumn.html#a4">value</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the string value of this object.  <a href="#a4"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
Class representing string values. <dl compact><dt><b>Examples: </b></dt><dd>

<p>
<a class="el" href="complete_8cpp-example.html#_a1">complete.cpp</a>.</dl>
<p>
<hr><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" name="a0" doxytag="SimpleDB::StringColumn::StringColumn"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">SimpleDB::StringColumn::StringColumn           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">const int&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>bufferSize</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Constructor to allocate memory for this column. 
<p>
This function will throw an <a class="el" href="classSimpleDB_1_1Exception.html">Exception</a> if the memory cannot be allocated.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>bufferSize</em>&nbsp;</td><td>The maximum number of bytes the value will hold. </td></tr>
  </table>
</dl>
    </td>
  </tr>
</table>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="a3" doxytag="SimpleDB::StringColumn::bind"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">void SimpleDB::StringColumn::bind           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">SQLHSTMT&nbsp;</td>
          <td class="mdname" nowrap> <em>statementHandle</em>, </td>
        </tr>
        <tr>
          <td class="md" nowrap align="right"></td>
          <td class="md"></td>
          <td class="md" nowrap>int&nbsp;</td>
          <td class="mdname" nowrap> <em>columnNumber</em></td>
        </tr>
        <tr>
          <td class="md"></td>
          <td class="md">)&nbsp;</td>
          <td class="md" colspan="2"><code> [virtual]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
This abstract function is called by <a class="el" href="classSimpleDB_1_1Query.html">Query</a> when the <a class="el" href="classSimpleDB_1_1Query.html#a2">Query.bind</a> function is invoked. 
<p>
This function has an implementation that handles making sure columns are bound. This function should be called by any derived objects.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>statementHandle</em>&nbsp;</td><td>The statementHandle columns are being bound to </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>columnNumber</em>&nbsp;</td><td>The column number to bind this column to.. </td></tr>
  </table>
</dl>

<p>
Implements <a class="el" href="classSimpleDB_1_1Column.html#a1">SimpleDB::Column</a>.    </td>
  </tr>
</table>
<a class="anchor" name="a2" doxytag="SimpleDB::StringColumn::oStream"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">std::ostream&amp; SimpleDB::StringColumn::oStream           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">std::ostream &amp;&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>oStream</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap><code> [virtual]</code></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Function called to write a column value to the output stream. 
<p>
This function is implemented by each column type to write the value in a suitable form to the output stream.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>oStream</em>&nbsp;</td><td>Output stream object. </td></tr>
  </table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Output stream object to which data was written. </dd></dl>

<p>
Implements <a class="el" href="classSimpleDB_1_1Column.html#a2">SimpleDB::Column</a>.    </td>
  </tr>
</table>
<a class="anchor" name="a4" doxytag="SimpleDB::StringColumn::value"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">std::string SimpleDB::StringColumn::value           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="mdname1" valign="top" nowrap>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Returns the string value of this object. 
<p>
<dl compact><dt><b>Returns:</b></dt><dd>The string value. </dd></dl>

<p>
Reimplemented from <a class="el" href="classSimpleDB_1_1Column.html#a5">SimpleDB::Column</a>.    </td>
  </tr>
</table>
<hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="Column_8h-source.html">Column.h</a></ul>
<hr>
<div align="right"><small>
Copyright (C) 2005 <a target="top" href="http://www.eminence.com.au">Eminence Technology Pty Ltd</a>.<br>
Documentation pages generated by doxygen.</small><br>
<a href="http://sourceforge.net"><img src="http://sourceforge.net/sflogo.php?group_id=129109&amp;type=1" width="88" height="31" border="0" alt="SourceForge.net Logo" /></a>
</div>