Package org.openquark.cal.internal.runtime.lecc

Examples of org.openquark.cal.internal.runtime.lecc.RTRecordValue$TextualRecord


   * This method implements the function logic of the CAL function Cal.Utilities.DirectedGraph.$lambda$showDirectedGraph$3
   */
  public final RTValue f2S(RTValue accum, RTValue vertexNum, RTExecutionContext $ec) throws CALExecutorException {
    // Top level supercombinator logic

    RTRecordValue $recordCase1 =
      ((RTRecordValue)(java.lang.Object)accum.evaluate($ec));
    RTValue indent = $recordCase1.getOrdinalFieldValue(1);
    RTValue text = $recordCase1.getOrdinalFieldValue(2);

    return
      RTRecordValue.makeTupleRecord(
        new RTValue[] {new RTFullApp.General._2._L(Subtract_Int.$instance, indent, new RTFullApp.General._1._S(Show_Directed_Graph__indent_Diff__3.$instance, _dict___Num___Int.$instance)), new RTFullApp.General._2._L(Append_String.$instance, text, new RTFullApp.General._2._L(Append_String.$instance, new RTFullApp.General._1._S(Show_Directed_Graph__make_Indent_String__4.$instance, new RTFullApp.General._2._L(Subtract_Int.$instance, indent, new RTFullApp.General._1._S(Show_Directed_Graph__indent_Diff__3.$instance, _dict___Num___Int.$instance))), _lambda__show_Directed_Graph__3.$L1_String_N))});
  }
