Interface OMRSTopic
- All Known Implementing Classes:
OMRSTopicConnector
public interface OMRSTopic
OMRSTopic defines the interface to the messaging Topic for OMRS Events.
It implemented by the OMRSTopicConnector.
-
Method Summary
Modifier and TypeMethodDescriptionvoidregisterListener(OMRSTopicListener newListener) Deprecated.voidregisterListener(OMRSTopicListener newListener, String serviceName) Register a listener object.voidregisterListener(OMRSTopicRepositoryEventListener newListener, String serviceName) Register a listener object.voidSends the supplied event to the topic.Sends the supplied event to the topic.sendTypeDefEvent(OMRSTypeDefEvent event) Sends the supplied event to the topic.voidsetEventProtocolLevel(OMRSEventProtocolVersion eventProtocolVersion) Set up the version of the protocol to use for events.
-
Method Details
-
setEventProtocolLevel
Set up the version of the protocol to use for events.- Parameters:
eventProtocolVersion- version enum
-
registerListener
Deprecated.Register a listener object. This object will be supplied with all the events received on the topic.- Parameters:
newListener- object implementing the OMRSTopicListener interface
-
registerListener
Register a listener object. This object will be supplied with all the events received on the topic.- Parameters:
newListener- object implementing the OMRSTopicListener interfaceserviceName- name of service that the listener is from
-
registerListener
Register a listener object. This object will be supplied with all the events received on the topic.- Parameters:
newListener- object implementing the OMRSTopicRepositoryEventListener interfaceserviceName- name of service that the listener is from
-
sendRegistryEvent
CompletableFuture<Boolean> sendRegistryEvent(OMRSRegistryEvent event) throws ConnectorCheckedException Sends the supplied event to the topic.- Parameters:
event- OMRSRegistryEvent object containing the event properties.- Throws:
ConnectorCheckedException- the connector is not able to communicate with the event bus
-
sendTypeDefEvent
CompletableFuture<Boolean> sendTypeDefEvent(OMRSTypeDefEvent event) throws ConnectorCheckedException Sends the supplied event to the topic.- Parameters:
event- OMRSTypeDefEvent object containing the event properties.- Returns:
- a future that has the result (boolean) of sendEvent
- Throws:
ConnectorCheckedException- the connector is not able to communicate with the event bus
-
sendInstanceEvent
Sends the supplied event to the topic.- Parameters:
event- OMRSInstanceEvent object containing the event properties.- Throws:
ConnectorCheckedException- the connector is not able to communicate with the event bus
-