Class BigraphBuilderSupport<S extends Signature<? extends Control<?,?>>>

java.lang.Object
org.bigraphs.framework.core.BigraphBuilderSupport<S>
All Implemented Interfaces:
BigraphBuilder<S>
Direct Known Subclasses:
PureBigraphBuilder

public abstract class BigraphBuilderSupport<S extends Signature<? extends Control<?,?>>> extends Object implements BigraphBuilder<S>
Supporting base class for concrete bigraph builder implementations.

Provides some generic methods for building bigraphs.

Author:
Dominik Grzelak
  • Field Details

  • Constructor Details

    • BigraphBuilderSupport

      public BigraphBuilderSupport()
  • Method Details

    • getMetaModel

      public abstract org.eclipse.emf.ecore.EPackage getMetaModel()
    • getInstanceModel

      protected abstract org.eclipse.emf.ecore.EObject getInstanceModel()
    • getAvailableEClasses

      protected abstract Map<String,org.eclipse.emf.ecore.EClass> getAvailableEClasses()
    • getAvailableEReferences

      protected abstract Map<String,org.eclipse.emf.ecore.EReference> getAvailableEReferences()
    • closeInnerName

      public abstract void closeInnerName(BigraphEntity.InnerName innerName, boolean keepIdleName) throws LinkTypeNotExistsException
      Throws:
      LinkTypeNotExistsException
    • executeValidationChain

      protected static BModelValidationResult executeValidationChain(org.eclipse.emf.ecore.EObject signatureMetaModel) throws SignatureValidationFailedException
      Executes various metamodel validators. It returns the class of the respective signature instance object passed to this method (e.g., KindSignature).
      Parameters:
      signatureMetaModel - the signature instance model
      Returns:
      the class of the corresponding signature instance model
      Throws:
      SignatureValidationFailedException - If the validation fails because the instance model does not conform to a metamodel or the respective signature class constructor could not be found.
    • getSignatureFromMetaModel

      public static <S extends AbstractEcoreSignature<? extends Control<?, ?>>> S getSignatureFromMetaModel(org.eclipse.emf.ecore.EObject signatureInstanceModel) throws SignatureValidationFailedException
      Throws:
      SignatureValidationFailedException
    • assertSortingIsEnsuredForControl

      protected void assertSortingIsEnsuredForControl(String controlName)
    • assertSortingIsEnsuredForControl

      protected void assertSortingIsEnsuredForControl(Control controlName)
    • isOuterName

      protected boolean isOuterName(org.eclipse.emf.ecore.EObject eObject)
    • isRoot

      public boolean isRoot(org.eclipse.emf.ecore.EObject eObject)
    • isNode

      public boolean isNode(org.eclipse.emf.ecore.EObject eObject)
    • isEdge

      protected boolean isEdge(org.eclipse.emf.ecore.EObject eObject)
    • createBBigraphContainer

      protected org.eclipse.emf.ecore.EObject createBBigraphContainer(Collection<BigraphEntity.RootEntity> roots, Collection<BigraphEntity.Edge> edges, Collection<BigraphEntity.InnerName> innerNames, Collection<BigraphEntity.OuterName> outerNames)
    • createNameSupplier

      protected static Supplier<String> createNameSupplier(String prefix)
    • createIndexSupplier

      protected static Supplier<Integer> createIndexSupplier()