MCPcopy Create free account
hub / github.com/StackStorm/st2 / to_model

Method to_model

st2common/st2common/models/api/trigger.py:179–191  ·  view source on GitHub ↗
(cls, instance)

Source from the content-addressed store, hash-verified

177
178 @classmethod
179 def to_model(cls, instance):
180 trigger = instance.trigger
181 payload = instance.payload
182 occurrence_time = isotime.parse(instance.occurrence_time)
183 status = instance.status
184
185 model = cls.model(
186 trigger=trigger,
187 payload=payload,
188 occurrence_time=occurrence_time,
189 status=status,
190 )
191 return model

Callers

nothing calls this directly

Calls 1

parseMethod · 0.80

Tested by

no test coverage detected