mirror of
https://github.com/ynput/ayon-core.git
synced 2026-01-02 00:44:52 +01:00
implemented helper private methods for creators
This commit is contained in:
parent
3e8c97e9d6
commit
d15240d2a3
4 changed files with 26 additions and 20 deletions
|
|
@ -69,6 +69,12 @@ class BaseCreator:
|
|||
self._log = logging.getLogger(self.__class__.__name__)
|
||||
return self._log
|
||||
|
||||
def _add_instance_to_context(self, instance):
|
||||
self.create_context.creator_adds_instance(instance)
|
||||
|
||||
def _remove_instance_from_context(self, instance):
|
||||
self.create_context.creator_removed_instance(instance)
|
||||
|
||||
@abstractmethod
|
||||
def create(self, options=None):
|
||||
"""Create new instance.
|
||||
|
|
@ -97,12 +103,8 @@ class BaseCreator:
|
|||
Args:
|
||||
instance(list<CreatedInstance>): Instance objects which should be
|
||||
removed.
|
||||
|
||||
Returns:
|
||||
bool: Instance was removed completely and is not required to call
|
||||
host's implementation of removement.
|
||||
"""
|
||||
return False
|
||||
pass
|
||||
|
||||
def get_icon(self):
|
||||
"""Icon of creator (family).
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue