
iOS & macOS Charting Documentation - SciChart iOS & macOS Charts SDK v4.x
SCIAxisCollection
@interface SCIAxisCollection : SCIObservableCollection <id <ISCIAxis>>
Contains a collection of ISCIAxis
and allows getting of axis by Id.
-
Initializes a new instance of
SCIAxisCollection
class.Declaration
Objective-C
- (nonnull instancetype)initWithCollection: (nonnull NSArray<id<ISCIAxis>> *)collection;
Parameters
collection
The collections with items to add.
-
Gets the primary axis in the collection. This is the first axis that has
ISCIAxis.isPrimaryAxis
set to YES, ornil
- if none exists.Declaration
Objective-C
@property (nonatomic, strong, readonly, nullable) id<ISCIAxis> primaryAxis;
-
Gets the value indicating whether this collection has primary axis.
Declaration
Objective-C
@property (nonatomic, readonly) BOOL hasPrimaryAxis;
Return Value
YES - if any of the Axes in the collection have
ISCIAxis.isPrimaryAxis
set to YES. -
Gets the default axis, which is equal to the axis with the
DEFAULT_AXIS_ID
, else -nil
.Declaration
Objective-C
@property (nonatomic, strong, readonly) id<ISCIAxis> _Nonnull defaultAxis;
-
Gets the axis specified by id if it exists, otherwise returns nil.
Declaration
Objective-C
- (nonnull id<ISCIAxis>)getAxisById:(nonnull NSString *)axisId;
Parameters
axisId
The axis id.
Return Value
The axis with specified id if it exists, otherwise returns nil.
-
Gets the axis specified by id if it exists, otherwise returns nil.
Declaration
Objective-C
- (nonnull id<ISCIAxis>)getAxisById:(nonnull NSString *)axisId assertAxisExists:(BOOL)assertAxisExists;
Parameters
axisId
The axis id.
assertAxisExists
If set to YES assert and throw if the axis does not exist.
Return Value
The axis with specified id if it exists, otherwise returns nil.