[+/-]
NdbRecAttr::getColumn()NdbRecAttr::getType()NdbRecAttr::get_size_in_bytes()NdbRecAttr::isNULL()NdbRecAttr::int64_value()NdbRecAttr::int32_value()NdbRecAttr::medium_value()NdbRecAttr::short_value()NdbRecAttr::char_value()NdbRecAttr::int8_value()NdbRecAttr::u_64_value()NdbRecAttr::u_32_value()NdbRecAttr::u_medium_value()NdbRecAttr::u_short_value()NdbRecAttr::u_char_value()NdbRecAttr::u_8_value()NdbRecAttr::float_value()NdbRecAttr::double_value()NdbRecAttr::aRef()NdbRecAttr::clone()~NdbRecAttr()Abstract
This section lists and describes the public methods of the
NdbRecAttr class.
Constructor and Destructor.
The NdbRecAttr class has no public
constructor; an instance of this object is created using
NdbTransaction::execute(). The destructor
method, which is public, is discussed in
Section 2.3.16.1.21, “~NdbRecAttr()”.
Description. This method is used to obtain the column to which the attribute belongs.
Signature.
const NdbDictionary::Column* getColumn
(
void
) const
Parameters. None.
Return value.
A pointer to a Column object. See
Section 2.3.1, “The Column Class”.
Description. This method is used to obtain the column's datatype.
Signature.
NdbDictionary::Column::Type getType
(
void
) const
Parameters. None.
Return value.
An NdbDictionary::Column::Type value. See
Section 2.3.1.1.3, “Column::Type” for more information,
including permitted values.
Description. You can use this method to obtain the size of an attribute (element).
Signature.
Uint32 get_size_in_bytes
(
void
) const
Parameters. None.
Return value. The attribute size in bytes, as an unsigned 32-bit integer.
Description.
This method checks whether an attribute value is
NULL.
Signature.
int isNULL
(
void
) const
Parameters. None.
Return value. One of the following 3 values:
-1: The attribute value is not
defined due to an error.
0: The attribute value is defined,
but is not NULL.
1: The attribute value is defined and
is NULL.
In the event that
NdbTransaction::execute() has not yet
been called, the value returned by
isNull() is not determined.
Description.
This method gets a Bigint value stored in
an NdbRecAttr object, and returns it as a
64-bit signed integer.
Signature.
Int64 int64_value
(
void
) const
Parameters. None.
Return value. A 64-bit signed integer.
Description.
This method gets an Int value stored in an
NdbRecAttr object, and returns it as a
32-bit signed integer.
Signature.
Int32 int32_value
(
void
) const
Parameters. None.
Return value. A 32-bit signed integer.
Description.
Gets the value of a Mediumint value stored
in an NdbRecAttr object, and returns it as
a 32-bit signed integer.
Signature.
Int32 medium_value
(
void
) const
Parameters. None.
Return value. A 32-bit signed integer.
Description.
This method gets a Smallint value stored in
an NdbRecAttr object, and returns it as a
16-bit signed integer (short).
Signature.
short short_value
(
void
) const
Parameters. None.
Return value. A 16-bit signed integer.
Description.
This method gets a Char value stored in an
NdbRecAttr object, and returns it as a
char.
Signature.
char char_value
(
void
) const
Parameters. None.
Return value.
A char value.
Description.
This method gets a Small value stored in an
NdbRecAttr object, and returns it as an
8-bit signed integer.
Signature.
Int8 int8_value
(
void
) const
Parameters. None.
Return value. An 8-bit signed integer.
Description.
This method gets a Bigunsigned value stored
in an NdbRecAttr object, and returns it as
a 64-bit unsigned integer.
Signature.
Uint64 u_64_value
(
void
) const
Parameters. None.
Return value. A 64-bit unsigned integer.
Description.
This method gets an Unsigned value stored
in an NdbRecAttr object, and returns it as
a 32-bit unsigned integer.
Signature.
Uint32 u_32_value
(
void
) const
Parameters. None.
Return value. A 32-bit unsigned integer.
Description.
This method gets an Mediumunsigned value
stored in an NdbRecAttr object, and returns
it as a 32-bit unsigned integer.
Signature.
Uint32 u_medium_value
(
void
) const
Parameters. None.
Return value. A 32-bit unsigned integer.
Example.
[To be supplied...]
Description.
This method gets a Smallunsigned value
stored in an NdbRecAttr object, and returns
it as a 16-bit (short) unsigned integer.
Signature.
Uint16 u_short_value
(
void
) const
Parameters. None.
Return value. A short (16-bit) unsigned integer.
Description.
This method gets a Char value stored in an
NdbRecAttr object, and returns it as an
unsigned char.
Signature.
Uint8 u_char_value
(
void
) const
Parameters. None.
Return value.
An 8-bit unsigned char value.
Description.
This method gets a Smallunsigned value
stored in an NdbRecAttr object, and returns
it as an 8-bit unsigned integer.
Signature.
Uint8 u_8_value
(
void
) const
Parameters. None.
Return value. An 8-bit unsigned integer.
Description.
This method gets a Float value stored in an
NdbRecAttr object, and returns it as a
float.
Signature.
float float_value
(
void
) const
Parameters. None.
Return value. A float (4 bytes).
Description.
This method gets a Double value stored in
an NdbRecAttr object, and returns it as a
double.
Signature.
double double_value
(
void
) const
Parameters. None.
Return value. A double (8 bytes).
Description.
This method is used to obtain a reference to an attribute
value, as a char pointer. This pointer is
aligned appropriately for the datatype. The memory is released
by the NDB API when
NdbTransaction::closeTransaction() is
executed on the transaction which read the value.
Signature.
char* aRef
(
void
) const
Parameters.
A pointer to the attribute value. Because this pointer is
constant, this method can be called anytime after
NdbOperation::getValue() has been called.
Return value. None.
Description.
This method creates a deep copy of an
NdbRecAttr object.
The copy created by this method should be deleted by the application when no longer needed.
Signature.
NdbRecAttr* clone
(
void
) const
Parameters. None.
Return value.
An NdbRecAttr object. This is a complete
copy of the original, including all data.
Description.
The NdbRecAttr class destructor method.
You should delete only copies of NdbRecAttr
objects that were created in your application using the
clone() method. See
Section 2.3.16.1.20, “NdbRecAttr::clone()”.
Signature.
~NdbRecAttr
(
void
)
Parameters. None.
Return value. None.
