Flowdock
class
Importance_1
v1_8_7_330 - Show latest stable - 0 notes - Superclass: Object

Property stream format:

line separator is \r?\n.  1 line per a property.
line which begins with '#' is a comment line.  empty line is ignored, too.
key/value separator is ':' or '='.
'\' as escape character.  but line separator cannot be escaped.
\s at the head/tail of key/value are trimmed.

'[' + key + ']' indicates property section.  for example,

  [aaa.bbb]
  ccc = ddd
  eee.fff = ggg
  []
  aaa.hhh = iii

is the same as;

  aaa.bbb.ccc = ddd
  aaa.bbb.eee.fff = ggg
  aaa.hhh = iii

Constants

NO_HOOK = [].freeze

LINE_REGEXP = Regexp.new("^#{DEF_REGSRC}$")

CATDEF_REGEXP = Regexp.new("^\\[\\s*#{KEY_REGSRC}\\s*\\]$")

COMMENT_REGEXP = Regexp.new('^(?:#.*|)$')

DEF_REGSRC = '\\s*' + KEY_REGSRC + '\\s*[=:]\\s*(.*)'

KEY_REGSRC = '([^=:\\\\]*(?:\\\\.[^=:\\\\]*)*)'

FrozenError = (RUBY_VERSION >= "1.9.0") ? RuntimeError : TypeError

Attributes

Show files where this class is defined (1 file)
Register or log in to add new notes.