### YamlMime:JavaType
uid: "com.microsoft.azure.documentdb.JsonSerializable"
fullName: "com.microsoft.azure.documentdb.JsonSerializable"
name: "JsonSerializable"
nameWithType: "JsonSerializable"
summary: "Represents a base resource that can be serialized to JSON in the Azure Cosmos DB database service."
inheritances:
- ""
inheritedClassMethods:
- classRef: ""
methodsRef:
- ""
- ""
- ""
- ""
- ""
- ""
- ""
- ""
- ""
- ""
- ""
syntax: "public class **JsonSerializable** implements "
constructors:
- uid: "com.microsoft.azure.documentdb.JsonSerializable.JsonSerializable()"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.JsonSerializable()"
name: "JsonSerializable()"
nameWithType: "JsonSerializable.JsonSerializable()"
modifiers:
- "protected"
syntax: "protected JsonSerializable()"
- uid: "com.microsoft.azure.documentdb.JsonSerializable.JsonSerializable(java.lang.String)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.JsonSerializable(String jsonString)"
name: "JsonSerializable(String jsonString)"
nameWithType: "JsonSerializable.JsonSerializable(String jsonString)"
summary: "Constructor."
modifiers:
- "protected"
parameters:
- description: "the json string that represents the JsonSerializable."
name: "jsonString"
type: ""
syntax: "protected JsonSerializable(String jsonString)"
desc: "Constructor."
- uid: "com.microsoft.azure.documentdb.JsonSerializable.JsonSerializable(java.lang.String,com.fasterxml.jackson.databind.ObjectMapper)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.JsonSerializable(String jsonString, ObjectMapper objectMapper)"
name: "JsonSerializable(String jsonString, ObjectMapper objectMapper)"
nameWithType: "JsonSerializable.JsonSerializable(String jsonString, ObjectMapper objectMapper)"
summary: "Constructor."
modifiers:
- "protected"
parameters:
- description: "the json string that represents the JsonSerializable."
name: "jsonString"
type: ""
- description: "the custom object mapper"
name: "objectMapper"
type: ""
syntax: "protected JsonSerializable(String jsonString, ObjectMapper objectMapper)"
desc: "Constructor."
- uid: "com.microsoft.azure.documentdb.JsonSerializable.JsonSerializable(org.json.JSONObject)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.JsonSerializable(JSONObject jsonObject)"
name: "JsonSerializable(JSONObject jsonObject)"
nameWithType: "JsonSerializable.JsonSerializable(JSONObject jsonObject)"
summary: "Constructor."
modifiers:
- "protected"
parameters:
- description: "the json object that represents the JsonSerializable."
name: "jsonObject"
type: ""
syntax: "protected JsonSerializable(JSONObject jsonObject)"
desc: "Constructor."
methods:
- uid: "com.microsoft.azure.documentdb.JsonSerializable.getCollection(java.lang.String,java.lang.Class)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.getCollection(String propertyName, Class c)"
name: "getCollection(String propertyName, Class c)"
nameWithType: "JsonSerializable.getCollection(String propertyName, Class c)"
summary: "Gets an object collection."
parameters:
- description: "the property to get"
name: "propertyName"
type: ""
- description: "the class of the object. If c is a POJO class, it must be a member (and not an anonymous or local)\n and a static one."
name: "c"
type: "<>"
syntax: "public Collection getCollection(String propertyName, Class c)"
desc: "Gets an object collection."
returns:
description: "the object collection."
type: "<>"
- uid: "com.microsoft.azure.documentdb.JsonSerializable.getObject(java.lang.String,java.lang.Class)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.getObject(String propertyName, Class c)"
name: "getObject(String propertyName, Class c)"
nameWithType: "JsonSerializable.getObject(String propertyName, Class c)"
summary: "Gets an object value."
parameters:
- description: "the property to get."
name: "propertyName"
type: ""
- description: "the class of the object. If c is a POJO class, it must be a member (and not an anonymous or local)\n and a static one."
name: "c"
type: "<>"
syntax: "public T getObject(String propertyName, Class c)"
desc: "Gets an object value."
returns:
description: "the object value."
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.set(java.lang.String,T)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.set(String propertyName, T value)"
name: "set(String propertyName, T value)"
nameWithType: "JsonSerializable.set(String propertyName, T value)"
summary: "Sets the value of a property."
parameters:
- description: "the property to set."
name: "propertyName"
type: ""
- description: "the value of the property."
name: "value"
type: ""
syntax: "public void set(String propertyName, T value)"
desc: "Sets the value of a property."
- uid: "com.microsoft.azure.documentdb.JsonSerializable.toObject(java.lang.Class)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.toObject(Class c)"
name: "toObject(Class c)"
nameWithType: "JsonSerializable.toObject(Class c)"
summary: "Converts to an Object (only POJOs and JSONObject are supported)."
parameters:
- description: "the class of the object, either a POJO class or JSONObject. If c is a POJO class, it must be a member\n (and not an anonymous or local) and a static one."
name: "c"
type: "<>"
syntax: "public T toObject(Class c)"
desc: "Converts to an Object (only POJOs and JSONObject are supported)."
returns:
description: "the POJO."
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.get(java.lang.String)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.get(String propertyName)"
name: "get(String propertyName)"
nameWithType: "JsonSerializable.get(String propertyName)"
summary: "Gets a property value as Object."
parameters:
- description: "the property to get."
name: "propertyName"
type: ""
syntax: "public Object get(String propertyName)"
desc: "Gets a property value as Object."
returns:
description: "the value of the property."
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.getBoolean(java.lang.String)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.getBoolean(String propertyName)"
name: "getBoolean(String propertyName)"
nameWithType: "JsonSerializable.getBoolean(String propertyName)"
summary: "Gets a boolean value."
parameters:
- description: "the property to get."
name: "propertyName"
type: ""
syntax: "public Boolean getBoolean(String propertyName)"
desc: "Gets a boolean value."
returns:
description: "the boolean value."
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.getCollection(java.lang.String)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.getCollection(String propertyName)"
name: "getCollection(String propertyName)"
nameWithType: "JsonSerializable.getCollection(String propertyName)"
summary: "Gets a JSONObject collection."
parameters:
- description: "the property to get."
name: "propertyName"
type: ""
syntax: "public Collection getCollection(String propertyName)"
desc: "Gets a JSONObject collection."
returns:
description: "the JSONObject collection."
type: "<>"
- uid: "com.microsoft.azure.documentdb.JsonSerializable.getDouble(java.lang.String)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.getDouble(String propertyName)"
name: "getDouble(String propertyName)"
nameWithType: "JsonSerializable.getDouble(String propertyName)"
summary: "Gets a double value."
parameters:
- description: "the property to get."
name: "propertyName"
type: ""
syntax: "public Double getDouble(String propertyName)"
desc: "Gets a double value."
returns:
description: "the double value."
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.getHashMap()"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.getHashMap()"
name: "getHashMap()"
nameWithType: "JsonSerializable.getHashMap()"
summary: "Returns the propertybag(JSONObject) in a hashMap"
syntax: "public HashMap getHashMap()"
desc: "Returns the propertybag(JSONObject) in a hashMap"
returns:
description: "the HashMap."
type: "<,>"
- uid: "com.microsoft.azure.documentdb.JsonSerializable.getInt(java.lang.String)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.getInt(String propertyName)"
name: "getInt(String propertyName)"
nameWithType: "JsonSerializable.getInt(String propertyName)"
summary: "Gets an integer value."
parameters:
- description: "the property to get."
name: "propertyName"
type: ""
syntax: "public Integer getInt(String propertyName)"
desc: "Gets an integer value."
returns:
description: "the boolean value"
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.getLogger()"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.getLogger()"
name: "getLogger()"
nameWithType: "JsonSerializable.getLogger()"
modifiers:
- "protected"
syntax: "protected Logger getLogger()"
returns:
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.getLong(java.lang.String)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.getLong(String propertyName)"
name: "getLong(String propertyName)"
nameWithType: "JsonSerializable.getLong(String propertyName)"
summary: "Gets a long value."
parameters:
- description: "the property to get."
name: "propertyName"
type: ""
syntax: "public Long getLong(String propertyName)"
desc: "Gets a long value."
returns:
description: "the long value"
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.getMapper()"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.getMapper()"
name: "getMapper()"
nameWithType: "JsonSerializable.getMapper()"
modifiers:
- "protected"
syntax: "protected ObjectMapper getMapper()"
returns:
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.getObject(java.lang.String)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.getObject(String propertyName)"
name: "getObject(String propertyName)"
nameWithType: "JsonSerializable.getObject(String propertyName)"
summary: "Gets a JSONObject."
parameters:
- description: "the property to get."
name: "propertyName"
type: ""
syntax: "public JSONObject getObject(String propertyName)"
desc: "Gets a JSONObject."
returns:
description: "the JSONObject."
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.getObjectByPath(java.util.Collection)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.getObjectByPath(Collection propertyNames)"
name: "getObjectByPath(Collection propertyNames)"
nameWithType: "JsonSerializable.getObjectByPath(Collection propertyNames)"
summary: "Gets the value of a property identified by an array of property names that forms the path."
parameters:
- description: "that form the path to the the property to get."
name: "propertyNames"
type: "<>"
syntax: "public Object getObjectByPath(Collection propertyNames)"
desc: "Gets the value of a property identified by an array of property names that forms the path."
returns:
description: "the value of the property."
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.getString(java.lang.String)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.getString(String propertyName)"
name: "getString(String propertyName)"
nameWithType: "JsonSerializable.getString(String propertyName)"
summary: "Gets a string value."
parameters:
- description: "the property to get."
name: "propertyName"
type: ""
syntax: "public String getString(String propertyName)"
desc: "Gets a string value."
returns:
description: "the string value."
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.has(java.lang.String)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.has(String propertyName)"
name: "has(String propertyName)"
nameWithType: "JsonSerializable.has(String propertyName)"
summary: "Checks whether a property exists."
parameters:
- description: "the property to look up."
name: "propertyName"
type: ""
syntax: "public boolean has(String propertyName)"
desc: "Checks whether a property exists."
returns:
description: "true if the property exists."
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.remove(java.lang.String)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.remove(String propertyName)"
name: "remove(String propertyName)"
nameWithType: "JsonSerializable.remove(String propertyName)"
summary: "Removes a value by propertyName."
parameters:
- description: "the property to remove."
name: "propertyName"
type: ""
syntax: "public void remove(String propertyName)"
desc: "Removes a value by propertyName."
- uid: "com.microsoft.azure.documentdb.JsonSerializable.toJson()"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.toJson()"
name: "toJson()"
nameWithType: "JsonSerializable.toJson()"
summary: "Converts to a JSON string."
syntax: "public String toJson()"
desc: "Converts to a JSON string."
returns:
description: "the JSON string."
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.toJson(com.microsoft.azure.documentdb.SerializationFormattingPolicy)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.toJson(SerializationFormattingPolicy formattingPolicy)"
name: "toJson(SerializationFormattingPolicy formattingPolicy)"
nameWithType: "JsonSerializable.toJson(SerializationFormattingPolicy formattingPolicy)"
summary: "Converts to a JSON string."
parameters:
- description: "the formatting policy instance"
name: "formattingPolicy"
type: ""
syntax: "public String toJson(SerializationFormattingPolicy formattingPolicy)"
desc: "Converts to a JSON string."
returns:
description: "the JSON string."
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.toString()"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.toString()"
name: "toString()"
nameWithType: "JsonSerializable.toString()"
summary: "Gets Simple String representation of property bag."
overridden: "java.lang.Object.toString()"
syntax: "public String toString()"
desc: "Gets Simple String representation of property bag. For proper conversion to json and inclusion of the default values use ."
returns:
description: "string representation of property bag."
type: ""
- uid: "com.microsoft.azure.documentdb.JsonSerializable.toString(int)"
fullName: "com.microsoft.azure.documentdb.JsonSerializable.toString(int indentFactor)"
name: "toString(int indentFactor)"
nameWithType: "JsonSerializable.toString(int indentFactor)"
summary: "Gets formatted String representation of property bag."
deprecatedTag: "For proper conversion to json and inclusion of the default values use ."
parameters:
- description: "formatting indentation factor."
name: "indentFactor"
type: ""
syntax: "public String toString(int indentFactor)"
desc: "Gets formatted String representation of property bag."
hasDeprecatedTag: true
returns:
description: "formatted string representation of property bag."
type: ""
type: "class"
desc: "Represents a base resource that can be serialized to JSON in the Azure Cosmos DB database service. Note on Serializable: this interface is implemented solely for the use with the CosmosDB Spark Connector. In RDD transformation, it is a requirement of the RDD item type to be Serializable so that they can be transferred among the work nodes by the default serializer. The Serializable is not intended to be used by the user of the Cosmos DB Java SDK. Avoid relying on the serialized string format as it can change in the future."
implements:
- ""
metadata: {}
package: "com.microsoft.azure.documentdb"
artifact: com.microsoft.azure:azure-documentdb:2.4.7