Difference between revisions of "JsonNamespace class"

From Catglobe Wiki
Jump to: navigation, search
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
{{HelpFiles}}
 
 
{{CGscriptClass_Template
 
{{CGscriptClass_Template
 
|Name=<nowiki>JsonNamespace</nowiki>
 
|Name=<nowiki>JsonNamespace</nowiki>
 
|Description=<nowiki>The json namespace</nowiki>
 
|Description=<nowiki>The json namespace</nowiki>
|Methods=
+
|InheritsFrom=object|Methods=
 
{{CGscriptMethods_Template|ReturnType=string|Name=<nowiki>Encode</nowiki>|Parameters=
 
{{CGscriptMethods_Template|ReturnType=string|Name=<nowiki>Encode</nowiki>|Parameters=
{{CGscriptParameters_Template|Type=AnyType|Name=<nowiki>obj</nowiki>|Description=<nowiki>Object to encode</nowiki>}}
+
{{CGscriptParameters_Template|Type=object|Name=<nowiki>obj</nowiki>|Description=<nowiki>Object to encode</nowiki>}}
 
|Description=<nowiki>Encode an object to a json string</nowiki>}}
 
|Description=<nowiki>Encode an object to a json string</nowiki>}}
 
{{CGscriptMethods_Template|ReturnType=string|Name=<nowiki>EncodeWcf</nowiki>|Parameters=
 
{{CGscriptMethods_Template|ReturnType=string|Name=<nowiki>EncodeWcf</nowiki>|Parameters=
{{CGscriptParameters_Template|Type=AnyType|Name=<nowiki>obj</nowiki>|Description=<nowiki>Object to encode</nowiki>}}
+
{{CGscriptParameters_Template|Type=object|Name=<nowiki>obj</nowiki>|Description=<nowiki>Object to encode</nowiki>}}
 
|Description=<nowiki>Encode an object to a json string using Wcf json (where __type is added)</nowiki>}}
 
|Description=<nowiki>Encode an object to a json string using Wcf json (where __type is added)</nowiki>}}
{{CGscriptMethods_Template|ReturnType=AnyType|Name=<nowiki>Parse</nowiki>|Parameters=
+
{{CGscriptMethods_Template|ReturnType=object|Name=<nowiki>Parse</nowiki>|Parameters=
 
{{CGscriptParameters_Template|Type=string|Name=<nowiki>json</nowiki>|Description=<nowiki>String to parse</nowiki>}}
 
{{CGscriptParameters_Template|Type=string|Name=<nowiki>json</nowiki>|Description=<nowiki>String to parse</nowiki>}}
 
|Description=<nowiki>Parse a json string to an object structure</nowiki>}}
 
|Description=<nowiki>Parse a json string to an object structure</nowiki>}}
{{CGscriptMethods_Template|ReturnType=AnyType|Name=<nowiki>ParseWcf</nowiki>|Parameters=
+
{{CGscriptMethods_Template|ReturnType=object|Name=<nowiki>ParseWcf</nowiki>|Parameters=
 
{{CGscriptParameters_Template|Type=string|Name=<nowiki>json</nowiki>|Description=<nowiki>String to parse</nowiki>}}
 
{{CGscriptParameters_Template|Type=string|Name=<nowiki>json</nowiki>|Description=<nowiki>String to parse</nowiki>}}
 
|Description=<nowiki>Parse a json string to an object structure using Wcf json (where __type is respected)</nowiki>}}
 
|Description=<nowiki>Parse a json string to an object structure using Wcf json (where __type is respected)</nowiki>}}
{{CGscriptMethods_Template|ReturnType=string|Name=<nowiki>ToString</nowiki>|Description=<nowiki>The string representation of the object.</nowiki>}}
+
{{CGscriptMethods_Template|ReturnType=string|Name=<nowiki>ToString</nowiki>|Inherited=object|Description=<nowiki>The string representation of the object.</nowiki>}}
 
|Properties=
 
|Properties=
 
{{CGscriptProperties_Template|ReturnType=string|Name=<nowiki>ObjectTypeName</nowiki>|HasGetter=1|Description=<nowiki>The name of the type of object.</nowiki>}}
 
{{CGscriptProperties_Template|ReturnType=string|Name=<nowiki>ObjectTypeName</nowiki>|HasGetter=1|Description=<nowiki>The name of the type of object.</nowiki>}}
{{CGscriptProperties_Template|ReturnType=TypeInformation|Name=<nowiki>TypeInformation</nowiki>|HasGetter=1|Description=<nowiki>Get information about this class.</nowiki>}}
+
{{CGscriptProperties_Template|ReturnType=TypeInformation|Name=<nowiki>TypeInformation</nowiki>|HasGetter=1|Inherited=object|Description=<nowiki>Get information about this class.</nowiki>}}
 
}}
 
}}

Latest revision as of 05:50, 2 July 2020

JsonNamespace



The json namespace

Parent class

Inherits from object

Methods

  • string Encode(object obj "Object to encode") - Encode an object to a json string
  • string EncodeWcf(object obj "Object to encode") - Encode an object to a json string using Wcf json (where __type is added)
  • object Parse(string json "String to parse") - Parse a json string to an object structure
  • object ParseWcf(string json "String to parse") - Parse a json string to an object structure using Wcf json (where __type is respected)
  • (From object) string ToString() - The string representation of the object.

Properties

  • string ObjectTypeName { get; } - The name of the type of object.
  • (From object) TypeInformation TypeInformation { get; } - Get information about this class.