fmartingr
/
jeeves
Archived
1
0
Fork 0
This repository has been archived on 2021-02-14. You can view files and clone it, but cannot push or open issues or pull requests.
jeeves/jeeves/core/actions/base.py

23 lines
499 B
Python

import logging
from abc import abstractmethod
import pydantic
class Action:
id = ""
class Parameters(pydantic.BaseModel):
pass
def __init__(self, parameters=None):
self.logger = logging.getLogger(self.__class__.__name__)
self.parameters = self.Parameters(**(parameters or {}))
@abstractmethod
def execute(self, workspace, **kwargs):
"""
Main method to override that handles the work for the defining action.
"""
pass