Package erjang

Examples of erjang.ESeq.reverse()


    if (target == null) {
      throw new ErlangUndefined(m, f, new ESmall(arity));
    }
   
    self.tail = target;
    a = a.reverse();
    switch (arity) {
    default:
      throw new NotImplemented("hibernate w/" + arity + " args");
    case 7:
      self.arg6 = a.head(); a = a.tail();
View Full Code Here


      collector.end();

      if (rest != ERT.NIL) {
        return ETuple.make(INCOMPLETE_ATOM, 
                   output_converter.convert(out),
                   ErlConvert.iolist_to_binary(rest.reverse()));
      }
     
    } catch (CharCollector.PartialDecodingException e) {
      EObject data = output_converter.convert(out);
      return ETuple.make(INCOMPLETE_ATOM, data);
View Full Code Here

    if (set == null) return res;
    for(ISeq s = set.seq(); s != null; s = s.next())
    {
      res = res.cons((EObject) s.first());
    }   
    return res.reverse();
  }

  @Override
  protected EAtom member(EObject key) {
    IPersistentMap ipm = deref();
View Full Code Here

       
        Seqable coll = (Seqable)ent.getValue();
        res = matcher.match_vars(res, coll.seq());
      }
     
      return res.reverse();
    }
   
    IPersistentMap map = deref();
    IPersistentCollection coll = (IPersistentCollection) map.valAt(key);
    if (coll == null) return ERT.NIL;
View Full Code Here

       
        Seqable coll = (Seqable)ent.getValue();
        res = matcher.match_members(res, coll.seq());
      }
     
      return res.reverse();
    }
   
    IPersistentMap map = deref();
    IPersistentCollection coll = (IPersistentCollection) map.valAt(key);
    if (coll == null) return ERT.NIL;
View Full Code Here

             } else {
               out = out.cons(nocapture(o2));
             }
           }
          
           return new ETuple2(am_match, out.reverse());
         
        } else {
          throw ERT.badarg(subj, re, opts);
        }
       
View Full Code Here

        if ((res = matcher.match(candidate)) != null) {
          count += 1;
          vals = vals.cons(res);
        }
      }
      if (ordered) vals = vals.reverse();

      if (vals == ERT.NIL) {
        return Native.am_$end_of_table;
      } else if (!seq_has_more(map_seq)) {
        return new ETuple2(vals, Native.am_$end_of_table);
View Full Code Here

    ESeq res = ERT.NIL;
   
    EObject key = matcher.getKey(keypos1);
    if (key == null) {
      res = matcher.match(res, (Map<EObject, ETuple>) map);
      if (ordered) res = res.reverse();
    } else {
      ETuple candidate = (ETuple) map.valAt(key);
      if (candidate != null) {
        res =  matcher.match(res, candidate);
      }
View Full Code Here

    ESeq res = ERT.NIL;
   
    EObject key = matcher.getKey(keypos1);
    if (key == null) {
      res = matcher.match_members(res, (Map<EObject, ETuple>) map);
      if (ordered) res = res.reverse();
    } else {
      ETuple candidate = (ETuple) map.valAt(key);
      if (candidate != null) {
        res =  matcher.match_members(res, candidate);
      }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.