Class: Lutaml::Model::Schema::RngCompiler::MemberCollector

Inherits:
Object
  • Object
show all
Defined in:
lib/lutaml/model/schema/rng_compiler/member_collector.rb

Overview

Lightweight accumulator used by ElementVisitor when collecting the children of a transient construct (<group>, <choice>) before promoting them into a Definitions::Sequence or Definitions::Choice on the real Definitions::Model.

Mirrors the surface ElementVisitor expects on a model (members, imports, mixed, text_content) but with no XML root, documentation, or namespace — none of which apply to a scratch container.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeMemberCollector

Returns a new instance of MemberCollector.



20
21
22
23
24
25
# File 'lib/lutaml/model/schema/rng_compiler/member_collector.rb', line 20

def initialize
  @members = []
  @imports = []
  @mixed = false
  @text_content = false
end

Instance Attribute Details

#importsObject (readonly)

Returns the value of attribute imports.



17
18
19
# File 'lib/lutaml/model/schema/rng_compiler/member_collector.rb', line 17

def imports
  @imports
end

#membersObject (readonly)

Returns the value of attribute members.



17
18
19
# File 'lib/lutaml/model/schema/rng_compiler/member_collector.rb', line 17

def members
  @members
end

#mixedObject

Returns the value of attribute mixed.



18
19
20
# File 'lib/lutaml/model/schema/rng_compiler/member_collector.rb', line 18

def mixed
  @mixed
end

#text_contentObject

Returns the value of attribute text_content.



18
19
20
# File 'lib/lutaml/model/schema/rng_compiler/member_collector.rb', line 18

def text_content
  @text_content
end