Class: Azure::Cosmosdb::Mgmt::V2019_12_12::Models::ContainerPartitionKey

Inherits:
Object
  • Object
show all
Includes:
MsRestAzure
Defined in:
lib/2019-12-12/generated/azure_mgmt_cosmosdb/models/container_partition_key.rb

Overview

The configuration of the partition key to be used for partitioning data into multiple partitions

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#kindPartitionKind

partitioning. Possible values include: ‘Hash’, ‘Range’. Default value: ‘Hash’ .



23
24
25
# File 'lib/2019-12-12/generated/azure_mgmt_cosmosdb/models/container_partition_key.rb', line 23

def kind
  @kind
end

#pathsArray<String>

container can be partitioned



18
19
20
# File 'lib/2019-12-12/generated/azure_mgmt_cosmosdb/models/container_partition_key.rb', line 18

def paths
  @paths
end

#versionInteger



26
27
28
# File 'lib/2019-12-12/generated/azure_mgmt_cosmosdb/models/container_partition_key.rb', line 26

def version
  @version
end

Class Method Details

.mapperObject

Mapper for ContainerPartitionKey class as Ruby Hash. This will be used for serialization/deserialization.



33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
# File 'lib/2019-12-12/generated/azure_mgmt_cosmosdb/models/container_partition_key.rb', line 33

def self.mapper()
  {
    client_side_validation: true,
    required: false,
    serialized_name: 'ContainerPartitionKey',
    type: {
      name: 'Composite',
      class_name: 'ContainerPartitionKey',
      model_properties: {
        paths: {
          client_side_validation: true,
          required: false,
          serialized_name: 'paths',
          type: {
            name: 'Sequence',
            element: {
                client_side_validation: true,
                required: false,
                serialized_name: 'StringElementType',
                type: {
                  name: 'String'
                }
            }
          }
        },
        kind: {
          client_side_validation: true,
          required: false,
          serialized_name: 'kind',
          default_value: 'Hash',
          type: {
            name: 'String'
          }
        },
        version: {
          client_side_validation: true,
          required: false,
          serialized_name: 'version',
          constraints: {
            InclusiveMaximum: 2,
            InclusiveMinimum: 1
          },
          type: {
            name: 'Number'
          }
        }
      }
    }
  }
end