Class: Google::Apis::DatastoreV1beta2::Property

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
generated/google/apis/datastore_v1beta2/classes.rb,
generated/google/apis/datastore_v1beta2/representations.rb,
generated/google/apis/datastore_v1beta2/representations.rb

Overview

An entity property.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ Property

Returns a new instance of Property



691
692
693
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 691

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#blob_key_valueString

A blob key value. Corresponds to the JSON property blobKeyValue

Returns:

  • (String)


623
624
625
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 623

def blob_key_value
  @blob_key_value
end

#blob_valueString

A blob value. May be a maximum of 1,000,000 bytes. When indexed is true, may have at most 500 bytes. Corresponds to the JSON property blobValue

Returns:

  • (String)


629
630
631
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 629

def blob_value
  @blob_value
end

#boolean_valueBoolean Also known as: boolean_value?

A boolean value. Corresponds to the JSON property booleanValue

Returns:

  • (Boolean)


634
635
636
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 634

def boolean_value
  @boolean_value
end

#date_time_valueDateTime

A timestamp value. Corresponds to the JSON property dateTimeValue

Returns:

  • (DateTime)


640
641
642
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 640

def date_time_value
  @date_time_value
end

#double_valueFloat

A double value. Corresponds to the JSON property doubleValue

Returns:

  • (Float)


645
646
647
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 645

def double_value
  @double_value
end

#entity_valueGoogle::Apis::DatastoreV1beta2::Entity

An entity. Corresponds to the JSON property entityValue



650
651
652
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 650

def entity_value
  @entity_value
end

#indexedBoolean Also known as: indexed?

If the value should be indexed. The indexed property may be set for a null value. When indexed is true, stringValue is limited to 500 characters and the blob value is limited to 500 bytes. Input values by default have indexed set to true; however, you can explicitly set indexed to true if you want. (An output value never has indexed explicitly set to true.) If a value is itself an entity, it cannot have indexed set to true. Corresponds to the JSON property indexed

Returns:

  • (Boolean)


661
662
663
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 661

def indexed
  @indexed
end

#integer_valueString

An integer value. Corresponds to the JSON property integerValue

Returns:

  • (String)


667
668
669
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 667

def integer_value
  @integer_value
end

#key_valueGoogle::Apis::DatastoreV1beta2::Key

A unique identifier for an entity. Corresponds to the JSON property keyValue



672
673
674
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 672

def key_value
  @key_value
end

#list_valueArray<Google::Apis::DatastoreV1beta2::Value>

A list value. Cannot contain another list value. A Value instance that sets field list_value must not set field meaning or field indexed. Corresponds to the JSON property listValue



678
679
680
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 678

def list_value
  @list_value
end

#meaningFixnum

The meaning field is reserved and should not be used. Corresponds to the JSON property meaning

Returns:

  • (Fixnum)


683
684
685
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 683

def meaning
  @meaning
end

#string_valueString

A UTF-8 encoded string value. When indexed is true, may have at most 500 characters. Corresponds to the JSON property stringValue

Returns:

  • (String)


689
690
691
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 689

def string_value
  @string_value
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



696
697
698
699
700
701
702
703
704
705
706
707
708
709
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 696

def update!(**args)
  @blob_key_value = args[:blob_key_value] if args.key?(:blob_key_value)
  @blob_value = args[:blob_value] if args.key?(:blob_value)
  @boolean_value = args[:boolean_value] if args.key?(:boolean_value)
  @date_time_value = args[:date_time_value] if args.key?(:date_time_value)
  @double_value = args[:double_value] if args.key?(:double_value)
  @entity_value = args[:entity_value] if args.key?(:entity_value)
  @indexed = args[:indexed] if args.key?(:indexed)
  @integer_value = args[:integer_value] if args.key?(:integer_value)
  @key_value = args[:key_value] if args.key?(:key_value)
  @list_value = args[:list_value] if args.key?(:list_value)
  @meaning = args[:meaning] if args.key?(:meaning)
  @string_value = args[:string_value] if args.key?(:string_value)
end