Collections return an array containing FieldApi instances so any field in those rows can be accessed.

Constructor

@:keepnew (api:Api, collection:Collection, ?key:String)

Variables

@:keepread onlyfields:Array<String>

An array containing all field keys

Methods

@:has_untyped@:value({ raw : false })@:keepfield (key:String, raw:Bool = false):Dynamic

Returns data of the field identified by key. Type of return is different based on the field's content.

If the field's content is text, it will return a String.

If the field is an image, this will return an instance of ImageHandler which you can use to transform the image.

If the field is a collection, it will return an array containing FieldApi instances.

All values will have html escaped unless raw is set.

@:keepgetKey ():String

Used by MixedFieldCollection instances to distinguish between different kind of blocks

@:keeptoJson (?options:ToJsonOptions):JSONValue

Returns a processed representation of all the data data in this field.