Package com.onpositive.commons.ui.tableeditor

Examples of com.onpositive.commons.ui.tableeditor.Field


  private void appendNeededFields(Map<String, Field> fields,
      Collection<String> ks) {
    for (String us : persistentFields.keySet()) {
      if (ks.contains(us)) {
        Field f = fields.get(us);
        Class type = null;
        if (persistentFields.containsKey(us)) {
          type = persistentFields.get(us);
        }
        if (f.getType() == null) {
          f.setType(type);
          if (Collection.class.isAssignableFrom(type)) {
            ((GAEField) f).multiplicity = true;
            f.setType(null);
          }
        }
        continue;
      }
      GAEField f = new GAEField(us, true);
      // f.setKeyKind(kind);
      Class type = null;
      if (persistentFields.containsKey(us)) {
        type = persistentFields.get(us);
      }

      updateValues(us, null);
      f.setType(type);
      if (Collection.class.isAssignableFrom(type)) {
        f.multiplicity = true;
        f.setType(null);
      }

      fields.put(f.name, f);
    }
  }
View Full Code Here


      Class type = null;
      if (fi.getFieldType() != null) {
        type = fi.getFieldType();
      }
      if (determined.contains(us)) {
        Field f = fields.get(us);
        if (f.getType() == null) {
          f.setType(type);
        }
        continue;
      }
      GAEField f = new GAEField(us, true);
      // f.setKeyKind(kind);

      f.setType(type);
      updateValues(us, null);

      fields.put(f.name, f);
    }
View Full Code Here

      }

    }

    protected void setPropValue(String b, Binding binding, Object value) {
      Field f = facade.getField(b);
      Object val = null;
      if (f != null) {
        if (f.getType() != null) {
          Class<?> type = f.getType();
          if (value instanceof Collection) {
            val = new ArrayList<Object>();
            Collection<?> coll = (Collection<?>) value;
            for (Iterator<?> i = coll.iterator(); i.hasNext();) {
              Object nxt = i.next();
View Full Code Here

TOP

Related Classes of com.onpositive.commons.ui.tableeditor.Field

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.