Examples of shift()


Examples of org.apache.velocity.tools.generic.Alternator.shift()

        assertStringEquals("red", auto);
        /* test manual alternator (use 'make()' and not 'manual()' since we define the default to be manual in toolbox.xml*/
         Alternator manual = alternatorTool.make(new String[] {"red","blue","yellow"});
        assertStringEquals("red", manual);
        assertStringEquals("red", manual);
        manual.shift();
        assertStringEquals("blue", manual);
        manual.shift();
        manual.shift();
        assertStringEquals("red", manual);
    }
View Full Code Here

Examples of org.apache.velocity.tools.generic.Alternator.shift()

         Alternator manual = alternatorTool.make(new String[] {"red","blue","yellow"});
        assertStringEquals("red", manual);
        assertStringEquals("red", manual);
        manual.shift();
        assertStringEquals("blue", manual);
        manual.shift();
        manual.shift();
        assertStringEquals("red", manual);
    }

    protected void assertStringEquals(String expected, Object testThis) {
View Full Code Here

Examples of org.apache.velocity.tools.generic.Alternator.shift()

        assertStringEquals("red", manual);
        assertStringEquals("red", manual);
        manual.shift();
        assertStringEquals("blue", manual);
        manual.shift();
        manual.shift();
        assertStringEquals("red", manual);
    }

    protected void assertStringEquals(String expected, Object testThis) {
        assertEquals(expected, String.valueOf(testThis));
View Full Code Here

Examples of org.apache.velocity.tools.generic.Alternator.shift()

        assertEquals("red",auto.toString());
        /* test manual alternator (use 'make()' and not 'manual()' since we define the default to be manual in toolbox.xml*/
         Alternator manual = alternatorTool.make(new String[] {"red","blue","yellow"});
        assertEquals("red",manual.toString());
        assertEquals("red",manual.toString());
        manual.shift();
        assertEquals("blue",manual.toString());
        manual.shift();
        manual.shift();
        assertEquals("red",manual.toString());
    }
View Full Code Here

Examples of org.apache.velocity.tools.generic.Alternator.shift()

         Alternator manual = alternatorTool.make(new String[] {"red","blue","yellow"});
        assertEquals("red",manual.toString());
        assertEquals("red",manual.toString());
        manual.shift();
        assertEquals("blue",manual.toString());
        manual.shift();
        manual.shift();
        assertEquals("red",manual.toString());
    }

    public @Test void testDateTool() { /* TODO still incomplete */
 
View Full Code Here

Examples of org.apache.velocity.tools.generic.Alternator.shift()

        assertEquals("red",manual.toString());
        assertEquals("red",manual.toString());
        manual.shift();
        assertEquals("blue",manual.toString());
        manual.shift();
        manual.shift();
        assertEquals("red",manual.toString());
    }

    public @Test void testDateTool() { /* TODO still incomplete */
        DateTool dateTool = (DateTool)toolbox.get("date");
View Full Code Here

Examples of org.jruby.RubyArray.shift()

    static List<Object> getList(ThreadContext context, IRubyObject value) {
        RubyArray ruby_array = (RubyArray)RuntimeHelpers.invoke(context, value, "to_a");
        List<Object> list = new ArrayList<Object>();
        while (true) {
            IRubyObject element = ruby_array.shift(context);
            if (element.isNil()) break;
            list.add(DiametricUtils.convertRubyToJava(context, element));
        }
        return Collections.unmodifiableList(list);
    }
View Full Code Here

Examples of org.osm2world.core.math.SimplePolygonXZ.shift()

            }
           
            VectorXZ direction = end.subtract(start).normalize();
           
            if (startCommonNode) {
              subtractPolygons.add(subtractPoly.shift(direction));
            }
           
            if (endCommonNode) {
              subtractPolygons.add(subtractPoly.shift(direction.invert()));
            }
View Full Code Here

Examples of org.osm2world.core.math.SimplePolygonXZ.shift()

            if (startCommonNode) {
              subtractPolygons.add(subtractPoly.shift(direction));
            }
           
            if (endCommonNode) {
              subtractPolygons.add(subtractPoly.shift(direction.invert()));
            }
           
          }
         
        }
View Full Code Here

Examples of org.pentaho.reporting.engine.classic.core.layout.model.RenderNode.shift()

  private static void shiftBoxInternal(final RenderBox box, final long amount)
  {
    RenderNode node = box.getFirstChild();
    while (node != null)
    {
      node.shift(amount);
      if ((node.getNodeType() & LayoutNodeTypes.MASK_BOX) == LayoutNodeTypes.MASK_BOX)
      {
        shiftBoxInternal((RenderBox) node, amount);
      }
      node = node.getNext();
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.