Navigation
API > API/Runtime > API/Runtime/Json > API/Runtime/Json/Dom
References
| Module | Json |
| Header | /Engine/Source/Runtime/Json/Public/Dom/JsonObject.h |
| Include | #include "Dom/JsonObject.h" |
Syntax
class FJsonObject
Remarks
A Json Object is a structure holding an unordered set of name/value pairs. In a Json file, it is represented by everything between curly braces {}.
Variables
| Type | Name | Description | |
|---|---|---|---|
| TMap< FString, TSharedPtr< FJsonValue > > | Values |
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | Duplicate
(
const TSharedPtr< const FJsonObject >& Source, |
||
| void | Duplicate
(
const TSharedPtr< FJsonObject >& Source, |
||
| const TArray< TSharedPtr< FJsonValue > > & | GetArrayField
(
const FString& FieldName |
Get the field named FieldName as an array. | |
| bool | GetBoolField
(
const FString& FieldName |
Gets the field with the specified name as a boolean. | |
| TSharedPtr< FJsonValue > | |||
| int32 | GetIntegerField
(
const FString& FieldName |
Gets a numeric field and casts to an int32 | |
| double | GetNumberField
(
const FString& FieldName |
Gets the field with the specified name as a number. | |
| const TSharedPtr< FJsonObject > & | GetObjectField
(
const FString& FieldName |
Gets the field with the specified name as a Json object. | |
| FString | GetStringField
(
const FString& FieldName |
Get the field named FieldName as a string. | |
| bool | Checks whether a field with the specified name exists in the object. | ||
| bool | HasTypedField
(
const FString& FieldName |
Checks whether a field with the specified name and type exists in the object. | |
| void | RemoveField
(
const FString& FieldName |
Removes the field with the specified name. | |
| void | SetArrayField
(
const FString& FieldName, |
Set an array field named FieldName and value of Array | |
| void | SetBoolField
(
const FString& FieldName, |
Set a boolean field named FieldName and value of InValue | |
| void | SetField
(
const FString& FieldName, |
Sets the value of the field with the specified name. | |
| void | SetNumberField
(
const FString& FieldName, |
Add a field named FieldName with Number as value | |
| void | SetObjectField
(
const FString& FieldName, |
Set an ObjectField named FieldName and value of JsonObject | |
| void | SetStringField
(
const FString& FieldName, |
Add a field named FieldName with value of StringValue | |
| bool | TryGetArrayField
(
const FString& FieldName, |
Try to get the field named FieldName as an array, or return false if it's another type | |
| bool | TryGetBoolField
(
const FString& FieldName, |
Get the field named FieldName as a string. | |
| bool | TryGetEnumArrayField
(
const FString& FieldName, |
Get the field named FieldName as an array of enums. | |
| TSharedPtr< FJsonValue > | TryGetField
(
const FString& FieldName |
Attempts to get the field with the specified name. | |
| bool | TryGetNumberField
(
const FString& FieldName, |
Get the field named FieldName as a number, and makes sure it's within uint32 range. | |
| bool | TryGetNumberField
(
const FString& FieldName, |
Get the field named FieldName as a number. | |
| bool | TryGetNumberField
(
const FString& FieldName, |
Get the field named FieldName as a number. | |
| bool | TryGetNumberField
(
const FString& FieldName, |
Get the field named FieldName as a number, and makes sure it's within int8 range. | |
| bool | TryGetNumberField
(
const FString& FieldName, |
Get the field named FieldName as a number, and makes sure it's within int16 range. | |
| bool | TryGetNumberField
(
const FString& FieldName, |
Get the field named FieldName as a number, and makes sure it's within int32 range. | |
| bool | TryGetNumberField
(
const FString& FieldName, |
Get the field named FieldName as a number. | |
| bool | TryGetNumberField
(
const FString& FieldName, |
Get the field named FieldName as a number, and makes sure it's within uint8 range. | |
| bool | TryGetNumberField
(
const FString& FieldName, |
Get the field named FieldName as a number, and makes sure it's within uint16 range. | |
| bool | TryGetNumberField
(
const FString& FieldName, |
Get the field named FieldName as a number, and makes sure it's within uint64 range. | |
| bool | TryGetObjectField
(
const FString& FieldName, |
Try to get the field named FieldName as an object, or return false if it's another type | |
| bool | TryGetStringArrayField
(
const FString& FieldName, |
Get the field named FieldName as an array of strings. | |
| bool | TryGetStringField
(
const FString& FieldName, |
Get the field named FieldName as a string. |