Package org.objectweb.speedo.metadata

Examples of org.objectweb.speedo.metadata.SpeedoCollection


    if (sf.jdoTuple instanceof SpeedoMap) {
      SpeedoMap sm = (SpeedoMap) sf.jdoTuple;
      sm.keyType = toJavaFQN((String) sm.keyType);
      sm.valueType = toJavaFQN((String) sm.valueType);
    } else if (sf.jdoTuple instanceof SpeedoCollection) {
      SpeedoCollection sc = (SpeedoCollection) sf.jdoTuple;
      sc.elementType = toJavaFQN((String) sc.elementType);
    }
  }
View Full Code Here


    // Verifies if it is a Collection or a Serializable type.
    if (Set.class.isAssignableFrom(t)
        || List.class.isAssignableFrom(t)
        || Collection.class.isAssignableFrom(t)) {
      // This is a valid type: a Set, List or Collection of Entity class.
      sf.jdoTuple = new SpeedoCollection();
      sf.jdoTuple.moField = sf;
      if (t == gt) {
        // No generic type defined.
        if (sf.type == null) {
          nbErrors++;
View Full Code Here

     * Visit genclass index. Indexes can be find for List or Map implementation.
     * @param sf a persistent field.
     */
    private void visitGenClassIndex(SpeedoField sf) throws SpeedoException {
        if (sf.jdoTuple instanceof SpeedoCollection) {
            SpeedoCollection collec = (SpeedoCollection) sf.jdoTuple;
            if (collec.indexColumns == null
                    && List.class.isAssignableFrom(getGCClass(sf))) {
                collec.indexColumns = new SpeedoColumn("idx", sf.join.extTable);
                if (logger.isLoggable(BasicLevel.DEBUG)) {
                    logger.log(BasicLevel.DEBUG,
View Full Code Here

      shf.columns = null;
      shf.inheritedField = null;
      shf.join = null;
      shf.moClass = null;
    } else if (se instanceof SpeedoCollection) {
      SpeedoCollection sc = (SpeedoCollection) se;
      sc.elementType = null;
      sc.embeddedElement = false;
      sc.indexColumns = null;
      sc.moField = null;
    } else if (se instanceof SpeedoMap) {
View Full Code Here

      shf.columns = null;
      shf.inheritedField = null;
      shf.join = null;
      shf.moClass = null;
    } else if (se instanceof SpeedoCollection) {
      SpeedoCollection sc = (SpeedoCollection) se;
      sc.elementType = null;
      sc.embeddedElement = false;
      sc.indexColumns = null;
      sc.moField = null;
    } else if (se instanceof SpeedoMap) {
View Full Code Here

        }
        return f.jdoTuple;
    }
    private Object treatCollection(Node node, Object mo) throws SpeedoException {
        SpeedoField f = (SpeedoField) mo;
        SpeedoCollection co = (SpeedoCollection) f.jdoTuple;
        if (co == null) {
            co = new SpeedoCollection();
        }
        f.jdoTuple = co;
        co.moField = f;
        //attribute element-type
        Node n = node.getAttributes().getNamedItem("element-type");
View Full Code Here

    }
    private void treatCollectionField(FieldContext fc) throws SpeedoException {
        List l = (List) fc.fieldChildren.get("collection");
        if (l != null) {
            Node collectionNode = (Node) l.get(0);
          SpeedoCollection co = (SpeedoCollection) fc.field.jdoTuple;
          if (co == null) {
              co = new SpeedoCollection();
          }
          fc.field.jdoTuple = co;
          co.moField = (SpeedoField) fc.field;
          //attribute element-type
          Node n = collectionNode.getAttributes().getNamedItem("element-type");
View Full Code Here

TOP

Related Classes of org.objectweb.speedo.metadata.SpeedoCollection

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.