Package railo.runtime.type

Examples of railo.runtime.type.Collection


     */
    public static Reference getInstance(Object o, String key) {
        if(o instanceof Reference) {
            return new ReferenceReference((Reference)o,key);
        }
        Collection coll = Caster.toCollection(o,null);
        if(coll!=null) return new VariableReference(coll,key);
        return new NativeReference(o,key);
    }
View Full Code Here


    }
    /*else if(obj instanceof Query) {
      return toQuery((Query) obj);
    }*/ 
    else if(obj instanceof Collection) {
      Collection coll=(Collection) obj;
      return toQuery(coll, CollectionUtil.keys(coll));
    }
   
    return obj;
   
View Full Code Here

      }
      return textes;
    }
  // Collection
    else if(o instanceof Collection) {
      Collection coll=(Collection)o;
      Iterator<Object> it = coll.valueIterator();
      List<Text> textes=new ArrayList<Text>();
      while(it.hasNext()) {
        textes.add(toText(doc,it.next()));
      }
      return textes.toArray(new Text[textes.size()]);
View Full Code Here

      }
      return attres;
    }
  // Collection
    else if(o instanceof Collection) {
      Collection coll=(Collection)o;
      Iterator<Entry<Key, Object>> it = coll.entryIterator();
      Entry<Key, Object> e;
      List<Attr> attres=new ArrayList<Attr>();
      Attr attr;
      Collection.Key k;
      while(it.hasNext()) {
View Full Code Here

      }
      return comments;
    }
  // Collection
    else if(o instanceof Collection) {
      Collection coll=(Collection)o;
      Iterator<Object> it = coll.valueIterator();
      List<Comment> comments=new ArrayList<Comment>();
      while(it.hasNext()) {
        comments.add(toComment(doc,it.next()));
      }
      return comments.toArray(new Comment[comments.size()]);
View Full Code Here

      }
      return elements;
    }
  // Collection
    else if(o instanceof Collection) {
      Collection coll=(Collection)o;
      Iterator<Object> it = coll.valueIterator();
      List<Element> elements=new ArrayList<Element>();
      while(it.hasNext()) {
        elements.add(toElement(doc,it.next()));
      }
      return elements.toArray(new Element[elements.size()]);
View Full Code Here

    if(o instanceof Node[]) {
      return (Node[])o;
    }
  // Collection
    else if(o instanceof Collection) {
      Collection coll=(Collection)o;
      Iterator<Object> it = coll.valueIterator();
      List<Node> nodes=new ArrayList<Node>();
      while(it.hasNext()) {
        nodes.add(toNode(doc,it.next(),false));
      }
      return nodes.toArray(new Node[nodes.size()]);
View Full Code Here

                  values.setEL(k,argColl.get(k,Argument.NULL));
                }
              }
        }
      else if(value instanceof Collection) {
            Collection argColl=(Collection) value;
          //Collection.Key[] keys = argColl.keys();
        Iterator<Key> it = argColl.keyIterator();
        Key k;
        while(it.hasNext()) {
            k = it.next();
            if(!values.containsKey(k)){
                  values.setEL(k,argColl.get(k,Argument.NULL));
                }
              }
        }
      else if(value instanceof Map) {
        Map map=(Map) value;
View Full Code Here

  }
 
  @Override
  public CatchBlock getCatchBlock(Config config) {
    CatchBlock cb=rootCause.getCatchBlock(config);
    Collection cause = (Collection) Duplicator.duplicate(cb,false);
    //rtn.setEL("message", getMessage());
    if(!cb.containsKey(KeyConstants._detail))cb.setEL(KeyConstants._detail, "Exception throwed while invoking function ["+eventName+"] from "+Constants.APP_CFC);
    cb.setEL(ROOT_CAUSE, cause);
    cb.setEL(CAUSE, cause);
    //cb.setEL("stacktrace", getStackTraceAsString());
View Full Code Here

    return call(pc, struct, KeyImpl.init(key));
  }
 
  public static boolean call(PageContext pc , railo.runtime.type.Struct struct, Collection.Key key) {
    if(struct instanceof CollectionStruct) {
      Collection c=((CollectionStruct) struct).getCollection();
      if(c instanceof Query) {
        return QueryColumnExists.call(pc, (Query)c, key);
      }
    }
    if(NullSupportHelper.full()) return struct.containsKey(key);
View Full Code Here

TOP

Related Classes of railo.runtime.type.Collection

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.