public Attribute getEntityAttribute(Class clazz, String fieldName)
    {
        if (entityTypes != null && entityTypes.containsKey(clazz))
        {
            EntityType entityType = entityTypes.get(clazz);
            return entityType.getAttribute(fieldName);
        }
        throw new IllegalArgumentException("No entity found: " + clazz);
    }
public Attribute getEntityAttribute ( Class clazz , String fieldName ) { if ( entityTypes != null && entityTypes . containsKey ( clazz ) ) { EntityType entityType = entityTypes . get ( clazz ) ; return entityType . getAttribute ( fieldName ) ; } throw new IllegalArgumentException ( "No entity found: " + clazz ) ; }
Returns entity attribute for given managed entity class.

@param clazz
Entity class
@param fieldName
field name
@return entity attribute