View Full Code Here


   * This method implements the function logic of the CAL function Cal.Utilities.DirectedGraph.findCycleInternal$startVertexFn$3
   */
  public final RTValue f2S(RTValue accum, RTValue vertexNum, RTExecutionContext $ec) throws CALExecutorException {
    // Top level supercombinator logic

    RTRecordValue $recordCase1 =
      ((RTRecordValue)(java.lang.Object)accum.evaluate($ec));
    RTValue path = $recordCase1.getOrdinalFieldValue(1);
    RTValue isCycle = $recordCase1.getOrdinalFieldValue(2);

    if (isCycle.evaluate($ec).getBooleanValue()) {
      return accum;
    } else {
      return
View Full Code Here

    // Top level supercombinator logic
    if (Is_Just.$instance.fUnboxed1S(result.getValue(), $ec)) {
      return result.getValue();
    } else {

      RTRecordValue $recordCase2 =
        ((RTRecordValue)(java.lang.Object)pair.getValue());
      RTValue key = $recordCase2.getOrdinalFieldValue(1);
      RTValue val = $recordCase2.getOrdinalFieldValue(2);

      if ((new RTOApp3(
        $dictvarCal_Core_Prelude_Eq_0,
        Get_Maybe_Vertex_Number__find_Vertex_Num__3.$L1_Int_0,
        val,
View Full Code Here

   * This method implements the function logic of the CAL function Cal.Samples.DirectedGraphLibrary.partition
   */
  public final RTValue f2S(RTValue partitionFn, RTValue graph, RTExecutionContext $ec) throws CALExecutorException {
    // Top level supercombinator logic

    RTRecordValue $recordCase1 =
      ((RTRecordValue)(java.lang.Object)
        org.openquark.cal_Cal_Utilities_DirectedGraph.Partition.$instance.f3S(
          _dict___Eq___Vertex.$instance,
          new RTPartialApp._2._1(
            Apply_Vertex_Predicate.$instance,
            partitionFn),
          graph,
          $ec).evaluate(
          $ec));
    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),
View Full Code Here

   * This version of the logic returns an unboxed value.
   */
  public final Pair fUnboxed2S(RTValue partitionFn, RTValue graph, RTExecutionContext $ec) throws CALExecutorException {
    // Top level supercombinator logic

    RTRecordValue $recordCase1 =
      ((RTRecordValue)(java.lang.Object)
        org.openquark.cal_Cal_Utilities_DirectedGraph.Partition.$instance.f3S(
          _dict___Eq___Vertex.$instance,
          new RTPartialApp._2._1(
            Apply_Vertex_Predicate.$instance,
            partitionFn),
          graph,
          $ec).evaluate(
          $ec));
    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),
View Full Code Here

          // Decompose data type to access members.
          RTValue stackTop = $case1.get_head();
          RTValue stackBottom = $case1.get_tail();


          RTRecordValue $recordCase2 =
            ((RTRecordValue)(java.lang.Object)
              stackTop.evaluate($ec));
          RTValue vertexNum =
            $recordCase2.getOrdinalFieldValue(1);
          RTValue finished = $recordCase2.getOrdinalFieldValue(2);

          if (finished.evaluate($ec).getBooleanValue()) {
            stack = stackBottom.evaluate($ec);
              accum =
              finishVertexFn.f2L(
View Full Code Here

   * This method implements the function logic of the CAL function Cal.Utilities.DirectedGraph.findPath$startVertexFn$7
   */
  public final RTValue f3S(RTValue endVertexNum, RTValue accum, RTValue vertexNum, RTExecutionContext $ec) throws CALExecutorException {
    // Top level supercombinator logic

    RTRecordValue $recordCase1 =
      ((RTRecordValue)(java.lang.Object)accum.evaluate($ec));
    RTValue path = $recordCase1.getOrdinalFieldValue(1);
    RTValue reachesEnd = $recordCase1.getOrdinalFieldValue(2);

    if (reachesEnd.evaluate($ec).getBooleanValue()) {
      return accum;
    } else {
      return
View Full Code Here

   * This method implements the function logic of the CAL function Cal.Utilities.DirectedGraph.findCycleInternal$revisitVertexFn$4
   */
  public final RTValue f2S(RTValue accum, RTValue vertexNum, RTExecutionContext $ec) throws CALExecutorException {
    // Top level supercombinator logic

    RTRecordValue $recordCase1 =
      ((RTRecordValue)(java.lang.Object)accum.evaluate($ec));
    RTValue path = $recordCase1.getOrdinalFieldValue(1);
    RTValue isCycle = $recordCase1.getOrdinalFieldValue(2);

    if (isCycle.evaluate($ec).getBooleanValue()) {
      return accum;
    } else {
      TYPE_Maybe $case2;
View Full Code Here

   * This method implements the function logic of the CAL function Cal.Utilities.DirectedGraph.containsEdge
   */
  public final RTValue f3S(RTValue $dictvarCal_Core_Prelude_Eq_23, RTValue graph, RTValue edge, RTExecutionContext $ec) throws CALExecutorException {
    // Top level supercombinator logic

    RTRecordValue $recordCase1 =
      ((RTRecordValue)(java.lang.Object)edge.evaluate($ec));
    RTValue startVertex = $recordCase1.getOrdinalFieldValue(1);
    RTValue endVertex = $recordCase1.getOrdinalFieldValue(2);

    RTValue letVar_maybeStartVertexNum =
      Contains_Edge.maybeStartVertexNum$5$def_Lazy(
        $dictvarCal_Core_Prelude_Eq_23,
        graph,
View Full Code Here

   * This version of the logic returns an unboxed value.
   */
  public final boolean fUnboxed3S(RTValue $dictvarCal_Core_Prelude_Eq_23, RTValue graph, RTValue edge, RTExecutionContext $ec) throws CALExecutorException {
    // Top level supercombinator logic

    RTRecordValue $recordCase1 =
      ((RTRecordValue)(java.lang.Object)edge.evaluate($ec));
    RTValue startVertex = $recordCase1.getOrdinalFieldValue(1);
    RTValue endVertex = $recordCase1.getOrdinalFieldValue(2);

    RTValue letVar_maybeStartVertexNum =
      Contains_Edge.maybeStartVertexNum$5$def_Lazy(
        $dictvarCal_Core_Prelude_Eq_23,
        graph,
View Full Code Here

TOP

Related Classes of org.openquark.cal.internal.runtime.lecc.RTRecordValue$TextualRecord

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.