Class: Avro::Schema::ArraySchema
- Inherits:
-
Schema
- Object
- Schema
- Avro::Schema::ArraySchema
- Defined in:
- lib/avro/schema.rb
Instance Attribute Summary collapse
-
#items ⇒ Object
readonly
Returns the value of attribute items.
Instance Method Summary collapse
-
#initialize(items, names = nil, default_namespace = nil) ⇒ ArraySchema
constructor
A new instance of ArraySchema.
- #to_avro(names = Set.new) ⇒ Object
Constructor Details
#initialize(items, names = nil, default_namespace = nil) ⇒ ArraySchema
Returns a new instance of ArraySchema.
375 376 377 378 |
# File 'lib/avro/schema.rb', line 375 def initialize(items, names=nil, default_namespace=nil) super(:array) @items = subparse(items, names, default_namespace) end |
Instance Attribute Details
#items ⇒ Object (readonly)
Returns the value of attribute items.
373 374 375 |
# File 'lib/avro/schema.rb', line 373 def items @items end |
Instance Method Details
#to_avro(names = Set.new) ⇒ Object
380 381 382 |
# File 'lib/avro/schema.rb', line 380 def to_avro(names=Set.new) super.merge('items' => items.to_avro(names)) end |