Einhugur JSON Plugin III for Xojo

EinhugurJSONIII.JSONPrimitive Class

Basic JSON primitive that can represent Boolean, Double, Integer, a String, JSON array or JSON object.

Object
   JSONPrimitive

class EinhugurJSONIII.JSONPrimitive implements

Iterable

Constructors

JSONPrimitivePrivate constructor.

Properties

BooleanValueReads or writes Boolean value if the JSONPrimitive is actually Boolean.
DoubleValueReads or writes Double value if the JSONPrimitive is actually Double.
Int32ValueReads or writes Int32 value if the JSONPrimitive is actually Int32.
Int64ValueReads or writes Int64 value if the JSONPrimitive is actually Int64.
IsArrayReturns true if the JSONPrimitive is actually JSON array.
IsBooleanReturns true if the JSONPrimitive is actually Boolean.
IsDoubleReturns true if the JSONPrimitive is actually Double.
IsIntReturns true if the JSONPrimitive is actually Integer based (Int32 or Int64).
IsNullReturns true if the JSONPrimitive represents JSON null.
IsNumberReturns true if the JSONPrimitive is actually number.
IsObjectReturns true if the JSONPrimitive is actually JSON object.
IsStringReturns true if the JSONPrimitive is actually String.
MemberCountReturn number of members in the JSON object.
StringValueReads or writes String value if the JSONPrimitive is actually String.
TypeReturns type code enum value for the JSON primitive.

Methods

AddMemberAdds Boolean member to a JSON object.
AddMemberAdds Double member to a JSON object.
AddMemberAdds JSONPrimitive member to a JSON object.
AddMemberAdds Int32 member to a JSON object.
AddMemberAdds Int64 member to a JSON object.
AddMemberAdds String member to a JSON object.
AsArrayGets JSONArray from the JSONPrimitive if the primitive is actually array.
BooleanValueByKeyGets or Sets Boolean value by key on a JSON object.
CloneDeep clones the primitive..
DoubleValueByKeyGets or Sets Double value by key on a JSON object.
GetSourceGets source for the JSON primitive and all nodes bellow it.
HasMemberChecks if JSON object has a member by given name.
Int32ValueByKeyGets or Sets Int32 value by key on a JSON object.
Int64ValueByKeyGets or Sets Int64 value by key on a JSON object.
Operator_CompareCompares the JSON primitive with a JSONprimitive value.
Operator_CompareCompares the JSON primitive with a Boolean value.
Operator_CompareCompares the JSON primitive with a double value.
Operator_CompareCompares the JSON primitive with a Int32 value.
Operator_CompareCompares the JSON primitive with a Int64 value.
Operator_CompareCompares the JSON primitive with a String value.
Operator_SubscriptReads JSON primitive from JSON object by using the Xojo array operator.
RemoveAllMembersRemoves all members from the primitive if the primitive is a JSON object.
RemoveMemberRemoves member by name from JSON object.
SetArrayChanges the primitive so it becomes json array.
SetObjectChanges the primitive so it becomes json object.
SortKeysSorts the Keys if the primitive is actually Object.
StringValueByKeyGets or Sets String value by key on a JSON object.

Enumerations

PrimitiveTypesEnum representing types of primitive nodes.

Examples

This class implements Iterable interface which means you can use for each to iterate through JSON object or JSON array.

Supported Platforms:

  • macOS Intel 32 bit
  • macOS Intel 64 bit
  • macOS Apple Silicon
  • Windows 32 bit
  • Windows 64 bit
  • Windows ARM 64 bit
  • Linux 32 bit
  • Linux 64 bit
  • Linux ARM 32 bit
  • Linux ARM 64 bit
  • iOS