Class IMapNode
java.lang.Object
rs.edu.raf.dsw.rudok.app.observer.IObserver
rs.edu.raf.dsw.rudok.app.observer.IPublisherGlobal
rs.edu.raf.dsw.rudok.app.observer.IPublisher
rs.edu.raf.dsw.rudok.app.repository.IMapNode
- Direct Known Subclasses:
Element
,IMapNodeComposite
public abstract class IMapNode extends IPublisher
Composite design pattern unit. Cannot have any children. Can have multiple
IMapNodeComposite
parents.-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
IMapNode.Message
Message for publishing. -
Field Summary
Fields Modifier and Type Field Description Set<IMapNodeComposite>
parents
Set of parents. -
Constructor Summary
-
Method Summary
Modifier and Type Method Description void
addParent(IMapNodeComposite parent)
Adds a parent to the node.String
getNodeName()
Set<IMapNodeComposite>
getParents()
void
receive(Object message)
Receive data update from publisher.void
removeParent(IMapNodeComposite parent)
Removes a parent from the node.void
setNodeName(String nodeName)
void
setParents(Set<IMapNodeComposite> parents)
String
toString()
Methods inherited from class rs.edu.raf.dsw.rudok.app.observer.IPublisher
addObserver, getObservers, publish, removeObserver, setObservers
Methods inherited from class rs.edu.raf.dsw.rudok.app.observer.IPublisherGlobal
addObserverGlobal, getObserversGlobal, removeObserverGlobal
Methods inherited from class rs.edu.raf.dsw.rudok.app.observer.IObserver
addPublisher, getPublishers, removePublisher, setPublishers
-
Field Details
-
parents
Set of parents.
-
-
Constructor Details
-
IMapNode
-
-
Method Details
-
getParents
-
setParents
-
getNodeName
-
setNodeName
-
toString
-
addParent
Adds a parent to the node.- Parameters:
parent
- Node to add as parent.
-
removeParent
Removes a parent from the node.- Parameters:
parent
- Node to remove from parents.
-
receive
Description copied from class:IObserver
Receive data update from publisher. Default implementation, should be overridden.
-