![]() |
Lightstreamer iOS Client 1.2.6
Native iOS Client library for Lightstreamer
|
The LSUpdateInfo class provides information about an update for a subscribed item. More...
#import <LSUpdateInfo.h>
Public Member Functions | |
(id) | - initWithItemPosition:itemName:fieldNames:oldValues:newValues:isSnapshot: |
Initializes an LSUpdateInfo object with the specified parameters. | |
(BOOL) | - isChangedValueOfFieldPosition: |
Tells if the value for a field has changed after the reception of this update. | |
(BOOL) | - isChangedValueOfFieldName: |
Tells if the value for a field has changed after the reception of this update. | |
(NSString *) | - currentValueOfFieldPosition: |
Gets the value for a field as it is after the reception of this update. | |
(NSString *) | - currentValueOfFieldName: |
Gets the value for a field as it is after the reception of this update. | |
(NSString *) | - previousValueOfFieldPosition: |
Gets the value for a field as it was before the reception of this update. | |
(NSString *) | - previousValueOfFieldName: |
Gets the value for a field as it was before the reception of this update. | |
Static Public Member Functions | |
(LSUpdateInfo *) | + updateInfoForItemPosition:itemName:fieldNames:oldValues:newValues:isSnapshot: |
Creates and returns an LSUpdateInfo object with the specified parameters. | |
Properties | |
int | itemPosition |
The 1-based position of the item in the Group of items in the related table. | |
NSString * | itemName |
The item name, or nil if an LSTableInfo was used to describe the related table. | |
int | numberOfFields |
The number of fields of the Schema used to subscribe the table. | |
BOOL | isSnapshot |
Tells if the update is part of the initial snapshot. |
The LSUpdateInfo class provides information about an update for a subscribed item.
The new and previous values for the subscribed fields are reported.
NOTE: If the table subscription configuration enables the "COMMAND logic", then the old field values are referred to the same key.
Both names and positional information can be used to identify the specific fields, unless an LSTableInfo was used to describe the related table: in that case, only positional information can be used.
- (NSString *) currentValueOfFieldName: | (NSString *) | fieldName |
Gets the value for a field as it is after the reception of this update.
fieldName | A field name. |
NSInvalidArgumentException | Thrown in case the specified field name does not represent a subscribed field. |
LSException | Thrown in case an LSTableInfo was used to describe the related table. |
- (NSString *) currentValueOfFieldPosition: | (int) | fieldPosition |
Gets the value for a field as it is after the reception of this update.
fieldPosition | The 1-based field position within the Schema of fields in the related table. |
NSInvalidArgumentException | Thrown in case the specified field position does not represent a subscribed field. |
- (id) initWithItemPosition: | (int) | itemPosition | |
itemName: | (NSString *) | itemName | |
fieldNames: | (NSArray *) | fieldNames | |
oldValues: | (NSArray *) | oldValues | |
newValues: | (NSArray *) | newValues | |
isSnapshot: | (BOOL) | isSnapshot | |
Initializes an LSUpdateInfo object with the specified parameters.
itemPosition | The 1-based position of the item in the Group of items in the related table. |
itemName | The item name, or nil if an LSTableInfo was used to describe the related table. |
fieldNames | An array of strings containing the names of fields of the Schema used to subscribe the table, or nil if an LSTableInfo was used to describe the related table. |
oldValues | An array of strings containing the previous values of fields of the Schema. |
newValues | An array of strings containing the current values of fields of the Schema. |
isSnapshot | Tells if the update is part of the initial snapshot. |
- (BOOL) isChangedValueOfFieldName: | (NSString *) | fieldName |
Tells if the value for a field has changed after the reception of this update.
For the first update for the item, it always returns YES.
fieldName | A field name. |
NSInvalidArgumentException | Thrown in case the specified field name does not represent a subscribed field. |
LSException | Thrown in case an LSTableInfo was used to describe the related table. |
- (BOOL) isChangedValueOfFieldPosition: | (int) | fieldPosition |
Tells if the value for a field has changed after the reception of this update.
For the first update for the item, it always returns YES.
fieldPosition | The 1-based field position within the Schema of fields in the related table. |
NSInvalidArgumentException | Thrown in case the specified field position does not represent a subscribed field. |
- (NSString *) previousValueOfFieldName: | (NSString *) | fieldName |
Gets the value for a field as it was before the reception of this update.
fieldName | A field name. |
NSInvalidArgumentException | Thrown in case the specified field name does not represent a subscribed field. |
LSException | Thrown in case an LSTableInfo was used to describe the related table. |
- (NSString *) previousValueOfFieldPosition: | (int) | fieldPosition |
Gets the value for a field as it was before the reception of this update.
fieldPosition | The 1-based field position within the Schema of fields in the related table. |
NSInvalidArgumentException | Thrown in case the specified field position does not represent a subscribed field. |
+ (LSUpdateInfo *) updateInfoForItemPosition: | (int) | itemPosition | |
itemName: | (NSString *) | itemName | |
fieldNames: | (NSArray *) | fieldNames | |
oldValues: | (NSArray *) | oldValues | |
newValues: | (NSArray *) | newValues | |
isSnapshot: | (BOOL) | isSnapshot | |
Creates and returns an LSUpdateInfo object with the specified parameters.
itemPosition | The 1-based position of the item in the Group of items in the related table. |
itemName | The item name, or nil if an LSTableInfo was used to describe the related table. |
fieldNames | An array of strings containing the names of fields of the Schema used to subscribe the table, or nil if an LSTableInfo was used to describe the related table. |
oldValues | An array of strings containing the previous values of fields of the Schema. |
newValues | An array of strings containing the current values of fields of the Schema. |
isSnapshot | Tells if the update is part of the initial snapshot. |
- (BOOL) isSnapshot [read, assign] |
Tells if the update is part of the initial snapshot.
- (NSString*) itemName [read, assign] |
The item name, or nil if an LSTableInfo was used to describe the related table.
- (int) itemPosition [read, assign] |
The 1-based position of the item in the Group of items in the related table.
- (int) numberOfFields [read, assign] |
The number of fields of the Schema used to subscribe the table.
In case an LSTableInfo was used to describe the related table, this number might not be known at subscription time.