diff options
Diffstat (limited to 'buildstream/_project.py')
-rw-r--r-- | buildstream/_project.py | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/buildstream/_project.py b/buildstream/_project.py index 51cdd5e2b..028bdcc9f 100644 --- a/buildstream/_project.py +++ b/buildstream/_project.py @@ -26,6 +26,7 @@ from . import utils from . import _cachekey from . import _site from . import _yaml +from ._artifactelement import ArtifactElement from ._profile import Topics, profile_start, profile_end from ._exceptions import LoadError, LoadErrorReason from ._options import OptionPool @@ -255,6 +256,19 @@ class Project(): else: return self.config.element_factory.create(self._context, self, meta) + # create_artifact_element() + # + # Instantiate and return an ArtifactElement + # + # Args: + # ref (str): A string of the artifact ref + # + # Returns: + # (ArtifactElement): A newly created ArtifactElement object of the appropriate kind + # + def create_artifact_element(self, ref): + return ArtifactElement(self._context, ref) + # create_source() # # Instantiate and return a Source |