Package org.boco.seamwebappgen.annotations

Examples of org.boco.seamwebappgen.annotations.LocalSearchOnAttribute


        SearchAttribute attr = new SearchAttribute(fields[j].getName());

        attr.setType(fields[j].getType().getName());
        attr.setKey(isKey(cBean, fields[j]));

        LocalSearchOnAttribute annotation = fields[j].getAnnotation(LocalSearchOnAttribute.class);

        if (fields[j].getAnnotation(ShowInForm.class) != null)
        {
          ShowInForm showAnnotation = fields[j].getAnnotation(ShowInForm.class);

          attr.setImplementationType(showAnnotation.type());

          Vector<String> tmp1 = new Vector<String>();
          tmp1 = new Vector<String>();
          for (int i = 0; i < showAnnotation.labels().length; i++)
          {
            tmp1.add(showAnnotation.labels()[i]);
          }
          attr.setLabels(tmp1);
        }
        else
          attr.setImplementationType(AttributeImplementationType.TEXT);

        attr.setOrderInForm(annotation.order());

        String events[] = annotation.events();
        for (int i = 0; i < events.length; i++)
          attr.addEvent(events[i]);

        String eventFunctions[] = annotation.eventFunctions();
        for (int i = 0; i < events.length; i++)
          attr.addEventFunction(eventFunctions[i]);

        tmp.add(attr);
      }
    }

    // Attributi delle relazioni collegate al bean

    Method methods[] = cBean.getDeclaredMethods();

    /** Ordinamento degli attributi per nome **/

    java.util.Arrays.sort(methods, new JavaMethodComparator());

    for (int j = 0; j < methods.length; j++)
    {
      Annotation annotations[] = methods[j].getAnnotations();

      for (int k = 0; k < annotations.length; k++)
      {
        Annotation annotation = annotations[k];

        if (annotation.annotationType().equals(org.boco.seamwebappgen.annotations.LocalSearchOnRelationship.class))
        {
          String attributesName[] = ((org.boco.seamwebappgen.annotations.LocalSearchOnRelationship) annotation).attributes();
          String relationshipName = methods[j].getName();
          Relationship relationship = null;

View Full Code Here

TOP

Related Classes of org.boco.seamwebappgen.annotations.LocalSearchOnAttribute

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.