private T newContextObject() { try { if (type.isInterface()) { return (T) Classes.newDynamicProxy(type); } else { return (T) type.newInstance(); } } catch (Exception anExc) { throw new XmlReadingException(anExc); } }
public boolean isEqualsOnly(final Node node) { final Class<?> propertyType = node.getType(); if (propertyType != null) { if (propertyType.getAnnotation(ObjectDiffEqualsOnlyType.class) != null) { return true; } if (equalsOnlyTypes.contains(propertyType)) { return true; } if (Classes.isSimpleType(propertyType)) { return true; } } if (node.isEqualsOnly()) { return true; } if (equalsOnlyProperties.contains(node.getPropertyPath())) { return true; } return false; }
private void installClasses(Classes cs) { for (Enumeration e = cs.getElements(); e.hasMoreElements(); ) { installClass(new CgenNode((Class_) e.nextElement(), CgenNode.NotBasic, this)); } }
public ContextMutator(Class<?> aFor, Class<T> aWith, String aTagName) { method = Classes.getMutatorMethod(aFor, aWith.getSimpleName(), aTagName); }