Class RangeIndex


  • public final class RangeIndex
    extends Index
    Represents a range index in the Azure Cosmos DB database service.
    • Constructor Detail

      • RangeIndex

        public RangeIndex​(DataType dataType)
        Initializes a new instance of the RangeIndex class with specified DataType.

        Here is an example to instantiate RangeIndex class passing in the DataType:

         
        
         RangeIndex rangeIndex = new RangeIndex(DataType.NUMBER);
        
         
         
        Parameters:
        dataType - the data type.
      • RangeIndex

        public RangeIndex​(DataType dataType,
                          int precision)
        Initializes a new instance of the RangeIndex class with specified DataType and precision.
         
        
         RangeIndex rangeIndex = new RangeIndex(DataType.NUMBER, -1);
        
         
         
        Parameters:
        dataType - the data type of the RangeIndex
        precision - the precision of the RangeIndex
    • Method Detail

      • dataType

        public DataType dataType()
        Gets data type.
        Returns:
        the data type.
      • dataType

        public RangeIndex dataType​(DataType dataType)
        Sets data type.
        Parameters:
        dataType - the data type.
        Returns:
        the RangeIndex.
      • precision

        public int precision()
        Gets precision.
        Returns:
        the precision.
      • precision

        public RangeIndex precision​(int precision)
        Sets precision.
        Parameters:
        precision - the precision.
        Returns:
        the RangeIndex.