String ocFactoryName,
boolean retain,
Object... args) {
if (logging.isTraceEnabled()) {
logging.trace("creating [{} ({})].{}({})",
new Object[] {ocClassName, javaClass.getName(), ocFactoryName, new VarArgsUnpacker(args)});
}
ID ocClass = Foundation.getClass(ocClassName);
ID ocInstance = Foundation.send(ocClass, ocFactoryName, ID.class, args);
int initialRetainCount = Foundation.cfGetRetainCount(ocInstance);
T result = wrap(ocInstance, javaClass, retain);