SourcePro® C++ 13.1 |
SourcePro® C++ API Reference Guide |
Product Documentation: SourcePro C++ Documentation Home |
An ordered collection of RWDBValue instances. More...
#include <rw/db/row.h>
Public Member Functions | |
RWDBRow () | |
RWDBRow (const RWDBRow &rvalue) | |
virtual | ~RWDBRow () |
virtual void | append (const RWDBValue &value) |
RWspace | binaryStoreSize () const |
virtual void | clearAndDestroy () |
virtual int | compareTo (const RWCollectable *c) const |
virtual size_t | entries () const |
virtual unsigned | hash () const |
virtual RWClassID | isA () const |
virtual bool | isEqual (const RWCollectable *c) const |
virtual RWCollectable * | newSpecies () const |
RWDBRow & | operator= (const RWDBRow &rvalue) |
RWDBValue & | operator[] (size_t index) const |
virtual void | restoreGuts (RWFile &file) |
virtual void | restoreGuts (RWvistream &stream) |
virtual void | saveGuts (RWFile &file) const |
virtual void | saveGuts (RWvostream &stream) const |
Public Member Functions inherited from RWCollectable | |
virtual | ~RWCollectable () |
RWspace | recursiveStoreSize () const |
RWStringID | stringID () const |
Additional Inherited Members | |
Static Public Member Functions inherited from RWCollectable | |
static RWClassID | classID (const RWStringID &name) |
static RWClassID | classIsA () |
static bool | isAtom (RWClassID id) |
static RWspace | nilStoreSize () |
RWDBRow is an ordered collection of RWDBValue objects. RWDBRow is a relatively low level construct used by the DB Interface Module to store a row of data on its way to or from the database. It is visible to applications for two reasons:
The only semantics that RWDBRow adds to RWCollectable are:
RWDBRow is designed around the Interface/Implementation paradigm. An RWDBRow instance is an interface to a reference-counted implementation; copy constructors and assignment operators produce additional references to a shared implementation.
RWDBRow::RWDBRow | ( | ) |
The default constructor produces an empty RWDBRow.
RWDBRow::RWDBRow | ( | const RWDBRow & | rvalue | ) |
Copy constructor. The created RWDBRow shares an implementation with rvalue.
|
virtual |
The default destructor.
|
virtual |
Appends value to self.
|
virtual |
Returns the number of bytes required to store self.
Reimplemented from RWCollectable.
|
virtual |
Removes all values from the collection and deletes them.
|
virtual |
If c points to an RWDBRow, this method returns:
0
, if self and c share the same implementation>0
, if self has length greater than c <0
, if c has length greater than selfIf self and c do not share the same implementation and both have the same length, compares each RWDBValue in self with each value in c. Returns 0
if all values compare equal, otherwise returns the result of the first comparison that does not return 0
.
If c does not point to an RWDBRow, throws an std::bad_cast exception.
As a precondition, c is tested to determine if it is a null pointer. If null, the method asserts in debug mode, and throws RWInternalErr in optimized builds.
Reimplemented from RWCollectable.
|
virtual |
Returns the total number of values in the collection.
|
virtual |
Returns a hash value for use in collection classes.
Reimplemented from RWCollectable.
|
virtual |
Redefined from class RWCollectable. Returns __RWDBROW.
Reimplemented from RWCollectable.
|
virtual |
Returns true
if compareTo(c) == 0
, otherwise returns false
.
Reimplemented from RWCollectable.
|
virtual |
Allocates a new object off the heap of the same type as self and returns a pointer to it. You are responsible for deleting the object when done with it.
Reimplemented from RWCollectable.
Assignment operator. Returns reference to self which shares an implementation with rvalue.
RWDBValue& RWDBRow::operator[] | ( | size_t | index | ) | const |
Returns a reference to the RWDBValue at position index in the collection. Throws an exception of type RWBoundsErr if index is out of range.
|
virtual |
Reads file, replacing the contents of self.
Reimplemented from RWCollectable.
|
virtual |
Reads stream, replacing the contents of self.
Reimplemented from RWCollectable.
|
virtual |
Writes the contents of self to file.
Reimplemented from RWCollectable.
|
virtual |
Writes the contents of self to stream.
Reimplemented from RWCollectable.
Copyright © 2015 Rogue Wave Software, Inc. All Rights Reserved. |