Class MirrorComposite

    • Constructor Detail

      • MirrorComposite

        public MirrorComposite​(CompositeEntity container,
                               java.lang.String name)
                        throws IllegalActionException,
                               NameDuplicationException
        Create an actor with a name and a container. The container argument must not be null, or a NullPointerException will be thrown. This actor will use the workspace of the container for synchronization and version counts. If the name argument is null, then the name is set to the empty string. Increment the version of the workspace.
        Parameters:
        container - The container actor.
        name - The name of this actor.
        Throws:
        IllegalActionException - If the container is incompatible with this actor.
        NameDuplicationException - If the name coincides with an actor already in the container.
      • MirrorComposite

        public MirrorComposite​(Workspace workspace)
        Construct a MirrorComposite in the specified workspace with no container and an empty string as a name. You can then change the name with setName(). If the workspace argument is null, then use the default workspace. You should set the local director or executive director before attempting to send data to the actor or to execute it. Add the actor to the workspace directory. Increment the version number of the workspace.
        Parameters:
        workspace - The workspace that will list the actor.
      • MirrorComposite

        public MirrorComposite​(CompositeEntity container,
                               java.lang.String name,
                               boolean mirrorParameterPorts)
                        throws IllegalActionException,
                               NameDuplicationException
        Create an actor with a name and a container that optionally mirrors the ports that are instances of ParameterPort. The container argument must not be null, or a NullPointerException will be thrown. This actor will use the workspace of the container for synchronization and version counts. If the name argument is null, then the name is set to the empty string. Increment the version of the workspace.
        Parameters:
        container - The container actor.
        name - The name of this actor.
        mirrorParameterPorts - If false, then ports that are instances of ParameterPort are not mirrored.
        Throws:
        IllegalActionException - If the container is incompatible with this actor.
        NameDuplicationException - If the name coincides with an actor already in the container.
    • Method Detail

      • _mirrorPort

        protected boolean _mirrorPort​(ComponentPort insidePort)
        Return true if the specified inside port should be mirrored. This overrides the base class to return true for all ports unless the port is an instance of ParameterPort and the constructor specified that parameter ports should not be mirrored.
        Overrides:
        _mirrorPort in class ReflectComposite
        Parameters:
        insidePort - The port that may be mirrored.
        Returns:
        True if the inside port should be mirrored.