Class BinaryResourceContentImporter

All Implemented Interfaces:
IResourceContentImporter

public final class BinaryResourceContentImporter extends TransactionalBmContentImporter
IResourceContentImporter implementation for BinaryData.
  • Constructor Details

    • BinaryResourceContentImporter

      @Inject public BinaryResourceContentImporter(IBmModelManager bmModelManager, IQualifiedNameFilePathConverter qualifiedNameFilePathConverter)
      Constructs a new instance.
      Parameters:
      qualifiedNameFilePathConverter - The qualified-name-to-file-path converter. May not be null.
  • Method Details

    • supports

      public boolean supports(org.eclipse.core.runtime.IPath path)
      Description copied from interface: IResourceContentImporter
      Checks if this importer supports the specified resource.
      Parameters:
      path - The path to the resource to check. May not be null.
      Returns:
      true if the resource is supported, false otherwise.
    • handleResourceCreationOrModification

      protected byte[] handleResourceCreationOrModification(IBmPlatformTransaction transaction, IBmNamespace namespace, IDtProject project, org.eclipse.core.runtime.IPath path, InputStream content, boolean fullOverride)
      Description copied from class: TransactionalBmContentImporter
      Handles a data import process for an imported resource
      Specified by:
      handleResourceCreationOrModification in class TransactionalBmContentImporter
      Parameters:
      transaction - The data import BM transaction. Never null
      namespace - The target BM namespace for an import. Never null
      project - The target IDtProject. Never null
      path - The imported resource path. May not be null
      content - The imported content stream. May not be null
      fullOverride - Data full override import mode
      Returns:
      Signature of imported data. Never null
    • handleResourceDeletion

      protected void handleResourceDeletion(IBmPlatformTransaction transaction, IBmNamespace namespace, IDtProject project, org.eclipse.core.runtime.IPath path)
      Description copied from class: TransactionalBmContentImporter
      Handles a data removal process for a removed resource
      Specified by:
      handleResourceDeletion in class TransactionalBmContentImporter
      Parameters:
      transaction - The data import BM transaction. Never null
      namespace - The target BM namespace for an import. Never null
      project - Target IDtProject. Never null
      path - The removed resource path. May not be null