Package br.net.woodstock.rockframework.core.reflection

Examples of br.net.woodstock.rockframework.core.reflection.ClassFinder


    super();
  }

  public XmlDocument toXML(final String baseName) {
    Assert.notEmpty(baseName, "baseName");
    ClassFinder classFinder = new ClassFinderImpl(baseName, new AnnotationClassFilter(Entity.class));
    XmlDocument document = new XmlDocument(AnnotationToXML.XML_NAMESPACE, AnnotationToXML.XML_LOCATION, AnnotationToXML.XML_ROOT);
    XmlElement entityMappings = document.getRoot();

    for (Class<?> clazz : classFinder.getClasses()) {
      XmlElement entity = entityMappings.addElement("entity");
      entity.setAttribute("class", clazz.getCanonicalName());
      entity.setAttribute("access", "PROPERTY");
      entity.setAttribute("metadata-complete", "true");
View Full Code Here


  }

  public Collection<String> getErrors(final String baseName) {
    Assert.notEmpty(baseName, "baseName");
    Collection<String> collection = new ArrayList<String>();
    ClassFinder classFinder = new ClassFinderImpl(baseName, new AssignableClassFilter(Entity.class));
    for (Class<?> clazz : classFinder.getClasses()) {
      BeanDescriptor beanDescriptor = new BeanDescriptorBuilder(clazz).getBeanDescriptor();
      for (PropertyDescriptor propertyDescriptor : beanDescriptor.getProperties()) {
        String name = propertyDescriptor.getName();
        if (propertyDescriptor.isAnnotationPresent(Column.class)) {
          if (propertyDescriptor.isAnnotationPresent(Enumerated.class)) {
View Full Code Here

TOP

Related Classes of br.net.woodstock.rockframework.core.reflection.ClassFinder

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.