Main { static void die(String reason) (@ System.err.println(reason); System.exit(1); @) static void die(Throwable e) (@ e.printStackTrace(); die(e.getMessage()); @) } TypeDecl { public abstract String image(); } ReturnDecl { public String image() (@ return prefix+suffix; @) } Constant { public String image()(@ return get_image(); @) } ArgumentDecl { public String image() (@ StringBuffer value = new StringBuffer(prefix); value.append(" "); value.append(get_name().get_value()); value.append(suffix); return value.toString(); @) } CodeCategory { protected String expandPattern(Entity entity, String pattern) (@ String entityName = entity.get_name().get_value(); return Main.om.substitute("s%\\$\\[Entity\\]%"+entityName+"%g",pattern); @) String className(Entity entity) (@ return expandPattern(entity,get_classNamePattern()); @) File headerFile(Entity entity) (@ return new File(expandPattern(entity,get_headerNamePattern())); @) } GeneratedCodeCategory{ File implFile(Entity entity) (@ return new File(expandPattern(entity,get_implNamePattern())); @) } AccessKeyList{ public boolean intersects(AccessKeyList other) to AccessKey { (@ boolean result;@) init (@ result = false; @) return (@ result; @) before AccessKey (@ if(other.contains(host)) result = true; @) } } SourceList { init (@ set_value(new String_List(null)); @) void add(String fileName) (@ get_value().addElement(fileName); @) boolean isEmpty() (@ return get_value().isEmpty(); @) }