Class: Fbtxt::Parser::Minute

Inherits:
Struct
  • Object
show all
Defined in:
lib/fbtxt/parser/parse_tree-match.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#mObject

Returns the value of attribute m

Returns:

  • (Object)

    the current value of m



289
290
291
# File 'lib/fbtxt/parser/parse_tree-match.rb', line 289

def m
  @m
end

#offsetObject

Returns the value of attribute offset

Returns:

  • (Object)

    the current value of offset



289
290
291
# File 'lib/fbtxt/parser/parse_tree-match.rb', line 289

def offset
  @offset
end

#secsObject

Returns the value of attribute secs

Returns:

  • (Object)

    the current value of secs



289
290
291
# File 'lib/fbtxt/parser/parse_tree-match.rb', line 289

def secs
  @secs
end

Instance Method Details

#as_jsonObject



290
# File 'lib/fbtxt/parser/parse_tree-match.rb', line 290

def as_json(*) to_s; end

#pretty_print(q) ⇒ Object



301
302
303
# File 'lib/fbtxt/parser/parse_tree-match.rb', line 301

def pretty_print( q )
   q.text( to_s )
end

#to_sObject



292
293
294
295
296
297
298
299
# File 'lib/fbtxt/parser/parse_tree-match.rb', line 292

def to_s
  buf = String.new
  buf << "#{m}"
  buf << "'"
  buf << "+#{offset}"      if offset
  buf << "/#{secs} secs"   if secs
  buf
end