Package org.openquark.util

Examples of org.openquark.util.Pair


   * f2S
   * This method implements the function logic of the CAL function Cal.Samples.DirectedGraphLibrary.makePair
   */
  public final RTValue f2S(java.lang.Object $x0, java.lang.Object $x1, RTExecutionContext $ec) throws CALExecutorException {
    // Top level supercombinator logic
    return RTData.CAL_Opaque.make(new Pair($x0, $x1));
  }
View Full Code Here


   * This method implements the logic of the CAL function Cal.Samples.DirectedGraphLibrary.makePair
   * This version of the logic returns an unboxed value.
   */
  public final Pair fUnboxed2S(java.lang.Object $x0, java.lang.Object $x1, RTExecutionContext $ec) throws CALExecutorException {
    // Top level supercombinator logic
    return ((Pair)(java.lang.Object)(new Pair($x0, $x1)));
  }
View Full Code Here

    RTValue graph1 = $recordCase1.getOrdinalFieldValue(1);
    RTValue graph2 = $recordCase1.getOrdinalFieldValue(2);

    return
      RTData.CAL_Opaque.make(
        new Pair(
          Cal_Value_To_Object.$instance.fUnboxed1S(graph1, $ec),
          Cal_Value_To_Object.$instance.fUnboxed1S(graph2, $ec)));
  }
View Full Code Here

    RTValue graph1 = $recordCase1.getOrdinalFieldValue(1);
    RTValue graph2 = $recordCase1.getOrdinalFieldValue(2);

    return
      ((Pair)(java.lang.Object)
        (new Pair(
          Cal_Value_To_Object.$instance.fUnboxed1S(graph1, $ec),
          Cal_Value_To_Object.$instance.fUnboxed1S(graph2, $ec))));
  }
View Full Code Here

    private static void multithreadedAssertEquals(Object expectedValue, Object object, List asserts) {
        synchronized (asserts) {
            if (SHOW_DEBUGGING_OUTPUT) {
                System.out.println("Adding pair to asserts list: expected=" + expectedValue + " actual=" + object);
            }
            asserts.add(new Pair(expectedValue, object));
        }
    }
View Full Code Here

     * @param asserts a List of pairs of objects that should be equals.
     */
    private static void assertAll(List asserts) {
        synchronized (asserts) {
            for (int i = 0, n = asserts.size(); i < n; i++) {
                Pair pair = (Pair)asserts.get(i);
                assertEquals(pair.fst(), pair.snd());
            }
        }
    }
View Full Code Here

   * This method implements the function logic of the CAL function Cal.Samples.DirectedGraphLibrary.applyEdgePredicate
   */
  public final RTValue f3S(Predicate predicate, java.lang.Object source, java.lang.Object target, RTExecutionContext $ec) throws CALExecutorException {
    // Top level supercombinator logic
    return
      RTData.CAL_Boolean.make(predicate.apply(new Pair(source, target)));
  }
View Full Code Here

   * This method implements the logic of the CAL function Cal.Samples.DirectedGraphLibrary.applyEdgePredicate
   * This version of the logic returns an unboxed value.
   */
  public final boolean fUnboxed3S(Predicate predicate, java.lang.Object source, java.lang.Object target, RTExecutionContext $ec) throws CALExecutorException {
    // Top level supercombinator logic
    return predicate.apply(new Pair(source, target));
  }
View Full Code Here

   * f2S
   * This method implements the function logic of the CAL function Cal.Samples.DirectedGraphLibrary.makeEdge
   */
  public final RTValue f2S(java.lang.Object $x0, java.lang.Object $x1, RTExecutionContext $ec) throws CALExecutorException {
    // Top level supercombinator logic
    return RTData.CAL_Opaque.make(new Pair($x0, $x1));
  }
View Full Code Here

   * This method implements the logic of the CAL function Cal.Samples.DirectedGraphLibrary.makeEdge
   * This version of the logic returns an unboxed value.
   */
  public final Pair fUnboxed2S(java.lang.Object $x0, java.lang.Object $x1, RTExecutionContext $ec) throws CALExecutorException {
    // Top level supercombinator logic
    return ((Pair)(java.lang.Object)(new Pair($x0, $x1)));
  }
View Full Code Here

TOP

Related Classes of org.openquark.util.Pair

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.