GeneratedV1Document
extends GeneratedV1Prediction
in package
Generated V1 document prediction results.
Table of Contents
Properties
- $fields : array<string|int, mixed>
Methods
- __construct() : mixed
- GeneratedV1Document constructor.
- __toString() : string
- getListFields() : array<string, GeneratedListField>
- Returns a dictionary of all list-like fields.
- getObjectFields() : array<string, GeneratedObjectField>
- Returns a dictionary of all object-like fields.
- getSingleFields() : array<string, StringField>
- Returns a dictionary of all fields that aren't a collection.
- listFieldNames() : array<string|int, string>
- Lists names of all top-level field keys.
Properties
$fields
public
array<string|int, mixed>
$fields
Dictionary of all fields in the document.
Methods
__construct()
GeneratedV1Document constructor.
public
__construct(array<string|int, mixed> $rawPrediction) : mixed
Parameters
- $rawPrediction : array<string|int, mixed>
-
Dictionary containing the JSON document response.
__toString()
public
__toString() : string
Return values
string —String representation.
getListFields()
Returns a dictionary of all list-like fields.
public
getListFields() : array<string, GeneratedListField>
Return values
array<string, GeneratedListField>getObjectFields()
Returns a dictionary of all object-like fields.
public
getObjectFields() : array<string, GeneratedObjectField>
Return values
array<string, GeneratedObjectField>getSingleFields()
Returns a dictionary of all fields that aren't a collection.
public
getSingleFields() : array<string, StringField>
Return values
array<string, StringField>listFieldNames()
Lists names of all top-level field keys.
public
listFieldNames() : array<string|int, string>