from api_initializer.event_clusters import EventCluster, RouterCluster
from index import endpoints_index
from .supers_events import (
    SuperLivingSpaceListEvent,
    SuperLivingSpaceCreateEvent,
    SuperLivingSpaceUpdateEvent,
    SuperLivingSpaceDeleteEvent,
)

LivingSpaceRouterCluster = RouterCluster(name="LivingSpaceRouterCluster")

LivingSpaceListEventCluster = EventCluster(name="LivingSpaceListEventCluster", endpoint_uu_id=endpoints_index["LivingSpaceList"])
LivingSpaceListEventCluster.add_event(SuperLivingSpaceListEvent)

LivingSpaceCreateEventCluster = EventCluster(name="LivingSpaceCreateEventCluster", endpoint_uu_id=endpoints_index["LivingSpaceCreate"])
LivingSpaceCreateEventCluster.add_event(SuperLivingSpaceCreateEvent)

LivingSpaceUpdateEventCluster = EventCluster(name="LivingSpaceUpdateEventCluster", endpoint_uu_id=endpoints_index["LivingSpaceUpdate"])
LivingSpaceUpdateEventCluster.add_event(SuperLivingSpaceUpdateEvent)

LivingSpaceDeleteEventCluster = EventCluster(name="LivingSpaceDeleteEventCluster", endpoint_uu_id=endpoints_index["LivingSpaceDelete"])
LivingSpaceDeleteEventCluster.add_event(SuperLivingSpaceDeleteEvent)

LivingSpaceRouterCluster.set_event_cluster(LivingSpaceListEventCluster)
LivingSpaceRouterCluster.set_event_cluster(LivingSpaceCreateEventCluster)
LivingSpaceRouterCluster.set_event_cluster(LivingSpaceUpdateEventCluster)
LivingSpaceRouterCluster.set_event_cluster(LivingSpaceDeleteEventCluster)
