Class: Google::Apis::DatastoreV1beta3::PropertyTransform

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

Overview

A transformation of an entity property.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ PropertyTransform

Returns a new instance of PropertyTransform.



1935
1936
1937
# File 'lib/google/apis/datastore_v1beta3/classes.rb', line 1935

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

Instance Attribute Details

#append_missing_elementsGoogle::Apis::DatastoreV1beta3::ArrayValue

An array value. Corresponds to the JSON property appendMissingElements



1896
1897
1898
# File 'lib/google/apis/datastore_v1beta3/classes.rb', line 1896

def append_missing_elements
  @append_missing_elements
end

#incrementGoogle::Apis::DatastoreV1beta3::Value

A message that can hold any of the supported value types and associated metadata. Corresponds to the JSON property increment



1902
1903
1904
# File 'lib/google/apis/datastore_v1beta3/classes.rb', line 1902

def increment
  @increment
end

#maximumGoogle::Apis::DatastoreV1beta3::Value

A message that can hold any of the supported value types and associated metadata. Corresponds to the JSON property maximum



1908
1909
1910
# File 'lib/google/apis/datastore_v1beta3/classes.rb', line 1908

def maximum
  @maximum
end

#minimumGoogle::Apis::DatastoreV1beta3::Value

A message that can hold any of the supported value types and associated metadata. Corresponds to the JSON property minimum



1914
1915
1916
# File 'lib/google/apis/datastore_v1beta3/classes.rb', line 1914

def minimum
  @minimum
end

#propertyString

Optional. The name of the property. Property paths (a list of property names separated by dots (.)) may be used to refer to properties inside entity values. For example foo.bar means the property bar inside the entity property foo. If a property name contains a dot . or a backlslash \, then that name must be escaped. Corresponds to the JSON property property

Returns:

  • (String)


1923
1924
1925
# File 'lib/google/apis/datastore_v1beta3/classes.rb', line 1923

def property
  @property
end

#remove_all_from_arrayGoogle::Apis::DatastoreV1beta3::ArrayValue

An array value. Corresponds to the JSON property removeAllFromArray



1928
1929
1930
# File 'lib/google/apis/datastore_v1beta3/classes.rb', line 1928

def remove_all_from_array
  @remove_all_from_array
end

#set_to_server_valueString

Sets the property to the given server value. Corresponds to the JSON property setToServerValue

Returns:

  • (String)


1933
1934
1935
# File 'lib/google/apis/datastore_v1beta3/classes.rb', line 1933

def set_to_server_value
  @set_to_server_value
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1940
1941
1942
1943
1944
1945
1946
1947
1948
# File 'lib/google/apis/datastore_v1beta3/classes.rb', line 1940

def update!(**args)
  @append_missing_elements = args[:append_missing_elements] if args.key?(:append_missing_elements)
  @increment = args[:increment] if args.key?(:increment)
  @maximum = args[:maximum] if args.key?(:maximum)
  @minimum = args[:minimum] if args.key?(:minimum)
  @property = args[:property] if args.key?(:property)
  @remove_all_from_array = args[:remove_all_from_array] if args.key?(:remove_all_from_array)
  @set_to_server_value = args[:set_to_server_value] if args.key?(:set_to_server_value)
end