MFStoryline Class Reference

Inherits from NSObject
Declared in MFStoryline.h
MFStoryline.m

Overview

The MFStoryline class represent a storyline object. Each of storyline can have multiple MFStorylineDetail object.

  objectId

Specifies the unique id of MFStoryline object.

@property (strong, nonatomic, readonly, nullable) NSString *objectId

Discussion

This field will be assigned by fetching current object that exists or by saving new user to Mesosfer cloud.

Declared In

MFStoryline.h

  createdAt

Specifies the created timestamp of MFStoryline object.

@property (strong, nonatomic, readonly, nullable) NSDate *createdAt

Discussion

This field will be assigned by fetching current object that exists or by saving new user to Mesosfer cloud.

Declared In

MFStoryline.h

  updatedAt

Specifies the last updated timestamp of MFStoryline object.

@property (strong, nonatomic, readonly, nullable) NSDate *updatedAt

Discussion

This field will be assigned by fetching current object that exists or by saving new user to Mesosfer cloud.

Declared In

MFStoryline.h

  title

Specifies the title of storyline.

@property (strong, nonatomic, nullable) NSString *title

Declared In

MFStoryline.h

  isEnabled

Specifies the state of storyline, whether it is enabled or disabled.

@property (assign, nonatomic) BOOL isEnabled

Declared In

MFStoryline.h

+ storylineWithTitle:NS_SWIFT_NAME:

Creates a new MFStoryline with a title.

+ (nonnull instancetype)storylineWithTitle:(nonnull NSString *)title NS_SWIFT_NAME

Parameters

title

A name can be any alphanumeric string that begins with a letter. It represents a unique name for your storyline, like ‘Story for Independence Day’.

Return Value

the object beacon that is instantiated with the given title.

Declared In

MFStoryline.h

+ storylineWithObjectId:NS_SWIFT_NAME:

Creates a reference to an existing MFStoryline for use in creating associations between MFStorylines.

+ (nonnull instancetype)storylineWithObjectId:(nonnull NSString *)objectId NS_SWIFT_NAME

Parameters

objectId

The object id for the referenced MFStoryline object.

Return Value

A MFStoryline instance without data.

Discussion

Warning: You need to call MFStoryline.fetchAsyncWithBlock: to fetch object from Mesosfer cloud.

Declared In

MFStoryline.h

+ query

Creates a new MFQuery instance for querying MFStoryline object.

+ (nonnull MFQuery *)query

Return Value

A new MFQuery instance.

Declared In

MFStoryline.h

– dictionary

Gets all key and value pair of MFStoryline object in a dictionary.

- (nullable NSDictionary *)dictionary

Return Value

The dictionary of all key and value pair object.

Declared In

MFStoryline.h

– fetchAsyncWithBlock:

Fetch the current MFStoryline data from Mesosfer cloud asynchronously and executes the given callback block.

- (void)fetchAsyncWithBlock:(nullable MFObjectResultBlock)block

Parameters

block

The block to execute. It shoud have the following argument signature: ^(MFStoryline *storyline, NSError *error).

Declared In

MFStoryline.h

– saveAsyncWithBlock:

Saves the MFStoryline asynchronously and executes the given callback block.

- (void)saveAsyncWithBlock:(nullable MFBooleanResultBlock)block

Parameters

block

The block to execute. It should have the following argument signature: ^(BOOL succeeded, NSError *error).

Declared In

MFStoryline.h

– deleteAsyncWithBlock:

Delete the MFData object in Mesosfer cloud asynchronously and executes the given callback block.

- (void)deleteAsyncWithBlock:(nullable MFBooleanResultBlock)block

Parameters

block

The block to execute. It should have the following argument signature: ^(BOOL succeeded, NSError *error).

Declared In

MFStoryline.h