Class: Stark::Parser::AST::Field

Inherits:
Node
  • Object
show all
Defined in:
lib/stark/ast.rb,
lib/stark/raw_parser.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(index, type, name, value, options) ⇒ Field

Returns a new instance of Field.



420
421
422
423
424
425
426
# File 'lib/stark/raw_parser.rb', line 420

def initialize(index, type, name, value, options)
  @index = index
  @type = type
  @name = name
  @value = value
  @options = options
end

Instance Attribute Details

#indexObject (readonly)

Returns the value of attribute index.



427
428
429
# File 'lib/stark/raw_parser.rb', line 427

def index
  @index
end

#nameObject (readonly)

Returns the value of attribute name.



429
430
431
# File 'lib/stark/raw_parser.rb', line 429

def name
  @name
end

#optionsObject (readonly)

Returns the value of attribute options.



431
432
433
# File 'lib/stark/raw_parser.rb', line 431

def options
  @options
end

#typeObject (readonly)

Returns the value of attribute type.



428
429
430
# File 'lib/stark/raw_parser.rb', line 428

def type
  @type
end

#valueObject (readonly)

Returns the value of attribute value.



430
431
432
# File 'lib/stark/raw_parser.rb', line 430

def value
  @value
end

Instance Method Details

#accept(obj) ⇒ Object



24
25
26
# File 'lib/stark/ast.rb', line 24

def accept(obj)
  obj.process_field self
end