[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Deciding on XDI spec template variable formatting convention
Joseph asked about the syntax we are using for variables in specification template code, i.e., for “spec variables” vs. “XDI variables”. For an example, see the XDI Message Patterns wiki page.
Joseph’s suggestion is to start using ALLCAPS in bold.
Phil suggested using a colon as the prefix character, however a colon is a legal XDI syntax character, so the worry is that it would cause confustion.
Drummond’s suggestion is that we do both except using % as the prefix character (since it is not a legal XDI syntax character except for escape encoding, which should not appear in spec templates), plus ALLCAPS in bold, e.g., %FROM. The reason for the prefix character is that it allows multiple variables to appear contiguously (as we do have in some spec templates).
Example of old approach:
<--from-peer-->/$set/<--from-->[$msg]<--msg-id-->
Example of new approach:
%FROM-PEER/$set/%FROM[$msg]%MSG-ID[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]