test_class.file: org.eclipse.winery.repository/src/test/java/org/eclipse/winery/repository/backend/BackendUtilsTest.java
test_class.identifier: BackendUtilsTest
test_case.body: @Test
      public void synchronizeReferencesDoesNontRemoveExistantFileAndDoesNotRemoveUrls() throws Exception {
          ArtifactTemplateId artifactTemplateId = new ArtifactTemplateId("http://example.org", "test-artifact-template", false);
  
          // alternative test implementation: Use git-based repository
          // this test at hand is closer to the implementation, but easier to write
  
          IRepository repository = mock(IRepository.class);
          ArtifactTemplateFilesDirectoryId artifactTemplateFilesDirectoryId = new ArtifactTemplateFilesDirectoryId(artifactTemplateId);
  
          SortedSet<RepositoryFileReference> containedReferences = new TreeSet<>();
          RepositoryFileReference repositoryFileReference = new RepositoryFileReference(artifactTemplateId, "exists.txt");
          containedReferences.add(repositoryFileReference);
  
          when(repository.getContainedFiles(artifactTemplateFilesDirectoryId)).thenReturn(containedReferences);
  
          TArtifactTemplate artifactTemplate = createArtifactTemplateWithReferenceToAnUrlAndExistentFile();
          when(repository.getElement(artifactTemplateId)).thenReturn(artifactTemplate);
          TArtifactTemplate synchronizhedArtifactTemplate = BackendUtils.synchronizeReferences(repository, artifactTemplateId);
  
          assertEquals(createArtifactTemplateWithReferenceToAnUrlAndExistentFile(), synchronizhedArtifactTemplate);
      }
test_case.class_method_signature: BackendUtilsTest.synchronizeReferencesDoesNontRemoveExistantFileAndDoesNotRemoveUrls()
test_case.full_signature: @Test public void synchronizeReferencesDoesNontRemoveExistantFileAndDoesNotRemoveUrls()
test_case.identifier: synchronizeReferencesDoesNontRemoveExistantFileAndDoesNotRemoveUrls
test_case.invocations: mock add thenReturn when getContainedFiles createArtifactTemplateWithReferenceToAnUrlAndExistentFile thenReturn when getElement synchronizeReferences assertEquals createArtifactTemplateWithReferenceToAnUrlAndExistentFile
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void synchronizeReferencesDoesNontRemoveExistantFileAndDoesNotRemoveUrls()
focal_class.declarator: LOGGER = LoggerFactory.getLogger(BackendUtils.class)
focal_class.modifier: private static final
focal_class.original_string: private static final Logger LOGGER = LoggerFactory.getLogger(BackendUtils.class);
focal_class.type: Logger
focal_class.var_name: LOGGER
focal_class.declarator: MEDIATYPE_APPLICATION_OCTET_STREAM = MediaType.parse("application/octet-stream")
focal_class.modifier: private static final
focal_class.original_string: private static final MediaType MEDIATYPE_APPLICATION_OCTET_STREAM = MediaType.parse("application/octet-stream");
focal_class.type: MediaType
focal_class.var_name: MEDIATYPE_APPLICATION_OCTET_STREAM
focal_class.file: org.eclipse.winery.repository/src/main/java/org/eclipse/winery/repository/backend/BackendUtils.java
focal_class.identifier: BackendUtils
focal_class.class_method_signature: BackendUtils.isFileNewerThanModifiedDate(long millis, String modified)
focal_class.full_signature: public static boolean isFileNewerThanModifiedDate(long millis, String modified)
focal_class.identifier: isFileNewerThanModifiedDate
focal_class.modifiers: public static
focal_class.parameters: (long millis, String modified)
focal_class.return: boolean
focal_class.signature: boolean isFileNewerThanModifiedDate(long millis, String modified)
focal_class.class_method_signature: BackendUtils.getDefinitionsChildId(Class<T> idClass, String qnameStr)
focal_class.full_signature: public static T getDefinitionsChildId(Class<T> idClass, String qnameStr)
focal_class.identifier: getDefinitionsChildId
focal_class.modifiers: public static
focal_class.parameters: (Class<T> idClass, String qnameStr)
focal_class.return: T
focal_class.signature: T getDefinitionsChildId(Class<T> idClass, String qnameStr)
focal_class.class_method_signature: BackendUtils.getDefinitionsChildId(Class<T> idClass, QName qname)
focal_class.full_signature: public static T getDefinitionsChildId(Class<T> idClass, QName qname)
focal_class.identifier: getDefinitionsChildId
focal_class.modifiers: public static
focal_class.parameters: (Class<T> idClass, QName qname)
focal_class.return: T
focal_class.signature: T getDefinitionsChildId(Class<T> idClass, QName qname)
focal_class.class_method_signature: BackendUtils.getDefinitionsChildId(Class<T> idClass, String namespace, String id, boolean URLencoded)
focal_class.full_signature: public static T getDefinitionsChildId(Class<T> idClass, String namespace, String id, boolean URLencoded)
focal_class.identifier: getDefinitionsChildId
focal_class.modifiers: public static
focal_class.parameters: (Class<T> idClass, String namespace, String id, boolean URLencoded)
focal_class.return: T
focal_class.signature: T getDefinitionsChildId(Class<T> idClass, String namespace, String id, boolean URLencoded)
focal_class.class_method_signature: BackendUtils.getNamespace(ToscaElementId id)
focal_class.full_signature: public static Namespace getNamespace(ToscaElementId id)
focal_class.identifier: getNamespace
focal_class.modifiers: public static
focal_class.parameters: (ToscaElementId id)
focal_class.return: Namespace
focal_class.signature: Namespace getNamespace(ToscaElementId id)
focal_class.class_method_signature: BackendUtils.getDefinitionsAsXMLString(TDefinitions definitions)
focal_class.full_signature: public static String getDefinitionsAsXMLString(TDefinitions definitions)
focal_class.identifier: getDefinitionsAsXMLString
focal_class.modifiers: public static
focal_class.parameters: (TDefinitions definitions)
focal_class.return: String
focal_class.signature: String getDefinitionsAsXMLString(TDefinitions definitions)
focal_class.class_method_signature: BackendUtils.getName(DefinitionsChildId instanceId)
focal_class.full_signature: public static String getName(DefinitionsChildId instanceId)
focal_class.identifier: getName
focal_class.modifiers: public static
focal_class.parameters: (DefinitionsChildId instanceId)
focal_class.return: String
focal_class.signature: String getName(DefinitionsChildId instanceId)
focal_class.class_method_signature: BackendUtils.getPathInsideRepo(GenericId id)
focal_class.full_signature: public static String getPathInsideRepo(GenericId id)
focal_class.identifier: getPathInsideRepo
focal_class.modifiers: public static
focal_class.parameters: (GenericId id)
focal_class.return: String
focal_class.signature: String getPathInsideRepo(GenericId id)
focal_class.class_method_signature: BackendUtils.getPathInsideRepo(RepositoryFileReference ref)
focal_class.full_signature: public static String getPathInsideRepo(RepositoryFileReference ref)
focal_class.identifier: getPathInsideRepo
focal_class.modifiers: public static
focal_class.parameters: (RepositoryFileReference ref)
focal_class.return: String
focal_class.signature: String getPathInsideRepo(RepositoryFileReference ref)
focal_class.class_method_signature: BackendUtils.getFilenameAndSubDirectory(RepositoryFileReference ref)
focal_class.full_signature: public static String getFilenameAndSubDirectory(RepositoryFileReference ref)
focal_class.identifier: getFilenameAndSubDirectory
focal_class.modifiers: public static
focal_class.parameters: (RepositoryFileReference ref)
focal_class.return: String
focal_class.signature: String getFilenameAndSubDirectory(RepositoryFileReference ref)
focal_class.class_method_signature: BackendUtils.getRefOfDefinitions(DefinitionsChildId id)
focal_class.full_signature: public static RepositoryFileReference getRefOfDefinitions(DefinitionsChildId id)
focal_class.identifier: getRefOfDefinitions
focal_class.modifiers: public static
focal_class.parameters: (DefinitionsChildId id)
focal_class.return: RepositoryFileReference
focal_class.signature: RepositoryFileReference getRefOfDefinitions(DefinitionsChildId id)
focal_class.class_method_signature: BackendUtils.getFileNameOfDefinitions(DefinitionsChildId id)
focal_class.full_signature: public static String getFileNameOfDefinitions(DefinitionsChildId id)
focal_class.identifier: getFileNameOfDefinitions
focal_class.modifiers: public static
focal_class.parameters: (DefinitionsChildId id)
focal_class.return: String
focal_class.signature: String getFileNameOfDefinitions(DefinitionsChildId id)
focal_class.class_method_signature: BackendUtils.getFileNameOfDefinitions(Class<T> id)
focal_class.full_signature: public static String getFileNameOfDefinitions(Class<T> id)
focal_class.identifier: getFileNameOfDefinitions
focal_class.modifiers: public static
focal_class.parameters: (Class<T> id)
focal_class.return: String
focal_class.signature: String getFileNameOfDefinitions(Class<T> id)
focal_class.class_method_signature: BackendUtils.getTypeForAdminId(Class<? extends AdminId> idClass)
focal_class.full_signature: public static String getTypeForAdminId(Class<? extends AdminId> idClass)
focal_class.identifier: getTypeForAdminId
focal_class.modifiers: public static
focal_class.parameters: (Class<? extends AdminId> idClass)
focal_class.return: String
focal_class.signature: String getTypeForAdminId(Class<? extends AdminId> idClass)
focal_class.class_method_signature: BackendUtils.getRefOfConfiguration(GenericId id)
focal_class.full_signature: public static RepositoryFileReference getRefOfConfiguration(GenericId id)
focal_class.identifier: getRefOfConfiguration
focal_class.modifiers: public static
focal_class.parameters: (GenericId id)
focal_class.return: RepositoryFileReference
focal_class.signature: RepositoryFileReference getRefOfConfiguration(GenericId id)
focal_class.class_method_signature: BackendUtils.getRefOfJsonConfiguration(GenericId id)
focal_class.full_signature: public static RepositoryFileReference getRefOfJsonConfiguration(GenericId id)
focal_class.identifier: getRefOfJsonConfiguration
focal_class.modifiers: public static
focal_class.parameters: (GenericId id)
focal_class.return: RepositoryFileReference
focal_class.signature: RepositoryFileReference getRefOfJsonConfiguration(GenericId id)
focal_class.class_method_signature: BackendUtils.getAllNestedNodeTemplates(TServiceTemplate serviceTemplate)
focal_class.full_signature: public static List<TNodeTemplate> getAllNestedNodeTemplates(TServiceTemplate serviceTemplate)
focal_class.identifier: getAllNestedNodeTemplates
focal_class.modifiers: public static
focal_class.parameters: (TServiceTemplate serviceTemplate)
focal_class.return: List<TNodeTemplate>
focal_class.signature: List<TNodeTemplate> getAllNestedNodeTemplates(TServiceTemplate serviceTemplate)
focal_class.class_method_signature: BackendUtils.getAllReferencedArtifactTemplates(TDeploymentArtifacts tDeploymentArtifacts)
focal_class.full_signature: @NonNull private static Collection<QName> getAllReferencedArtifactTemplates(TDeploymentArtifacts tDeploymentArtifacts)
focal_class.identifier: getAllReferencedArtifactTemplates
focal_class.modifiers: @NonNull private static
focal_class.parameters: (TDeploymentArtifacts tDeploymentArtifacts)
focal_class.return: Collection<QName>
focal_class.signature: Collection<QName> getAllReferencedArtifactTemplates(TDeploymentArtifacts tDeploymentArtifacts)
focal_class.class_method_signature: BackendUtils.getAllReferencedArtifactTemplates(TImplementationArtifacts tImplementationArtifacts)
focal_class.full_signature: private static Collection<QName> getAllReferencedArtifactTemplates(TImplementationArtifacts tImplementationArtifacts)
focal_class.identifier: getAllReferencedArtifactTemplates
focal_class.modifiers: private static
focal_class.parameters: (TImplementationArtifacts tImplementationArtifacts)
focal_class.return: Collection<QName>
focal_class.signature: Collection<QName> getAllReferencedArtifactTemplates(TImplementationArtifacts tImplementationArtifacts)
focal_class.class_method_signature: BackendUtils.getArtifactTemplatesOfReferencedDeploymentArtifacts(TNodeTemplate nodeTemplate)
focal_class.full_signature: public static Collection<QName> getArtifactTemplatesOfReferencedDeploymentArtifacts(TNodeTemplate nodeTemplate)
focal_class.identifier: getArtifactTemplatesOfReferencedDeploymentArtifacts
focal_class.modifiers: public static
focal_class.parameters: (TNodeTemplate nodeTemplate)
focal_class.return: Collection<QName>
focal_class.signature: Collection<QName> getArtifactTemplatesOfReferencedDeploymentArtifacts(TNodeTemplate nodeTemplate)
focal_class.class_method_signature: BackendUtils.getArtifactTemplatesOfReferencedImplementationArtifacts(TNodeTemplate nodeTemplate)
focal_class.full_signature: public static Collection<QName> getArtifactTemplatesOfReferencedImplementationArtifacts(TNodeTemplate nodeTemplate)
focal_class.identifier: getArtifactTemplatesOfReferencedImplementationArtifacts
focal_class.modifiers: public static
focal_class.parameters: (TNodeTemplate nodeTemplate)
focal_class.return: Collection<QName>
focal_class.signature: Collection<QName> getArtifactTemplatesOfReferencedImplementationArtifacts(TNodeTemplate nodeTemplate)
focal_class.class_method_signature: BackendUtils.updateWrapperDefinitions(DefinitionsChildId tcId, Definitions defs)
focal_class.full_signature: public static Definitions updateWrapperDefinitions(DefinitionsChildId tcId, Definitions defs)
focal_class.identifier: updateWrapperDefinitions
focal_class.modifiers: public static
focal_class.parameters: (DefinitionsChildId tcId, Definitions defs)
focal_class.return: Definitions
focal_class.signature: Definitions updateWrapperDefinitions(DefinitionsChildId tcId, Definitions defs)
focal_class.class_method_signature: BackendUtils.clone(TTopologyTemplate topologyTemplate)
focal_class.full_signature: public static TTopologyTemplate clone(TTopologyTemplate topologyTemplate)
focal_class.identifier: clone
focal_class.modifiers: public static
focal_class.parameters: (TTopologyTemplate topologyTemplate)
focal_class.return: TTopologyTemplate
focal_class.signature: TTopologyTemplate clone(TTopologyTemplate topologyTemplate)
focal_class.class_method_signature: BackendUtils.clone(TNodeTemplate nodeTemplate)
focal_class.full_signature: public static TNodeTemplate clone(TNodeTemplate nodeTemplate)
focal_class.identifier: clone
focal_class.modifiers: public static
focal_class.parameters: (TNodeTemplate nodeTemplate)
focal_class.return: TNodeTemplate
focal_class.signature: TNodeTemplate clone(TNodeTemplate nodeTemplate)
focal_class.class_method_signature: BackendUtils.clone(TRelationshipTemplate relationshipTemplate)
focal_class.full_signature: public static TRelationshipTemplate clone(TRelationshipTemplate relationshipTemplate)
focal_class.identifier: clone
focal_class.modifiers: public static
focal_class.parameters: (TRelationshipTemplate relationshipTemplate)
focal_class.return: TRelationshipTemplate
focal_class.signature: TRelationshipTemplate clone(TRelationshipTemplate relationshipTemplate)
focal_class.class_method_signature: BackendUtils.createWrapperDefinitions(DefinitionsChildId tcId)
focal_class.full_signature: public static Definitions createWrapperDefinitions(DefinitionsChildId tcId)
focal_class.identifier: createWrapperDefinitions
focal_class.modifiers: public static
focal_class.parameters: (DefinitionsChildId tcId)
focal_class.return: Definitions
focal_class.signature: Definitions createWrapperDefinitions(DefinitionsChildId tcId)
focal_class.class_method_signature: BackendUtils.createWrapperDefinitionsAndInitialEmptyElement(IRepository repository, DefinitionsChildId id)
focal_class.full_signature: public static Definitions createWrapperDefinitionsAndInitialEmptyElement(IRepository repository, DefinitionsChildId id)
focal_class.identifier: createWrapperDefinitionsAndInitialEmptyElement
focal_class.modifiers: public static
focal_class.parameters: (IRepository repository, DefinitionsChildId id)
focal_class.return: Definitions
focal_class.signature: Definitions createWrapperDefinitionsAndInitialEmptyElement(IRepository repository, DefinitionsChildId id)
focal_class.class_method_signature: BackendUtils.initializeProperties(IRepository repository, TEntityTemplate entityTemplate)
focal_class.full_signature: public static void initializeProperties(IRepository repository, TEntityTemplate entityTemplate)
focal_class.identifier: initializeProperties
focal_class.modifiers: public static
focal_class.parameters: (IRepository repository, TEntityTemplate entityTemplate)
focal_class.return: void
focal_class.signature: void initializeProperties(IRepository repository, TEntityTemplate entityTemplate)
focal_class.class_method_signature: BackendUtils.persist(IRepository repository, DefinitionsChildId id, TExtensibleElements element)
focal_class.full_signature: public static void persist(IRepository repository, DefinitionsChildId id, TExtensibleElements element)
focal_class.identifier: persist
focal_class.modifiers: public static
focal_class.parameters: (IRepository repository, DefinitionsChildId id, TExtensibleElements element)
focal_class.return: void
focal_class.signature: void persist(IRepository repository, DefinitionsChildId id, TExtensibleElements element)
focal_class.class_method_signature: BackendUtils.persist(DefinitionsChildId id, Definitions definitions)
focal_class.full_signature: public static void persist(DefinitionsChildId id, Definitions definitions)
focal_class.identifier: persist
focal_class.modifiers: public static
focal_class.parameters: (DefinitionsChildId id, Definitions definitions)
focal_class.return: void
focal_class.signature: void persist(DefinitionsChildId id, Definitions definitions)
focal_class.class_method_signature: BackendUtils.persist(Object o, RepositoryFileReference ref, MediaType mediaType)
focal_class.full_signature: public static void persist(Object o, RepositoryFileReference ref, MediaType mediaType)
focal_class.identifier: persist
focal_class.modifiers: public static
focal_class.parameters: (Object o, RepositoryFileReference ref, MediaType mediaType)
focal_class.return: void
focal_class.signature: void persist(Object o, RepositoryFileReference ref, MediaType mediaType)
focal_class.class_method_signature: BackendUtils.getXSModel(final RepositoryFileReference ref)
focal_class.full_signature: public static Optional<XSModel> getXSModel(final RepositoryFileReference ref)
focal_class.identifier: getXSModel
focal_class.modifiers: public static
focal_class.parameters: (final RepositoryFileReference ref)
focal_class.return: Optional<XSModel>
focal_class.signature: Optional<XSModel> getXSModel(final RepositoryFileReference ref)
focal_class.class_method_signature: BackendUtils.deriveWPD(TEntityType ci, List<String> errors)
focal_class.full_signature: public static void deriveWPD(TEntityType ci, List<String> errors)
focal_class.identifier: deriveWPD
focal_class.modifiers: public static
focal_class.parameters: (TEntityType ci, List<String> errors)
focal_class.return: void
focal_class.signature: void deriveWPD(TEntityType ci, List<String> errors)
focal_class.class_method_signature: BackendUtils.getAllTOSCAElementIds(Class<T> idClass)
focal_class.full_signature: public SortedSet<T> getAllTOSCAElementIds(Class<T> idClass)
focal_class.identifier: getAllTOSCAElementIds
focal_class.modifiers: public
focal_class.parameters: (Class<T> idClass)
focal_class.return: SortedSet<T>
focal_class.signature: SortedSet<T> getAllTOSCAElementIds(Class<T> idClass)
focal_class.class_method_signature: BackendUtils.convertDefinitionsChildIdCollectionToQNameCollection(Collection<? extends DefinitionsChildId> col)
focal_class.full_signature: public static Collection<QName> convertDefinitionsChildIdCollectionToQNameCollection(Collection<? extends DefinitionsChildId> col)
focal_class.identifier: convertDefinitionsChildIdCollectionToQNameCollection
focal_class.modifiers: public static
focal_class.parameters: (Collection<? extends DefinitionsChildId> col)
focal_class.return: Collection<QName>
focal_class.signature: Collection<QName> convertDefinitionsChildIdCollectionToQNameCollection(Collection<? extends DefinitionsChildId> col)
focal_class.class_method_signature: BackendUtils.getMimeType(BufferedInputStream bis, String fn)
focal_class.full_signature: public static MediaType getMimeType(BufferedInputStream bis, String fn)
focal_class.identifier: getMimeType
focal_class.modifiers: public static
focal_class.parameters: (BufferedInputStream bis, String fn)
focal_class.return: MediaType
focal_class.signature: MediaType getMimeType(BufferedInputStream bis, String fn)
focal_class.class_method_signature: BackendUtils.getFixedMimeType(BufferedInputStream is, String fileName, MediaType mediaType)
focal_class.full_signature: public static MediaType getFixedMimeType(BufferedInputStream is, String fileName, MediaType mediaType)
focal_class.identifier: getFixedMimeType
focal_class.modifiers: public static
focal_class.parameters: (BufferedInputStream is, String fileName, MediaType mediaType)
focal_class.return: MediaType
focal_class.signature: MediaType getFixedMimeType(BufferedInputStream is, String fileName, MediaType mediaType)
focal_class.class_method_signature: BackendUtils.copyIdToFields(HasIdInIdOrNameField element, DefinitionsChildId id)
focal_class.full_signature: public static void copyIdToFields(HasIdInIdOrNameField element, DefinitionsChildId id)
focal_class.identifier: copyIdToFields
focal_class.modifiers: public static
focal_class.parameters: (HasIdInIdOrNameField element, DefinitionsChildId id)
focal_class.return: void
focal_class.signature: void copyIdToFields(HasIdInIdOrNameField element, DefinitionsChildId id)
focal_class.class_method_signature: BackendUtils.getGitInformation(DirectoryId directoryId)
focal_class.full_signature: public static GitInfo getGitInformation(DirectoryId directoryId)
focal_class.identifier: getGitInformation
focal_class.modifiers: public static
focal_class.parameters: (DirectoryId directoryId)
focal_class.return: GitInfo
focal_class.signature: GitInfo getGitInformation(DirectoryId directoryId)
focal_class.class_method_signature: BackendUtils.getTArtifactTemplate(DirectoryId directoryId)
focal_class.full_signature: public static TArtifactTemplate getTArtifactTemplate(DirectoryId directoryId)
focal_class.identifier: getTArtifactTemplate
focal_class.modifiers: public static
focal_class.parameters: (DirectoryId directoryId)
focal_class.return: TArtifactTemplate
focal_class.signature: TArtifactTemplate getTArtifactTemplate(DirectoryId directoryId)
focal_class.class_method_signature: BackendUtils.getYamlArtifactsDirectoryOfNodeTemplate(ServiceTemplateId serviceTemplateId, String nodeTemplateId)
focal_class.full_signature: public static DirectoryId getYamlArtifactsDirectoryOfNodeTemplate(ServiceTemplateId serviceTemplateId, String nodeTemplateId)
focal_class.identifier: getYamlArtifactsDirectoryOfNodeTemplate
focal_class.modifiers: public static
focal_class.parameters: (ServiceTemplateId serviceTemplateId, String nodeTemplateId)
focal_class.return: DirectoryId
focal_class.signature: DirectoryId getYamlArtifactsDirectoryOfNodeTemplate(ServiceTemplateId serviceTemplateId, String nodeTemplateId)
focal_class.class_method_signature: BackendUtils.getYamlArtifactDirectoryOfNodeTemplate(ServiceTemplateId serviceTemplateId,
                                                                       String nodeTemplateId, String yamlArtifactId)
focal_class.full_signature: public static DirectoryId getYamlArtifactDirectoryOfNodeTemplate(ServiceTemplateId serviceTemplateId,
                                                                       String nodeTemplateId, String yamlArtifactId)
focal_class.identifier: getYamlArtifactDirectoryOfNodeTemplate
focal_class.modifiers: public static
focal_class.parameters: (ServiceTemplateId serviceTemplateId,
                                                                       String nodeTemplateId, String yamlArtifactId)
focal_class.return: DirectoryId
focal_class.signature: DirectoryId getYamlArtifactDirectoryOfNodeTemplate(ServiceTemplateId serviceTemplateId,
                                                                       String nodeTemplateId, String yamlArtifactId)
focal_class.class_method_signature: BackendUtils.isGlobMatch(String glob, Path path)
focal_class.full_signature: public static boolean isGlobMatch(String glob, Path path)
focal_class.identifier: isGlobMatch
focal_class.modifiers: public static
focal_class.parameters: (String glob, Path path)
focal_class.return: boolean
focal_class.signature: boolean isGlobMatch(String glob, Path path)
focal_class.class_method_signature: BackendUtils.injectArtifactTemplateIntoDeploymentArtifact(ServiceTemplateId serviceTemplate, String nodeTemplateId, String deploymentArtifactId, ArtifactTemplateId artifactTemplate)
focal_class.full_signature: public static boolean injectArtifactTemplateIntoDeploymentArtifact(ServiceTemplateId serviceTemplate, String nodeTemplateId, String deploymentArtifactId, ArtifactTemplateId artifactTemplate)
focal_class.identifier: injectArtifactTemplateIntoDeploymentArtifact
focal_class.modifiers: public static
focal_class.parameters: (ServiceTemplateId serviceTemplate, String nodeTemplateId, String deploymentArtifactId, ArtifactTemplateId artifactTemplate)
focal_class.return: boolean
focal_class.signature: boolean injectArtifactTemplateIntoDeploymentArtifact(ServiceTemplateId serviceTemplate, String nodeTemplateId, String deploymentArtifactId, ArtifactTemplateId artifactTemplate)
focal_class.class_method_signature: BackendUtils.getImportLocationForWinerysPropertiesDefinitionXSD(EntityTypeId tcId, URI uri, String wrapperElementLocalName)
focal_class.full_signature: public static String getImportLocationForWinerysPropertiesDefinitionXSD(EntityTypeId tcId, URI uri, String wrapperElementLocalName)
focal_class.identifier: getImportLocationForWinerysPropertiesDefinitionXSD
focal_class.modifiers: public static
focal_class.parameters: (EntityTypeId tcId, URI uri, String wrapperElementLocalName)
focal_class.return: String
focal_class.signature: String getImportLocationForWinerysPropertiesDefinitionXSD(EntityTypeId tcId, URI uri, String wrapperElementLocalName)
focal_class.class_method_signature: BackendUtils.synchronizeReferences(IRepository repository, ArtifactTemplateId id)
focal_class.full_signature: public static TArtifactTemplate synchronizeReferences(IRepository repository, ArtifactTemplateId id)
focal_class.identifier: synchronizeReferences
focal_class.modifiers: public static
focal_class.parameters: (IRepository repository, ArtifactTemplateId id)
focal_class.return: TArtifactTemplate
focal_class.signature: TArtifactTemplate synchronizeReferences(IRepository repository, ArtifactTemplateId id)
focal_class.class_method_signature: BackendUtils.determineChanges(List<TArtifactReference> artRefList, SortedSet<RepositoryFileReference> filesOnDisk, List<TArtifactReference> toRemove, List<RepositoryFileReference> toAdd)
focal_class.full_signature: private static void determineChanges(List<TArtifactReference> artRefList, SortedSet<RepositoryFileReference> filesOnDisk, List<TArtifactReference> toRemove, List<RepositoryFileReference> toAdd)
focal_class.identifier: determineChanges
focal_class.modifiers: private static
focal_class.parameters: (List<TArtifactReference> artRefList, SortedSet<RepositoryFileReference> filesOnDisk, List<TArtifactReference> toRemove, List<RepositoryFileReference> toAdd)
focal_class.return: void
focal_class.signature: void determineChanges(List<TArtifactReference> artRefList, SortedSet<RepositoryFileReference> filesOnDisk, List<TArtifactReference> toRemove, List<RepositoryFileReference> toAdd)
focal_class.class_method_signature: BackendUtils.synchronizeReferences(ServiceTemplateId id)
focal_class.full_signature: public static void synchronizeReferences(ServiceTemplateId id)
focal_class.identifier: synchronizeReferences
focal_class.modifiers: public static
focal_class.parameters: (ServiceTemplateId id)
focal_class.return: void
focal_class.signature: void synchronizeReferences(ServiceTemplateId id)
focal_class.class_method_signature: BackendUtils.getXMLAsString(Object obj)
focal_class.full_signature: public static String getXMLAsString(Object obj)
focal_class.identifier: getXMLAsString
focal_class.modifiers: public static
focal_class.parameters: (Object obj)
focal_class.return: String
focal_class.signature: String getXMLAsString(Object obj)
focal_class.class_method_signature: BackendUtils.getXMLAsString(T obj, boolean includeProcessingInstruction)
focal_class.full_signature: public static String getXMLAsString(T obj, boolean includeProcessingInstruction)
focal_class.identifier: getXMLAsString
focal_class.modifiers: public static
focal_class.parameters: (T obj, boolean includeProcessingInstruction)
focal_class.return: String
focal_class.signature: String getXMLAsString(T obj, boolean includeProcessingInstruction)
focal_class.class_method_signature: BackendUtils.getXMLAsString(Class<T> clazz, T obj, boolean includeProcessingInstruction)
focal_class.full_signature: public static String getXMLAsString(Class<T> clazz, T obj, boolean includeProcessingInstruction)
focal_class.identifier: getXMLAsString
focal_class.modifiers: public static
focal_class.parameters: (Class<T> clazz, T obj, boolean includeProcessingInstruction)
focal_class.return: String
focal_class.signature: String getXMLAsString(Class<T> clazz, T obj, boolean includeProcessingInstruction)
focal_class.class_method_signature: BackendUtils.getErrorHandler(StringBuilder sb)
focal_class.full_signature: public static ErrorHandler getErrorHandler(StringBuilder sb)
focal_class.identifier: getErrorHandler
focal_class.modifiers: public static
focal_class.parameters: (StringBuilder sb)
focal_class.return: ErrorHandler
focal_class.signature: ErrorHandler getErrorHandler(StringBuilder sb)
focal_class.class_method_signature: BackendUtils.getRepositoryFileReference(Path rootPath, Path path, DirectoryId directoryId)
focal_class.full_signature: public static RepositoryFileReference getRepositoryFileReference(Path rootPath, Path path, DirectoryId directoryId)
focal_class.identifier: getRepositoryFileReference
focal_class.modifiers: public static
focal_class.parameters: (Path rootPath, Path path, DirectoryId directoryId)
focal_class.return: RepositoryFileReference
focal_class.signature: RepositoryFileReference getRepositoryFileReference(Path rootPath, Path path, DirectoryId directoryId)
focal_class.class_method_signature: BackendUtils.importDirectory(Path rootPath, IRepository repository, DirectoryId dir)
focal_class.full_signature: public static void importDirectory(Path rootPath, IRepository repository, DirectoryId dir)
focal_class.identifier: importDirectory
focal_class.modifiers: public static
focal_class.parameters: (Path rootPath, IRepository repository, DirectoryId dir)
focal_class.return: void
focal_class.signature: void importDirectory(Path rootPath, IRepository repository, DirectoryId dir)
focal_class.class_method_signature: BackendUtils.getDefinitionsHavingCorrectImports(IRepository repository, DefinitionsChildId id)
focal_class.full_signature: public static Definitions getDefinitionsHavingCorrectImports(IRepository repository, DefinitionsChildId id)
focal_class.identifier: getDefinitionsHavingCorrectImports
focal_class.modifiers: public static
focal_class.parameters: (IRepository repository, DefinitionsChildId id)
focal_class.return: Definitions
focal_class.signature: Definitions getDefinitionsHavingCorrectImports(IRepository repository, DefinitionsChildId id)
focal_class.class_method_signature: BackendUtils.mergeTopologyTemplateAinTopologyTemplateB(ServiceTemplateId serviceTemplateIdA, ServiceTemplateId serviceTemplateIdB)
focal_class.full_signature: public static void mergeTopologyTemplateAinTopologyTemplateB(ServiceTemplateId serviceTemplateIdA, ServiceTemplateId serviceTemplateIdB)
focal_class.identifier: mergeTopologyTemplateAinTopologyTemplateB
focal_class.modifiers: public static
focal_class.parameters: (ServiceTemplateId serviceTemplateIdA, ServiceTemplateId serviceTemplateIdB)
focal_class.return: void
focal_class.signature: void mergeTopologyTemplateAinTopologyTemplateB(ServiceTemplateId serviceTemplateIdA, ServiceTemplateId serviceTemplateIdB)
focal_class.class_method_signature: BackendUtils.mergeTopologyTemplateAinTopologyTemplateB(TTopologyTemplate topologyTemplateA, TTopologyTemplate topologyTemplateB)
focal_class.full_signature: public static Map<String, String> mergeTopologyTemplateAinTopologyTemplateB(TTopologyTemplate topologyTemplateA, TTopologyTemplate topologyTemplateB)
focal_class.identifier: mergeTopologyTemplateAinTopologyTemplateB
focal_class.modifiers: public static
focal_class.parameters: (TTopologyTemplate topologyTemplateA, TTopologyTemplate topologyTemplateB)
focal_class.return: Map<String, String>
focal_class.signature: Map<String, String> mergeTopologyTemplateAinTopologyTemplateB(TTopologyTemplate topologyTemplateA, TTopologyTemplate topologyTemplateB)
focal_class.class_method_signature: BackendUtils.mergeTopologyTemplateAinTopologyTemplateB(TTopologyTemplate topologyTemplateA, TTopologyTemplate topologyTemplateB, List<TEntityTemplate> stayingElements)
focal_class.full_signature: public static Map<String, String> mergeTopologyTemplateAinTopologyTemplateB(TTopologyTemplate topologyTemplateA, TTopologyTemplate topologyTemplateB, List<TEntityTemplate> stayingElements)
focal_class.identifier: mergeTopologyTemplateAinTopologyTemplateB
focal_class.modifiers: public static
focal_class.parameters: (TTopologyTemplate topologyTemplateA, TTopologyTemplate topologyTemplateB, List<TEntityTemplate> stayingElements)
focal_class.return: Map<String, String>
focal_class.signature: Map<String, String> mergeTopologyTemplateAinTopologyTemplateB(TTopologyTemplate topologyTemplateA, TTopologyTemplate topologyTemplateB, List<TEntityTemplate> stayingElements)
focal_class.class_method_signature: BackendUtils.updateVersionOfNodeTemplate(TTopologyTemplate topologyTemplate, String nodeTemplateId, String newComponentType)
focal_class.full_signature: public static TTopologyTemplate updateVersionOfNodeTemplate(TTopologyTemplate topologyTemplate, String nodeTemplateId, String newComponentType)
focal_class.identifier: updateVersionOfNodeTemplate
focal_class.modifiers: public static
focal_class.parameters: (TTopologyTemplate topologyTemplate, String nodeTemplateId, String newComponentType)
focal_class.return: TTopologyTemplate
focal_class.signature: TTopologyTemplate updateVersionOfNodeTemplate(TTopologyTemplate topologyTemplate, String nodeTemplateId, String newComponentType)
focal_class.class_method_signature: BackendUtils.getOtherVersionDefinitionsFromDefinition(DefinitionsChildId id)
focal_class.full_signature: public static SortedSet<? extends DefinitionsChildId> getOtherVersionDefinitionsFromDefinition(DefinitionsChildId id)
focal_class.identifier: getOtherVersionDefinitionsFromDefinition
focal_class.modifiers: public static
focal_class.parameters: (DefinitionsChildId id)
focal_class.return: SortedSet<? extends DefinitionsChildId>
focal_class.signature: SortedSet<? extends DefinitionsChildId> getOtherVersionDefinitionsFromDefinition(DefinitionsChildId id)
focal_class.class_method_signature: BackendUtils.getAllVersionsOfOneDefinition(DefinitionsChildId id)
focal_class.full_signature: public static List<WineryVersion> getAllVersionsOfOneDefinition(DefinitionsChildId id)
focal_class.identifier: getAllVersionsOfOneDefinition
focal_class.modifiers: public static
focal_class.parameters: (DefinitionsChildId id)
focal_class.return: List<WineryVersion>
focal_class.signature: List<WineryVersion> getAllVersionsOfOneDefinition(DefinitionsChildId id)
focal_class.class_method_signature: BackendUtils.getCurrentVersionWithAllFlags(DefinitionsChildId id)
focal_class.full_signature: public static WineryVersion getCurrentVersionWithAllFlags(DefinitionsChildId id)
focal_class.identifier: getCurrentVersionWithAllFlags
focal_class.modifiers: public static
focal_class.parameters: (DefinitionsChildId id)
focal_class.return: WineryVersion
focal_class.signature: WineryVersion getCurrentVersionWithAllFlags(DefinitionsChildId id)
focal_class.class_method_signature: BackendUtils.getVersionsList(DefinitionsChildId id, final WineryVersion[] current)
focal_class.full_signature: private static List<WineryVersion> getVersionsList(DefinitionsChildId id, final WineryVersion[] current)
focal_class.identifier: getVersionsList
focal_class.modifiers: private static
focal_class.parameters: (DefinitionsChildId id, final WineryVersion[] current)
focal_class.return: List<WineryVersion>
focal_class.signature: List<WineryVersion> getVersionsList(DefinitionsChildId id, final WineryVersion[] current)
focal_class.class_method_signature: BackendUtils.getPredecessor(DefinitionsChildId id)
focal_class.full_signature: public static WineryVersion getPredecessor(DefinitionsChildId id)
focal_class.identifier: getPredecessor
focal_class.modifiers: public static
focal_class.parameters: (DefinitionsChildId id)
focal_class.return: WineryVersion
focal_class.signature: WineryVersion getPredecessor(DefinitionsChildId id)
focal_class.class_method_signature: BackendUtils.compare(DefinitionsChildId id, WineryVersion versionToCompareTo)
focal_class.full_signature: public static ToscaDiff compare(DefinitionsChildId id, WineryVersion versionToCompareTo)
focal_class.identifier: compare
focal_class.modifiers: public static
focal_class.parameters: (DefinitionsChildId id, WineryVersion versionToCompareTo)
focal_class.return: ToscaDiff
focal_class.signature: ToscaDiff compare(DefinitionsChildId id, WineryVersion versionToCompareTo)
focal_class.class_method_signature: BackendUtils.commit(DefinitionsChildId componentToCommit, String commitMessagePrefix)
focal_class.full_signature: public static void commit(DefinitionsChildId componentToCommit, String commitMessagePrefix)
focal_class.identifier: commit
focal_class.modifiers: public static
focal_class.parameters: (DefinitionsChildId componentToCommit, String commitMessagePrefix)
focal_class.return: void
focal_class.signature: void commit(DefinitionsChildId componentToCommit, String commitMessagePrefix)
focal_method.body: public static TArtifactTemplate synchronizeReferences(IRepository repository, ArtifactTemplateId id) throws IOException {
          TArtifactTemplate template = repository.getElement(id);
          List<TArtifactReference> toRemove = new ArrayList<>();
          List<RepositoryFileReference> toAdd = new ArrayList<>();
          TArtifactTemplate.ArtifactReferences artifactReferences = template.getArtifactReferences();
          DirectoryId fileDir = new ArtifactTemplateFilesDirectoryId(id);
          SortedSet<RepositoryFileReference> files = repository.getContainedFiles(fileDir);
  
          if (artifactReferences == null) {
              artifactReferences = new TArtifactTemplate.ArtifactReferences();
              template.setArtifactReferences(artifactReferences);
          }
  
          List<TArtifactReference> artRefList = artifactReferences.getArtifactReference();
          determineChanges(artRefList, files, toRemove, toAdd);
  
          if (toAdd.size() > 0 || toRemove.size() > 0) {
              // apply removal list
              toRemove.forEach(artRefList::remove);
  
              // apply addition list
              artRefList.addAll(toAdd.stream().map(fileRef -> {
                  String path = Util.getUrlPath(fileRef);
  
                  // put path into data structure
                  // we do not use Include/Exclude as we directly reference a concrete file
                  TArtifactReference artRef = new TArtifactReference();
                  artRef.setReference(path);
  
                  return artRef;
              }).collect(Collectors.toList()));
  
              // finally, persist only if something changed
              BackendUtils.persist(repository, id, template);
          }
  
          return template;
      }
focal_method.class_method_signature: BackendUtils.synchronizeReferences(IRepository repository, ArtifactTemplateId id)
focal_method.full_signature: public static TArtifactTemplate synchronizeReferences(IRepository repository, ArtifactTemplateId id)
focal_method.identifier: synchronizeReferences
focal_method.invocations: getElement getArtifactReferences getContainedFiles setArtifactReferences getArtifactReference determineChanges size size forEach addAll collect map stream getUrlPath setReference toList persist
focal_method.modifiers: public static
focal_method.parameters: (IRepository repository, ArtifactTemplateId id)
focal_method.return: TArtifactTemplate
focal_method.signature: TArtifactTemplate synchronizeReferences(IRepository repository, ArtifactTemplateId id)