AnnotatedFields
extends ArrayObject
in package
A dictionary of field names and their corresponding annotation.
Tags
Table of Contents
Properties
- $fields : array<string, AnnotatedSimpleField|AnnotatedObjectField|AnnotatedListField>
Methods
- __construct() : mixed
- get() : AnnotatedSimpleField|AnnotatedObjectField|AnnotatedListField
- Get a field by key.
- getListField() : AnnotatedListField
- Get a list field by key.
- getObjectField() : AnnotatedObjectField
- Get an object field by key.
- getSimpleField() : AnnotatedSimpleField
- Get a simple field by key.
- toArray() : array<string, mixed>
Properties
$fields
private
array<string, AnnotatedSimpleField|AnnotatedObjectField|AnnotatedListField>
$fields
= []
Methods
__construct()
public
__construct(array<string, array<string, mixed>> $rawResponse) : mixed
Parameters
- $rawResponse : array<string, array<string, mixed>>
-
Raw server response array.
get()
Get a field by key.
public
get(string $fieldName) : AnnotatedSimpleField|AnnotatedObjectField|AnnotatedListField
Parameters
- $fieldName : string
-
Field key to retrieve.
Tags
Return values
AnnotatedSimpleField|AnnotatedObjectField|AnnotatedListFieldgetListField()
Get a list field by key.
public
getListField(string $fieldName) : AnnotatedListField
Parameters
- $fieldName : string
-
Field key to retrieve.
Tags
Return values
AnnotatedListFieldgetObjectField()
Get an object field by key.
public
getObjectField(string $fieldName) : AnnotatedObjectField
Parameters
- $fieldName : string
-
Field key to retrieve.
Tags
Return values
AnnotatedObjectFieldgetSimpleField()
Get a simple field by key.
public
getSimpleField(string $fieldName) : AnnotatedSimpleField
Parameters
- $fieldName : string
-
Field key to retrieve.
Tags
Return values
AnnotatedSimpleFieldtoArray()
public
toArray() : array<string, mixed>
Return values
array<string, mixed> —Array representation for serialization.