Package org.opencustomer.framework.db.util.engine.configuration

Examples of org.opencustomer.framework.db.util.engine.configuration.Entity


            throw new TableEngineException("could not load engine", e);
        }
    }
   
    private Entity parseEntity(Node node) throws TableEngineException {
        Entity entity = new Entity();
       
        NamedNodeMap attributes = node.getAttributes();
        for(int i=0; i<attributes.getLength(); i++) {
            Node attributeNode = attributes.item(i);
            if(attributeNode.getNodeType() == Node.ATTRIBUTE_NODE) {
                String name = attributeNode.getNodeName();
                if("class".equals(name)) {
                    try {
                    entity.setClazz((Class<? extends BaseVO>)Class.forName(attributeNode.getNodeValue()));
                    } catch(ClassNotFoundException e) {
                        throw new TableEngineException(e);
                    }
                } else if("alias".equals(name)) {
                    entity.setAlias(attributeNode.getNodeValue());
                } else if("messageKey".equals(name)) {
                    entity.setMessageKey(attributeNode.getNodeValue());
                }
            }
        }
       
        return entity;
View Full Code Here

TOP

Related Classes of org.opencustomer.framework.db.util.engine.configuration.Entity

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.