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

Method convertAnythingToIterator

output/java/1.4.19/Interpreter.java:1178–1184  ·  view source on GitHub ↗
(InstanceScope scope, Object o)

Source from the content-addressed store, hash-verified

1176 }
1177
1178 public Iterator<?> convertAnythingToIterator(InstanceScope scope, Object o) {
1179 o = convertAnythingIteratableToIterator(scope, o);
1180 if ( o instanceof Iterator) return (Iterator<?>)o;
1181 List<Object> singleton = new ST.AttributeList(1);
1182 singleton.add(o);
1183 return singleton.iterator();
1184 }
1185
1186 protected boolean testAttributeTrue(Object a) {
1187 if ( a==null ) return false;

Callers 1

zip_mapMethod · 0.95

Calls 3

addMethod · 0.65
iteratorMethod · 0.65

Tested by

no test coverage detected