/** * From the real className of an object, gets a displayable name. * * @param obj the object for which we want the class name to display - the object must not be null * * @return the classname to display in the view. */ public static String getDisplayableClassName( Object obj ) { return getDisplayableClassName( getRealClassName( obj ) ); }
/** * Gives the Object classname, give the real object class name if this is a VirtualProxy class * * @param obj the object for which we request the real class name. * * @return the real class name. */ public static <T> Class<T> getRealClassName( T obj ) { return removeCglibEnhanced( obj.getClass() ); }
CgLibUtil.getRealClassName( cvObject ).getName(), cvObject.getIdentifier(), annotation.getCvTopic().getShortLabel(),
/** * From the real className of className, gets a displayable name. * * @param clazz the class for which we want the class name to display - the class must not be null * * @return the classname to display in the view. */ public static String getDisplayableClassName( Class clazz ) { return getDisplayableClassName( clazz.getName() ); }
/** * From the real className of className, gets a displayable name. * * @param clazz the class for which we want the class name to display - the class must not be null * * @return the classname to display in the view. */ public static String getDisplayableClassName( Class clazz ) { return getDisplayableClassName( clazz.getName() ); }
/** * Gives the Object classname, give the real object class name if this is a VirtualProxy class * * @param obj the object for which we request the real class name. * * @return the real class name. */ public static <T> Class<T> getRealClassName( T obj ) { return removeCglibEnhanced( obj.getClass() ); }
/** * From the real className of an object, gets a displayable name. * * @param obj the object for which we want the class name to display - the object must not be null * * @return the classname to display in the view. */ public static String getDisplayableClassName( Object obj ) { return getDisplayableClassName( getRealClassName( obj ) ); }
@Column( name = "objclass", insertable = false, updatable = false ) public String getObjClass() { if (objClass == null) { objClass = CgLibUtil.removeCglibEnhanced( getClass() ).getName(); } return objClass; }
@Column( name = "objclass", insertable = false, updatable = false ) public String getObjClass() { if (objClass == null) { objClass = CgLibUtil.removeCglibEnhanced( getClass() ).getName(); } return objClass; }
public static String intactObjectToString(IntactObject io, boolean showAttributesCount) { if (io instanceof AnnotatedObject) { return annotatedObjectToString((AnnotatedObject) io, showAttributesCount); } Class clazz = CgLibUtil.removeCglibEnhanced(io.getClass()); StringBuilder sb = new StringBuilder(); sb.append(clazz.getSimpleName()).append(", ac=").append(io.getAc()).append("}"); return sb.toString(); } }
public static String intactObjectToString(IntactObject io, boolean showAttributesCount) { if (io instanceof AnnotatedObject) { return annotatedObjectToString((AnnotatedObject) io, showAttributesCount); } Class clazz = CgLibUtil.removeCglibEnhanced(io.getClass()); StringBuilder sb = new StringBuilder(); sb.append(clazz.getSimpleName()).append(", ac=").append(io.getAc()).append("}"); return sb.toString(); } }
public AnnotatedObjectStatsUnit(AnnotatedObject ao) { this.shortLabel = ao.getShortLabel(); this.ac = ao.getAc(); this.type = CgLibUtil.removeCglibEnhanced(ao.getClass()); }
protected Key keyForAnnotatedObject(AnnotatedObject annotatedObject) { Class normalizedClass = CgLibUtil.removeCglibEnhanced(annotatedObject.getClass()); return new Key(normalizedClass.getSimpleName() + ":" + annotatedObject.getShortLabel()); }
protected Key keyForAnnotatedObject(AnnotatedObject annotatedObject) { Class normalizedClass = CgLibUtil.removeCglibEnhanced(annotatedObject.getClass()); return new Key(normalizedClass.getSimpleName() + ":" + annotatedObject.getShortLabel()); }
/** * Get an item using its AC * * @param ac the identifier * * @return the object */ public T getByAc( String ac ) { return ( T ) getSession().get( CgLibUtil.removeCglibEnhanced( getEntityClass() ), ac ); }
/** * Get an item using its AC * * @param ac the identifier * * @return the object */ public T getByAc( String ac ) { return ( T ) getSession().get( CgLibUtil.removeCglibEnhanced( getEntityClass() ), ac ); }
public AnnotatedObjectStatsUnit(AnnotatedObject ao) { this.shortLabel = ao.getShortLabel(); this.ac = ao.getAc(); this.type = CgLibUtil.removeCglibEnhanced(ao.getClass()); }
/** * Gets the generic Xref type for an AnnotatedObject class * * @param clazz an AnnotatedObject class * @return the Xref type used in the class * @since 1.6.1 */ public static Class<? extends Alias> getAliasClassType(Class<? extends AnnotatedObject> clazz) { clazz = CgLibUtil.removeCglibEnhanced(clazz); PropertyDescriptor propDesc = null; try { propDesc = new PropertyDescriptor("aliases", clazz); } catch (IntrospectionException e) { e.printStackTrace(); } Method method = propDesc.getReadMethod(); return getParameterizedType(method.getGenericReturnType()); }
/** * Gets the generic Xref type for an AnnotatedObject class * * @param clazz an AnnotatedObject class * @return the Xref type used in the class */ public static Class<? extends Xref> getXrefClassType(Class<? extends AnnotatedObject> clazz) { clazz = CgLibUtil.removeCglibEnhanced(clazz); PropertyDescriptor propDesc = null; try { propDesc = new PropertyDescriptor("xrefs", clazz); } catch (IntrospectionException e) { e.printStackTrace(); } Method method = propDesc.getReadMethod(); return getParameterizedType(method.getGenericReturnType()); }
/** * Gets the generic Xref type for an AnnotatedObject class * * @param clazz an AnnotatedObject class * @return the Xref type used in the class */ public static Class<? extends Xref> getXrefClassType(Class<? extends AnnotatedObject> clazz) { clazz = CgLibUtil.removeCglibEnhanced(clazz); PropertyDescriptor propDesc = null; try { propDesc = new PropertyDescriptor("xrefs", clazz); } catch (IntrospectionException e) { e.printStackTrace(); } Method method = propDesc.getReadMethod(); return getParameterizedType(method.getGenericReturnType()); }