void passthru(ST self, String templateName, Map<String,Object> attrs) { CompiledST c = group.lookupTemplate(templateName); if ( c==null ) return; // will get error later for (FormalArgument arg : c.formalArguments.values()) { // if not already set by user, set to value from outer scope if ( !attrs.containsKey(arg.name) ) { //System.out.println("arg "+arg.name+" missing"); try { Object o = getAttribute(self, arg.name); // If the attribute exists but there is no value and // the formal argument has no default value, make it null. if ( o==ST.EMPTY_ATTR && arg.defaultValueToken==null ) { attrs.put(arg.name, null); } // Else, the attribute has an existing value, set arg. else if ( o!=ST.EMPTY_ATTR ) { attrs.put(arg.name, o); } } catch (STNoSuchAttributeException nsae) { // if no such attribute exists for arg.name, set parameter // if no default value if ( arg.defaultValueToken==null ) { attrs.put(arg.name, null); } } } } }
Object o = getAttribute(scope, arg.name);
Object o = getAttribute(scope, arg.name);
Object o = getAttribute(scope, arg.name);
Object o = getAttribute(scope, arg.name);
Object o = getAttribute(scope, arg.name);
Object o = getAttribute(scope, arg.name);
Object o = getAttribute(scope, arg.name);
name = self.impl.strings[nameIndex]; try { o = getAttribute(self, name); if ( o==ST.EMPTY_ATTR ) o = null;
name = self.impl.strings[nameIndex]; try { o = getAttribute(scope, name); if ( o==ST.EMPTY_ATTR ) o = null;
name = self.impl.strings[nameIndex]; try { o = getAttribute(scope, name); if ( o==ST.EMPTY_ATTR ) o = null;
name = self.impl.strings[nameIndex]; try { o = getAttribute(scope, name); if ( o==ST.EMPTY_ATTR ) o = null;
name = self.impl.strings[nameIndex]; try { o = getAttribute(scope, name); if ( o==ST.EMPTY_ATTR ) o = null;
name = self.impl.strings[nameIndex]; try { o = getAttribute(scope, name); if ( o==ST.EMPTY_ATTR ) o = null;
name = self.impl.strings[nameIndex]; try { o = getAttribute(scope, name); if ( o==ST.EMPTY_ATTR ) o = null;
name = self.impl.strings[nameIndex]; try { o = getAttribute(scope, name); if ( o==ST.EMPTY_ATTR ) o = null;