Package org.paquitosoft.lml.model.annotation

Examples of org.paquitosoft.lml.model.annotation.PersistentEntity


     */
    public static String getTableName(Class entityClass) {
       
        String result = entityClass.getSimpleName();
       
        PersistentEntity att = (PersistentEntity) entityClass.getAnnotation(PersistentEntity.class);
        if (att != null && att.tableName().length() > 0) {
            result = att.tableName();
        }
       
        return result.toUpperCase();
    }
View Full Code Here


     * @param entityClass
     * @return <b>true</b> when entity's primary key is generated by the database
     */
    public static boolean isEntityPKGeneratedByDatabase(Class entityClass) {
        boolean result = true;
        PersistentEntity pr = (PersistentEntity) entityClass.getAnnotation(PersistentEntity.class);
        if (pr != null && pr.generateKey()) {
            result = false;
        }
        return result;
    }
View Full Code Here

TOP

Related Classes of org.paquitosoft.lml.model.annotation.PersistentEntity

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.