Packages

  • package root
    Definition Classes
    root
  • package se
    Definition Classes
    root
  • package sics
    Definition Classes
    se
  • package kompics
    Definition Classes
    sics
  • package sl

    This package contains the Scala DSL for Kompics.

    This package contains the Scala DSL for Kompics.

    It is recommended to import this as import se.sics.kompics.sl._, since it contains a number of implicit conversions and convenience methods that are good to have in scope.

    Definition Classes
    kompics
  • package simulator

    The Kompics Simulator DSL for Scala

    The Kompics Simulator DSL for Scala

    Definition Classes
    sl
    Example:
    1. case object SimpleSimulation {
      
        import Distributions._
        // needed for the distributions, but needs to be initialised after setting the seed
        implicit val random = JSimulationScenario.getRandom();
      
        private def intToAddress(i: Int): Address = {
          try {
            new TAddress(new InetSocketAddress(InetAddress.getByName("192.193.0." + i), 10000));
          } catch {
            case ex: UnknownHostException => throw new RuntimeException(ex);
          }
        }
      
        val startResultSetterOp = Op { (self: Integer) =>
          val selfAddr = intToAddress(self);
          StartNode(selfAddr, Init[ResultSetter](selfAddr))
        };
        val startPongerOp = Op { (self: Integer) =>
          val selfAddr = intToAddress(self)
          StartNode(selfAddr, Init[PongerParent](selfAddr))
        };
        val startPingerOp = Op { (self: Integer, ponger: Integer) =>
          val selfAddr = intToAddress(self);
          val pongerAddr = intToAddress(ponger);
          StartNode(selfAddr, Init[PingerParent](selfAddr, pongerAddr))
        };
      
        val scenario = raise(5, startPongerOp, 1.toN)
          .arrival(constant(1000.millis))
          .andThen(1000.millis)
          .afterTermination(raise(5, startPingerOp, 6.toN, 1.toN).arrival(constant(1000.millis)))
          .inParallel(raise(1, startResultSetterOp, 1.toN).arrival(constant(1000.millis)))
          .andThen(10000.millis)
          .afterTermination(Terminate);
      }
  • ChangeNetwork
  • Distributions
  • IntDistributions
  • KillNode
  • Op
  • Setup
  • SimulationResult
  • StartNode
  • StochasticProcess
  • StochasticProcessBuilder
  • StochasticProcessChain
  • Terminate
o

se.sics.kompics.sl.simulator

ChangeNetwork

object ChangeNetwork

Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ChangeNetwork
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def apply(netModel: => NetworkModel): ChangeNetworkModelEvent

    Change the current network model

    Change the current network model

    Note that changing the network model during the simulation is possible, but has very poorly defined semantics for in-flight messages. For consistent semantics, only change the network model when you are sure that no messages are currently in transit (such as, at the beginning of the simulation).

    netModel

    the new network model to change to

    returns

    a simulator event that changes the network model

    See also

    se.sics.kompics.simulator.events.system.ChangeNetworkModelEvent and for concrete network models se.sics.kompics.simulator.network.NetworkModel

  5. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  6. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native() @HotSpotIntrinsicCandidate()
  7. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  8. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  9. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  10. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  11. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  12. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  13. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  14. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  15. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  16. def toString(): String
    Definition Classes
    AnyRef → Any
  17. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  18. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  19. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated @deprecated
    Deprecated

    (Since version ) see corresponding Javadoc for more information.

Inherited from AnyRef

Inherited from Any

Ungrouped