Class: RSAC::Token

Inherits:
Object
  • Object
show all
Defined in:
lib/antisamy/csspool/rsac/sac/token.rb

Direct Known Subclasses

DelimiterToken

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, value, position) ⇒ Token

Returns a new instance of Token.



5
6
7
8
9
# File 'lib/antisamy/csspool/rsac/sac/token.rb', line 5

def initialize(name, value, position)
  @name = name
  @value = value
  @position = position
end

Instance Attribute Details

#nameObject (readonly)

Returns the value of attribute name.



3
4
5
# File 'lib/antisamy/csspool/rsac/sac/token.rb', line 3

def name
  @name
end

#positionObject (readonly)

Returns the value of attribute position.



3
4
5
# File 'lib/antisamy/csspool/rsac/sac/token.rb', line 3

def position
  @position
end

#valueObject (readonly)

Returns the value of attribute value.



3
4
5
# File 'lib/antisamy/csspool/rsac/sac/token.rb', line 3

def value
  @value
end

Instance Method Details

#to_racc_tokenObject



11
12
13
# File 'lib/antisamy/csspool/rsac/sac/token.rb', line 11

def to_racc_token
  [name, value]
end