bobocep.cep.event.factory.BoboEventFactory
- class bobocep.cep.event.factory.BoboEventFactory[source]
Bases:
objectA BoboEvent factory that generates instances from JSON representations of events.
- __init__()
- static from_json_str(j: str) BoboEvent[source]
- Parameters:
j – A JSON str representation of the event.
- Returns:
A new instance of the event type.
- Raises:
BoboEventFactoryError – If EVENT_TYPE key is missing from JSON.
BoboEventFactoryError – If EVENT_TYPE value is an unknown event type.