Value wrapper class representing a value/timestamp pair.
More...
List of all members.
Detailed Description
Value class for scalar and matrix data. Data points return their data encapsulated in VCValue objects, which also contain timestamp and data type information.
Member Function Documentation
Retrieve the raw data pointer for the data represented by this value. Do not modify the buffer returned by this method.
- Returns:
- A pointer to the raw data buffer.
Retrieve the data type associated with the raw data stored in this VCValue.
- Returns:
- The data type stored. Generally one of the values from enum VCDataTypes.
- (double) doubleAtRow: |
|
(int) |
row |
column: |
|
(int) |
column |
|
|
| |
Retrieve the double at a specific row and column in this value, if it is a matrix. For integer and double values, this function acts as -(double)doubleValue.
- Parameters:
-
row | The row (1-based) of the value of interest. |
column | The column (1-based) of the value of interest. |
- Returns:
- The double at the specified row. If the data type of this value is not one of VCDataTypeInt, VCDataTypeDouble, VCDataTypeMatrix, then 0.0 will be returned.
Attempt to convert the stored data to a double and return the result.
- Returns:
- If the stored data can be converted to a double, the result will be returned. If it cannot be converted, 0.0 will be returned.
- (id) initWithPointerAndCopy: |
|
(void *) |
pointer |
dataType: |
|
(int) |
type |
timestamp: |
|
(VCTimestamp *) |
aTimestamp |
|
|
| |
Create a new value object. The object's value will be taken by making a copy of the data pointed to by pointer, the type of which must be accurately described by the dataType parameter.
- Parameters:
-
pointer | A pointer to the location of the value that should be stored. The data at this location will be copied. |
type | The data type (see enum VCDataTypes) of the value. |
aTimestamp | The time to associate with this value. |
- Returns:
- A newly allocated (effective retain count = 1) value object.
Attempt to convert the stored data to an integer and return the result.
- Returns:
- If the stored data can be converted to an integer, the result will be returned. If it cannot be converted, 0 will be returned.
Retrieve the number of columns for this value.
- Returns:
- The number of columns for this matrix value. If this value does not represent a matrix, 1 will be returned.
Retrieve the number of rows for this value.
- Returns:
- The number of rows for this matrix value. If this value does not represent a matrix, 1 will be returned.
- (BOOL) valueIsEqual: |
|
(VCValue *) |
v |
|
Determine whether or not the represented values are equal, not counting the timestamps associated with them.
- Parameters:
-
v | The value to which the receiver should be compared |
- Returns:
- true if the values are equal, false if otherwise. If v is nil, or either v or the reciever is invalid, will return false
+ (id) valueWithDouble: |
|
(double) |
value |
andTimestamp: |
|
(VCTimestamp *) |
timestamp |
|
|
| |
Create a new, autoreleased value object. The object's type will be VCDataTypeDouble, and its value will be that provided by the first parameter.
- Parameters:
-
value | The value for the new VCValue object. |
timestamp | The time to associate with this value. |
- Returns:
- A newly allocated and autoreleased (effective retain count = 0) value object.
+ (id) valueWithInteger: |
|
(int32_t) |
value |
andTimestamp: |
|
(VCTimestamp *) |
timestamp |
|
|
| |
Create a new, autoreleased value object. The object's type will be VCDataTypeInt, and its value will be that provided by the first parameter.
- Parameters:
-
value | The value for the new VCValue object. |
timestamp | The time to associate with this value. |
- Returns:
- A newly allocated and autoreleased (effective retain count = 0) value object.
+ (id) valueWithPointerAndCopy: |
|
(void *) |
pointer |
dataType: |
|
(int) |
type |
timestamp: |
|
(VCTimestamp *) |
aTimestamp |
|
|
| |
Create a new, autoreleased value object. The object's value will be taken by making a copy of the data pointed to by pointer, the type of which must be accurately described by the dataType parameter.
- Parameters:
-
pointer | A pointer to the location of the value that should be stored. The data at this location will be copied. |
type | The data type (see enum VCDataTypes) of the value. |
aTimestamp | The time to associate with this value. |
- Returns:
- A newly allocated and autoreleased (effective retain count = 0) value object.
+ (id) valueWithPointerAndFree: |
|
(void *) |
pointer |
dataType: |
|
(int) |
type |
timestamp: |
|
(VCTimestamp *) |
aTimestamp |
|
|
| |
Create a new, autoreleased value object. The object's value will be taken by making a copy of the data pointed to by pointer, the type of which must be accurately described by the dataType parameter.
- Parameters:
-
pointer | A pointer to the location of the value that should be stored. The data at this location will be destroyed when this object is deallocated. |
type | The data type (see enum VCDataTypes) of the value. |
aTimestamp | The time to associate with this value. |
- Returns:
- A newly allocated and autoreleased (effective retain count = 0) value object.
Member Data Documentation
Retrieve the timestamp associated with this value.
- Parameters:
-
A | VCTimestamp object representing the timestamp for this value. |
The documentation for this class was generated from the following files: