aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2012-08-17 10:08:14 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2012-08-17 10:08:14 +0200
commit3d643f17ae30d1a3c49f9bf3968f706898bea842 (patch)
treebf300174a43712edffec0d12f3447edba4acf1b4
parentb9ae91e23fc4eaeaf411fabb5b71cd023889d4e7 (diff)
Minor documentation changes
-rw-r--r--doc/manual.xhtml25
1 files changed, 13 insertions, 12 deletions
diff --git a/doc/manual.xhtml b/doc/manual.xhtml
index 395c90e..ffc485c 100644
--- a/doc/manual.xhtml
+++ b/doc/manual.xhtml
@@ -1207,16 +1207,17 @@ private:
unnecessary.</p>
<p>The final change adds a data member called <code>id_</code> which
- is preceded by another pragma. In ODB every persistent object must
- have a unique, within its class, identifier. Or, in other words,
- no two persistent instances of the same type have equal
- identifiers. For our class we use an integer id. The
- <code>db&nbsp;id auto</code> pragma that precedes the <code>id_</code>
- member tells the ODB compiler that the following member is the
- object's identifier. The <code>auto</code> specifier indicates that it
- is a database-assigned id. A unique id will be automatically generated
- by the database and assigned to the object when it is made
- persistent.</p>
+ is preceded by another pragma. In ODB every persistent object normally
+ has a unique, within its class, identifier. Or, in other words, no two
+ persistent instances of the same type have equal identifiers. While it
+ is possible to define a persistent class without an object id, the number
+ of database operations that can be performed on such a class is limited.
+ For our class we use an integer id. The <code>db&nbsp;id auto</code>
+ pragma that precedes the <code>id_</code> member tells the ODB compiler
+ that the following member is the object's identifier. The
+ <code>auto</code> specifier indicates that it is a database-assigned
+ id. A unique id will be automatically generated by the database and
+ assigned to the object when it is made persistent.</p>
<p>In this example we chose to add an identifier because none of
the existing members could serve the same purpose. However, if
@@ -1226,7 +1227,7 @@ private:
identification (SSN in the United States or ID/passport number
in other countries), then we could use that as an id. Or, if
we stored an email associated with each person, then we could
- have used that since each person is presumed to have a unique
+ have used that if each person is presumed to have a unique
email address, for example:</p>
<pre class="cxx">
@@ -2203,7 +2204,7 @@ class person
<a href="#4.4">Section 4.4, "Query Result"</a>).</p>
<p>The object id can be of a simple or composite (<a href="#7.2.1">Section
- 7.2.1, "Composite Object Ids"</a>) value type which should be
+ 7.2.1, "Composite Object Ids"</a>) value type and should be
default-constructible.</p>
<p>If an object class has private or protected non-transient data