Class: Taxonifi::Splitter::Tokens::Variety
- Defined in:
- lib/taxonifi/splitter/tokens.rb
Overview
A token to match variety Matches: var. blorf
-
blorf
Instance Attribute Summary collapse
-
#variety ⇒ Object
readonly
Returns the value of attribute variety.
Attributes inherited from Token
Instance Method Summary collapse
-
#initialize(str) ⇒ Variety
constructor
A new instance of Variety.
Constructor Details
#initialize(str) ⇒ Variety
Returns a new instance of Variety.
312 313 314 315 |
# File 'lib/taxonifi/splitter/tokens.rb', line 312 def initialize (str) str =~ Regexp.new(/\A\s*(var\.\s*|v\.\s*)(\w+)/i) @variety = $2 end |
Instance Attribute Details
#variety ⇒ Object (readonly)
Returns the value of attribute variety.
310 311 312 |
# File 'lib/taxonifi/splitter/tokens.rb', line 310 def variety @variety end |