YAML usage summary

For a number of reasons (e.g., expressiveness, flexibility, readability), I have opted to encode Ontiki's upper-level definitions as a tree of text files, using a simple subset of YAML. The tree, which roughly matches the class hierarchy, is easy to edit in TextMate.

Specifically, I use YAML to encode hashes, lists, and strings. Within this syntax, however, I have defined several idioms and tags.

Idioms

Assorted idioms are used for brevity, clarity, etc.

  • _ - the current class, in a pat(tern) or rel(ation)

  • _1 - role 1, in a pat(tern)

  • [[abc]] - MediaWiki link to page 'abc'

  • is_related_X - X may be from, to, or with. The first two relationships are not reflexive; the last one is.

Tags

The top-level tag in each file is the name of the class (e.g., AC_foo'). The second-level tags encode information about the class: