MCPcopy Create free account
hub / github.com/antlr/codebuff / getObjectProperty

Method getObjectProperty

output/java/1.4.19/Interpreter.java:1198–1212  ·  view source on GitHub ↗
(STWriter out, InstanceScope scope, Object o, Object property)

Source from the content-addressed store, hash-verified

1196 }
1197
1198 protected Object getObjectProperty(STWriter out, InstanceScope scope, Object o, Object property) {
1199 if ( o==null ) {
1200 errMgr.runTimeError(this, scope, ErrorType.NO_SUCH_PROPERTY, "null."+property);
1201 return null;
1202 }
1203 try {
1204 final ST self = scope.st;
1205 ModelAdaptor adap = self.groupThatCreatedThisInstance.getModelAdaptor(o.getClass());
1206 return adap.getProperty(this, self, o, property, toString(out, scope, property));
1207 }
1208 catch (STNoSuchPropertyException e) {
1209 errMgr.runTimeError(this, scope, ErrorType.NO_SUCH_PROPERTY, e, o.getClass().getName()+"."+property);
1210 }
1211 return null;
1212 }
1213
1214 /**
1215 * Find an attribute via dynamic scoping up enclosing scope chain. Only look

Callers 1

_execMethod · 0.95

Calls 5

getPropertyMethod · 0.95
toStringMethod · 0.95
runTimeErrorMethod · 0.65
getModelAdaptorMethod · 0.45
getNameMethod · 0.45

Tested by

no test coverage detected