Class NGNetwork

    • Constructor Detail

      • NGNetwork

        public NGNetwork()
        Creates a new network component.
    • Method Detail

      • init

        public void init​(String name,
                         int port,
                         short[] servers)
                  throws Exception
        Initializes a new network component. This method is used in order to easily creates and configure a Network component from a class name. So we can use the Class.newInstance() method for create (whitout any parameter) the component, then we can initialize it with this method.
        This method initializes the logical clock for the domain.
        Overrides:
        init in class StreamNetwork
        Parameters:
        name - The domain name.
        port - The listen port.
        servers - The list of servers directly accessible from this network interface.
        Throws:
        Exception - an error occurs.
        See Also:
        Network
      • close

        void close()
      • wakeup

        public void wakeup()
        Wakes up the watch-dog thread.
      • isRunning

        public boolean isRunning()
        Tests if the network component is alive.
        Returns:
        true if this MessageConsumer is alive; false otherwise.
      • toString

        public String toString()
        Returns a string representation of this consumer, including the daemon's name and status.
        Specified by:
        toString in interface NetworkMBean
        Overrides:
        toString in class Network
        Returns:
        A string representation of this consumer.