Advertisement
Guest User

Untitled

a guest
Oct 8th, 2015
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1. delimiters "$", "$"
  2. activate(person) ::= <<$person.personFirstName$>>
  3.  
  4. Person _thePerson = //fetched from database
  5. STGroup group = new STGroupFile(/tmp/email.stg);
  6. ST st = group.getInstanceOf("activate");
  7. st.add("person", _thePerson);
  8. System.out.println("the person first name is: " + _thePerson.personFirstName());
  9. System.out.println(st.render());
  10.  
  11. the person first name is: Ivan
  12. <nothing is returned here>
  13.  
  14. activate(person) ::= <<$person$>>
  15.  
  16. the person first name is: Ivan
  17. 999999999 - Johnson, Ivan G
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement