package mil.navy.nps.dis; // our package name /** * * PduPublisher interface for addListener () and removeListener () methods. * * This is an interface, a list of methods that a class can implement. * If the class does in fact implement all of the methods declared here, * it is said to implement the interface. * * This interface specifies two methods, addListener() and removeListener(). * The first adds a passed-in object to the list of objects that will * receive PDUs that we publish. The second removes it from the list. * This is intended to be similar to the Java 1.1 event model. * * This is an example of the Observer pattern. See _Design Patterns_, * Gamma, Helm, Johnson, & Vlissides, pp. 293-303. * * @version 1.0 * @author Don McGregor (http://www.npsnet.org/~mcgredo) * *
Location: *
Web: * http://www.web3d.org/WorkingGroups/vrtp/mil/navy/nps/dis/PduPublisher.java * *
or locally: * ~/mil/navy/nps/dis/PduPublisher.java * * HISTORY * 11/9/98 DMcG new * * * @see PduSubscriber */ public interface PduPublisher { /** addListener adds newListener to the list of objects that will recieve PDUs identified by the triplet entityID. */ public void addListener(PduSubscriber newListener, EntityID entityID); /** removeListener removes the object passed in from the list of objects that will recieve PDUs identified by the triplet entityID. If the object is not on the list, this does nothing. */ public void removeListener(PduSubscriber listenerToRemove, EntityID entityID); }