Package gov.cca.ports
Interface ConnectionEvent
- All Superinterfaces:
StandardEventType
Base event interface components wishing to know about their connectedness
(used or provided ports) must listen for.
This interface represents a large simplification and callback
style imposed over the general EventService layer.
This interface contains only enough information to be useful
in the scope of the particular Component instance receiving
the event.
-
Field Summary
Fields inherited from interface gov.cca.ports.StandardEventType
ALL, ALL_string, ComponentAdded, ComponentAdded_string, ComponentAddPending, ComponentAddPending_string, ComponentDeleted, ComponentDeleted_string, ComponentDeletePending, ComponentDeletePending_string, Connected, Connected_string, ConnectPending, ConnectPending_string, Disconnected, Disconnected_string, DisconnectPending, DisconnectPending_string, Error, Error_string, FactoryClosed, FactoryClosed_string, FactoryOpened, FactoryOpened_string, NONE, NONE_string, PortAdded, PortAdded_string, PortAddPending, PortAddPending_string, PortFetched, PortFetched_string, PortFetchPending, PortFetchPending_string, PortRegistered, PortRegistered_string, PortRegisterPending, PortRegisterPending_string, PortReleased, PortReleased_string, PortReleasePending, PortReleasePending_string, PortRemoved, PortRemoved_string, PortRemovePending, PortRemovePending_string, PortUnregistered, PortUnregistered_string, PortUnregisterPending, PortUnregisterPending_string -
Method Summary
Modifier and TypeMethodDescriptionintReturns the integer from those defined that describes the event.Get the PortInfo of the affected Port.
-
Method Details
-
getEventType
int getEventType()Returns the integer from those defined that describes the event.The semantics are noted before each member of the enum/static constant. We can add in different types of connect/disconnect as multiports and explicit local/global/sync/async semantics are agreed to in the future.
At present we assume that:
- all instances in a component cohort (often thought of as a single "parallel component") receive all the events and in the same order, but not necessarily globally synchronously.
- for disconnections, within a process the events are delivered first to the using component then to the providing component.
- for connections, within a process the events are delivered first to the providing component then to the using component.
-
getPortInfo
PortInfo getPortInfo()Get the PortInfo of the affected Port.
-