Package de.xima.fc.tenant.event
Class TenantChangeEvent
- java.lang.Object
-
- de.xima.fc.tenant.event.TenantChangeEvent
-
- All Implemented Interfaces:
Serializable
public final class TenantChangeEvent extends Object implements Serializable
Event published whenever one or more tenants are created, updated or deleted. Observe it (e.g. via@ObservesAsync) to react to tenant changes. The only dependency required for that is this module. The event carries the affected tenants as lightweightTenantBaseDataentries (never entities), so a single publication can cover a batch of tenants that changed together.- Since:
- 8.5.0
- Author:
- Norman Lorenz
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classTenantChangeEvent.EventTypeThe kind of change carried by aTenantChangeEvent.
-
Constructor Summary
Constructors Constructor Description TenantChangeEvent(TenantBaseData[] tenants, TenantChangeEvent.EventType eventType)Creates a newTenantChangeEventinstance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)TenantChangeEvent.EventTypegetEventType()How the affected tenants were changed.TenantBaseData[]getTenants()The tenants that were changed.inthashCode()StringtoString()
-
-
-
Constructor Detail
-
TenantChangeEvent
public TenantChangeEvent(TenantBaseData[] tenants, TenantChangeEvent.EventType eventType)
Creates a newTenantChangeEventinstance.- Parameters:
tenants- The tenants that were changed.eventType- How the affected tenants were changed.
-
-
Method Detail
-
getTenants
public TenantBaseData[] getTenants()
The tenants that were changed.
-
getEventType
public TenantChangeEvent.EventType getEventType()
How the affected tenants were changed.
-
-