Breadcrumbs

extendedJSONToClass() Operation


Syntax


set anObject = aString.extendedJSONToClass()
set anObject = extendedJSONToClass(literal)


Semantics

The operation extendedJSONToClass() takes an Extended JSON string (aString) and tries to map it to anObject. If this is not possible, an error is raised.

By default, the following mapping rules apply:

  • Extended JSON attributes are mapped to class attributes having the same name.

  • Attributes not defined in the target class are ignored.

For more mapping details refer to JSON Type Mapping. These details also refer to Extended JSON.

Substitutables

aString

An Extended JSON document as String.

anObject

Target object, can be any object.

literal

String literal.

Examples


set myAddress = mongoDbDocument.extendedJSONToClass();

See for more examples.



icon_download_example.png

<your example path>\Add-ons\MongoDB\uml\simpleMongoDbAccess.xml



For more information on Extended JSON refer to MongoDB Extended JSON.

Related Pages:


Related Documentation: