Class MetroIISequentialSDFDirector

    • Constructor Detail

      • MetroIISequentialSDFDirector

        public MetroIISequentialSDFDirector()
                                     throws IllegalActionException,
                                            NameDuplicationException
        Constructs a director in the default workspace with an empty string as its name. The director is added to the list of objects in the workspace. Increment the version number of the workspace.
        Throws:
        IllegalActionException - If the name has a period in it, or the director is not compatible with the specified container.
        NameDuplicationException - If the container already contains an entity with the specified name.
      • MetroIISequentialSDFDirector

        public MetroIISequentialSDFDirector​(Workspace workspace)
                                     throws IllegalActionException,
                                            NameDuplicationException
        Constructs a director in the given workspace with an empty name. The director is added to the list of objects in the workspace. Increment the version number of the workspace.
        Parameters:
        workspace - The workspace for this object.
        Throws:
        IllegalActionException - If the name has a period in it, or the director is not compatible with the specified container.
        NameDuplicationException - If the container already contains an entity with the specified name.
      • MetroIISequentialSDFDirector

        public MetroIISequentialSDFDirector​(CompositeEntity container,
                                            java.lang.String name)
                                     throws IllegalActionException,
                                            NameDuplicationException
        Constructs a director in the given container with the given name. The container argument must not be null, or a NullPointerException will be thrown. If the name argument is null, then the name is set to the empty string. Increment the version number of the workspace.
        Parameters:
        container - Container of the director.
        name - Name of this director.
        Throws:
        IllegalActionException - If the director is not compatible with the specified container.
        NameDuplicationException - If the name collides with an attribute in the container.
    • Method Detail

      • clone

        public java.lang.Object clone​(Workspace workspace)
                               throws java.lang.CloneNotSupportedException
        Clones the object into the specified workspace. The new object is not added to the directory of that workspace (you must do this yourself if you want it there).
        Overrides:
        clone in class SDFDirector
        Parameters:
        workspace - The workspace for the cloned object.
        Returns:
        The new Attribute.
        Throws:
        java.lang.CloneNotSupportedException - Not thrown in this base class
        See Also:
        NamedObj.exportMoML(Writer, int, String), NamedObj.setDeferringChangeRequests(boolean)
      • initialize

        public void initialize()
                        throws IllegalActionException
        Initializes the list of actors. The actors implementing MetroEventHandler are wrapped by ResumableFire, otherwise are wrapped by BlockingFire.
        Specified by:
        initialize in interface Initializable
        Overrides:
        initialize in class SDFDirector
        Throws:
        IllegalActionException - If the initialize() method of one of the associated actors throws it, or if there is no scheduler.
      • adapter

        public net.jimblackler.Utils.YieldAdapterIterable<java.lang.Iterable<metroIIcomm.Event.Builder>> adapter()
        Returns the iterator for the caller function of getfire().
        Specified by:
        adapter in interface GetFirable
        Returns:
        iterator the iterator for the caller function of getfire().
      • getfire

        public void getfire​(net.jimblackler.Utils.ResultHandler<java.lang.Iterable<metroIIcomm.Event.Builder>> resultHandler)
                     throws net.jimblackler.Utils.CollectionAbortedException
        The order of actor firing should be static and identical to fire(). Each actor is fired only if the associated Metro event is notified.
        Specified by:
        getfire in interface GetFirable
        Parameters:
        resultHandler - iterable of events 'yield returned'.
        Throws:
        net.jimblackler.Utils.CollectionAbortedException