MCPcopy Index your code
hub / github.com/antlr/codebuff / lookupImportedTemplate

Method lookupImportedTemplate

output/java8/1.4.17/STGroup.java:300–312  ·  view source on GitHub ↗
(String name)

Source from the content-addressed store, hash-verified

298 }
299
300 protected CompiledST lookupImportedTemplate(String name) {
301 if ( imports.size()==0 ) return null;
302 for (STGroup g : imports) {
303 if ( verbose ) System.out.println("checking "+g.getName()+" for imported "+name);
304 CompiledST code = g.lookupTemplate(name);
305 if ( code!=null ) {
306 if ( verbose ) System.out.println(g.getName()+".lookupImportedTemplate("+name+") found");
307 return code;
308 }
309 }
310 if ( verbose ) System.out.println(name+" not found in "+getName()+" imports");
311 return null;
312 }
313
314 public CompiledST rawGetTemplate(String name) {
315 return templates.get(name);

Callers 2

lookupTemplateMethod · 0.95
super_newMethod · 0.45

Calls 3

getNameMethod · 0.95
sizeMethod · 0.65
lookupTemplateMethod · 0.45

Tested by

no test coverage detected