public static class ConvertOperators.ConvertOperatorFactory extends Object
| Constructor and Description |
|---|
ConvertOperatorFactory(AggregationExpression expression)
Creates new
ConvertOperators.ConvertOperatorFactory for given AggregationExpression. |
ConvertOperatorFactory(String fieldReference)
Creates new
ConvertOperators.ConvertOperatorFactory for given fieldReference. |
| Modifier and Type | Method and Description |
|---|---|
ConvertOperators.Convert |
convertTo(int numericTypeIdentifier)
Creates new
aggregation expression that takes the associated value and converts it into the type
specified by the given numericTypeIdentifier. |
ConvertOperators.Convert |
convertTo(JsonSchemaObject.Type type)
Creates new
aggregation expression that takes the associated value and converts it into the type
specified by the given JsonSchemaObject.Type. |
ConvertOperators.Convert |
convertTo(String stringTypeIdentifier)
Creates new
aggregation expression that takes the associated value and converts it into the type
specified by the given stringTypeIdentifier. |
ConvertOperators.ToBool |
convertToBoolean()
Creates new
aggregation expression for $toBool that converts a value to boolean. |
ConvertOperators.ToDate |
convertToDate()
Creates new
aggregation expression for $toDate that converts a value to a date. |
ConvertOperators.ToDecimal |
convertToDecimal()
Creates new
aggregation expression for $toDecimal that converts a value to a decimal. |
ConvertOperators.ToDouble |
convertToDouble()
Creates new
aggregation expression for $toDouble that converts a value to a decimal. |
ConvertOperators.ToInt |
convertToInt()
Creates new
aggregation expression for $toInt that converts a value to an int. |
ConvertOperators.ToLong |
convertToLong()
Creates new
aggregation expression for $toLong that converts a value to a long. |
ConvertOperators.ToObjectId |
convertToObjectId()
Creates new
aggregation expression for $toObjectId that converts a value to a objectId. |
ConvertOperators.ToString |
convertToString()
Creates new
aggregation expression for $toString that converts a value to a string. |
ConvertOperators.Convert |
convertToTypeOf(AggregationExpression expression)
Creates new
aggregation expression that takes the associated value and converts it into the type
specified by the given expression. |
ConvertOperators.Convert |
convertToTypeOf(String fieldReference)
Creates new
aggregation expression that takes the associated value and converts it into the type
specified by the value of the given field reference. |
public ConvertOperatorFactory(String fieldReference)
ConvertOperators.ConvertOperatorFactory for given fieldReference.fieldReference - must not be null.public ConvertOperatorFactory(AggregationExpression expression)
ConvertOperators.ConvertOperatorFactory for given AggregationExpression.expression - must not be null.public ConvertOperators.Convert convertTo(String stringTypeIdentifier)
aggregation expression that takes the associated value and converts it into the type
specified by the given stringTypeIdentifier. stringTypeIdentifier - must not be null.ConvertOperators.Convert.public ConvertOperators.Convert convertTo(int numericTypeIdentifier)
aggregation expression that takes the associated value and converts it into the type
specified by the given numericTypeIdentifier. numericTypeIdentifier - must not be null.ConvertOperators.Convert.public ConvertOperators.Convert convertTo(JsonSchemaObject.Type type)
aggregation expression that takes the associated value and converts it into the type
specified by the given JsonSchemaObject.Type. type - must not be null.ConvertOperators.Convert.public ConvertOperators.Convert convertToTypeOf(String fieldReference)
aggregation expression that takes the associated value and converts it into the type
specified by the value of the given field reference. fieldReference - must not be null.ConvertOperators.Convert.public ConvertOperators.Convert convertToTypeOf(AggregationExpression expression)
aggregation expression that takes the associated value and converts it into the type
specified by the given expression. expression - must not be null.ConvertOperators.Convert.public ConvertOperators.ToBool convertToBoolean()
aggregation expression for $toBool that converts a value to boolean. Shorthand
for #convertTo("bool"). ConvertOperators.ToBool.public ConvertOperators.ToDate convertToDate()
aggregation expression for $toDate that converts a value to a date. Shorthand
for #convertTo("date"). ConvertOperators.ToDate.public ConvertOperators.ToDecimal convertToDecimal()
aggregation expression for $toDecimal that converts a value to a decimal.
Shorthand for #convertTo("decimal"). ConvertOperators.ToDecimal.public ConvertOperators.ToDouble convertToDouble()
aggregation expression for $toDouble that converts a value to a decimal.
Shorthand for #convertTo("double"). ConvertOperators.ToDouble.public ConvertOperators.ToInt convertToInt()
aggregation expression for $toInt that converts a value to an int. Shorthand
for #convertTo("int"). ConvertOperators.ToInt.public ConvertOperators.ToLong convertToLong()
aggregation expression for $toLong that converts a value to a long. Shorthand
for #convertTo("long"). ConvertOperators.ToInt.public ConvertOperators.ToObjectId convertToObjectId()
aggregation expression for $toObjectId that converts a value to a objectId. Shorthand
for #convertTo("objectId"). ConvertOperators.ToInt.public ConvertOperators.ToString convertToString()
aggregation expression for $toString that converts a value to a string. Shorthand
for #convertTo("string"). ConvertOperators.ToInt.Copyright © 2011–2020 Pivotal Software, Inc.. All rights reserved.