SCField Class Reference
| Inherits from | NSObject |
| Declared in | SCField.h |
Overview
The SCField object identifies a Sitecore system item’s field.
It provides getters for the field’s properties and asynchronous loader for the field’s value.
Now you can load fields using SCApiSession or SCItem object.
Tasks
-
apiSessionThe SCApiSession object this field was created/loaded from.
property
Can be used to load the necessary data. -
fieldIdThe system field’s id.
property -
nameThe system field’s name.
property -
typeThe system field’s type. Possible values: “Image”, “Datetime”, “Checklist” etc.
property -
rawValueThe system field’s raw value.
property -
itemThe SCItem object for this field is belong to.
property -
fieldValueThe value of the field, depends on the field type ( see [SCField type] ).
property -
– readFieldValueOperationUsed for the loading field value.
Properties
apiSession
The SCApiSession object this field was created/loaded from.
Can be used to load the necessary data.
@property (nonatomic, readonly) SCExtendedApiSession *apiSessionDiscussion
The SCApiSession object this field was created/loaded from.
Can be used to load the necessary data.
Declared In
SCField.hfieldId
The system field’s id.
@property (nonatomic, readonly) NSString *fieldIdDiscussion
The system field’s id.
Declared In
SCField.hfieldValue
The value of the field, depends on the field type ( see [SCField type] ).
@property (nonatomic, readonly) id fieldValueDiscussion
The value of the field, depends on the field type ( see [SCField type] ).
This value is equal to [SCField rawValue] if class of the field’s object is SCField and can be different for other fields types.
See SCField inheritor class: [SCImageField fieldValue] for details.
Declared In
SCField.hitem
The SCItem object for this field is belong to.
@property (nonatomic, weak, readonly) SCItem *itemDiscussion
The SCItem object for this field is belong to.
Declared In
SCField.hname
The system field’s name.
@property (nonatomic, readonly) NSString *nameDiscussion
The system field’s name.
Declared In
SCField.hInstance Methods
readFieldValueOperation
Used for the loading field value.
- (SCAsyncOp)readFieldValueOperationReturn Value
SCAsyncOp block. Call it to get the expected result. The SCAsyncOpResult handler’s result is [SCField rawValue] by default but can be different for other fields types.
See SCField inheritor class: [SCImageField readFieldValueOperation] for details.
Discussion
Used for the loading field value.
Declared In
SCField.h