Class: Deimos::SchemaClass::Record
Overview
Base Class of Record Classes generated from Avro.
Instance Attribute Summary collapse
-
#tombstone_key ⇒ Object
Returns the value of attribute tombstone_key.
Class Method Summary collapse
Instance Method Summary collapse
-
#[] ⇒ Object
Element access method as if this Object were a hash.
-
#full_schema ⇒ String
Returns the full schema name of the inheriting class.
-
#merge ⇒ SchemaClass::Base
Merge a hash or an identical schema object with this one and return a new object.
-
#namespace ⇒ String
Returns the namespace for the schema of the inheriting class.
-
#schema ⇒ String
Returns the schema name of the inheriting class.
-
#schema_fields ⇒ ::Array[String]
@return — an array of fields names in the schema.
-
#to_h ⇒ ::Hash[untyped, untyped]
Converts the object attributes to a hash which can be used for Kafka.
-
#validator ⇒ Deimos::SchemaBackends::Base
Returns the schema validator from the schema backend.
- #with_indifferent_access ⇒ SchemaClass::Record
Methods inherited from Base
#==, #[]=, #as_json, #hash, #initialize, #inspect
Constructor Details
This class inherits a constructor from Deimos::SchemaClass::Base
Instance Attribute Details
#tombstone_key ⇒ Object
Returns the value of attribute tombstone_key.
802 803 804 |
# File 'sig/defs.rbs', line 802 def tombstone_key @tombstone_key end |
Class Method Details
.initialize_from_value ⇒ SchemaClass::Record
799 |
# File 'sig/defs.rbs', line 799
def self.initialize_from_value: (Object value) -> SchemaClass::Record
|
Instance Method Details
#[] ⇒ Object
Element access method as if this Object were a hash
@param key
@return — The value of the attribute if exists, nil otherwise
780 |
# File 'sig/defs.rbs', line 780
def []: ((String | Symbol) key) -> Object
|
#full_schema ⇒ String
Returns the full schema name of the inheriting class.
791 |
# File 'sig/defs.rbs', line 791
def full_schema: () -> String
|
#merge ⇒ SchemaClass::Base
Merge a hash or an identical schema object with this one and return a new object.
@param other_hash
773 |
# File 'sig/defs.rbs', line 773
def merge: ((::Hash[untyped, untyped] | SchemaClass::Base) other_hash) -> SchemaClass::Base
|
#namespace ⇒ String
Returns the namespace for the schema of the inheriting class.
788 |
# File 'sig/defs.rbs', line 788
def namespace: () -> String
|
#schema ⇒ String
Returns the schema name of the inheriting class.
785 |
# File 'sig/defs.rbs', line 785
def schema: () -> String
|
#schema_fields ⇒ ::Array[String]
@return — an array of fields names in the schema.
797 |
# File 'sig/defs.rbs', line 797
def schema_fields: () -> ::Array[String]
|
#to_h ⇒ ::Hash[untyped, untyped]
Converts the object attributes to a hash which can be used for Kafka
@return — the payload as a hash.
768 |
# File 'sig/defs.rbs', line 768
def to_h: () -> ::Hash[untyped, untyped]
|
#validator ⇒ Deimos::SchemaBackends::Base
Returns the schema validator from the schema backend
794 |
# File 'sig/defs.rbs', line 794
def validator: () -> Deimos::SchemaBackends::Base
|
#with_indifferent_access ⇒ SchemaClass::Record
782 |
# File 'sig/defs.rbs', line 782
def with_indifferent_access: () -> SchemaClass::Record
|