Class: Jaina::Parser::Tokenizer::Token Private

Inherits:
Object
  • Object
show all
Defined in:
lib/jaina/parser/tokenizer/token.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

Since:

  • 0.4.0

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(raw_token, token, *arguments) ⇒ void

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Parameters:

  • raw_token (String)
  • token (String)
  • arguments (Array<Any>)

Since:

  • 0.4.0



31
32
33
34
35
# File 'lib/jaina/parser/tokenizer/token.rb', line 31

def initialize(raw_token, token, *arguments)
  @raw_token = raw_token
  @token = token
  @arguments = arguments
end

Instance Attribute Details

#argumentsArray<String> (readonly)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns:

  • (Array<String>)

Since:

  • 0.4.0



22
23
24
# File 'lib/jaina/parser/tokenizer/token.rb', line 22

def arguments
  @arguments
end

#raw_tokenString (readonly)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns:

  • (String)

Since:

  • 0.4.0



10
11
12
# File 'lib/jaina/parser/tokenizer/token.rb', line 10

def raw_token
  @raw_token
end

#tokenString (readonly)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns:

  • (String)

Since:

  • 0.4.0



16
17
18
# File 'lib/jaina/parser/tokenizer/token.rb', line 16

def token
  @token
end

Instance Method Details

#dupJaina::Parser::Tokenizer::Token

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns:

Since:

  • 0.4.0



41
42
43
# File 'lib/jaina/parser/tokenizer/token.rb', line 41

def dup
  self.class.new(raw_token.dup, token.dup, *arguments.dup)
end

#to_sString

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns:

  • (String)

Since:

  • 0.4.0



49
50
51
# File 'lib/jaina/parser/tokenizer/token.rb', line 49

def to_s
  raw_token
end