Interface ITranslationStorageProvider

All Known Implementing Classes:
AbstractFileStorageProvider, ContextDefStorageProvider, ContextFileStorageProvider, DbViewTermsStorageProvider, DefaultEditingStorageProvider, DictionaryFileStorageProvider

public interface ITranslationStorageProvider
The ITranslationStorageProvider provides storage place for translations. Provider must return at least one segment of storage. Implementations must be contributed to com.e1c.langtool.translationStorageProvider extension point.
  • Method Details

    • getProviderId

      String getProviderId()
      Gets the provider id.
      Returns:
      the provider id
    • isActive

      boolean isActive()
      Checks whether it active and can be used or not.
      Returns:
      true, if is active
    • initialize

      void initialize(org.eclipse.core.resources.IProject project, List<String> segments)
      Initialize.
      Parameters:
      project - the project
      segments - the segments
    • getStorageSegments

      List<String> getStorageSegments(org.eclipse.core.resources.IProject project)
      At least one segment ID should be returned to use the provider. String cannot contains `:`, which used for separation provider_id and segment for global "Storage ID" in the project: com.e1c.langtool.storage:common com.e1c.langtool.storage:context
      Parameters:
      project - the project
      Returns:
      the storage segments
    • getStorageDescription

      String getStorageDescription(org.eclipse.core.resources.IProject project, String segment)
      Gets the storage description.
      Parameters:
      project - the project
      segment - the segment
      Returns:
      the storage description
    • getStorage

      ITranslationStorageProvider.Storage getStorage(org.eclipse.core.resources.IProject project, String segment)
      Gets the storage.
      Parameters:
      project - the project
      segment - the segment
      Returns:
      the storage