Package anvil.core

Examples of anvil.core.AnyRange


  }


  public Any eval()
  {
    return new AnyRange(_left.eval(), _right.eval());
  }
View Full Code Here


 
  public Any getReference(anvil.script.Context context, Any index)
  {
    Name name = _name;
    if (index.isRange()) {
      AnyRange r = index.toRange();
      int size   = name.size();
      Any a      = r.getLeft();
      int start  = a.isDefined() ? a.toInt() : 0;
      a          = r.getRight();
      int end    = a.isDefined() ? a.toInt() : size;
      long l     = ArrayUtils.adjust2(start, end, size);
      start      = (int)(l & 0xffffffff);
      int length = (int)(l >> 32);
      if (start == 0) {
View Full Code Here

  public boolean deleteReference(anvil.script.Context context, Any index)
  {
    try {
      Name name = _name;
      if (index.isRange()) {
        AnyRange r = index.toRange();
        int size   = _name.size();
        Any a      = r.getLeft();
        int start  = a.isDefined() ? a.toInt() : 0;
        a          = r.getRight();
        int end    = a.isDefined() ? a.toInt() : size;
        long l     = ArrayUtils.adjust2(start, end, size);
        start      = (int)(l & 0xffffffff);
        int length = (int)(l >> 32);
        while(length-- > 0) {
View Full Code Here

TOP

Related Classes of anvil.core.AnyRange

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.