Package org.destecs.protocol.structs

Examples of org.destecs.protocol.structs.StepStruct


        + " -> " + totalSimulationTime + " Current=" + time);

    List<String> events = new Vector<String>();

    // First initialize DT
    StepStruct deResult = step(Simulator.DE, dtProxy, ctProxy, initTime, new Vector<StepinputsStructParam>(), false, events);
    StepStruct ctResult = step(Simulator.CT, dtProxy, ctProxy, initTime, outputToInput(deResult.outputs), false, events);

    engineInfo(Simulator.ALL, String.format("Simulation:  %2d %%", percentCompleted));
   
    variableSyncInfo(merge(deResult, ctResult).getHeaders());
    while (time <= totalSimulationTime)
View Full Code Here


      List<StepinputsStructParam> inputs, Boolean singleStep,
      List<String> events) throws SimulationException
  {
    beforeStep(simulator, outputTime, dtProxy, ctProxy, inputs, singleStep, events);
    messageInfo(simulator, outputTime, "step");
    StepStruct result = null;
    try
    {
      if (simulator == Simulator.CT)
      {
        result = ctProxy.step(outputTime, inputs, singleStep, events);
View Full Code Here

        {
          events.add((String) in);
        }
      }

      StepStruct result;

      outputTime = new Double(SystemClock.timeToInternal(TimeUnit.seconds, outputTime));
      result = SimulationManager.getInstance().step(outputTime, inputs, events);

      result.time = SystemClock.internalToTime(TimeUnit.seconds, result.time.longValue());
      if (result.time > finishTime)
      {
        // The next point where VDM needs CT communication is result.time but if the simulation stops before we
        // are not by protocol allowed to ask for this.
        result.time = finishTime;
      }

      return result.toMap();
    } catch (RemoteSimulationException e)
    {
      ErrorLog.log(e);
      throw e;
    }
View Full Code Here

        debugErr(e);
        throw new RemoteSimulationException("Faild to get output parameter", e);
      }
    }

    StepStruct result = new StepStruct(StepResultEnum.SUCCESS.value, new Double(nextSchedulableActionTime), new Vector<String>(), outputs);

    return result;
  }
View Full Code Here

TOP

Related Classes of org.destecs.protocol.structs.StepStruct

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.