Class GitProjectSourceProvider

java.lang.Object
com._1c.g5.v8.dt.internal.compare.datasource.AbstractProjectSourceProvider
com._1c.g5.v8.dt.internal.compare.datasource.GitProjectSourceProvider
All Implemented Interfaces:
IProjectSourceProvider, IExtendedProjectSourceProvider

public class GitProjectSourceProvider extends AbstractProjectSourceProvider
  • Constructor Details

    • GitProjectSourceProvider

      public GitProjectSourceProvider(Path repositoryPath, String revision, Path projectPath)
      Constructs the source provider.
      Parameters:
      repositoryPath - the Git repository directory path, cannot be null
      revision - the Git commit reference or GitCompareUtils.INDEX to use index, cannot be null
      projectPath - the project path in Git repository, cannot be null
  • Method Details

    • setBufferShortageMarker

      public static void setBufferShortageMarker()
      Sets the buffer shortage marker. The marker is being set as the thread-local variable to overcome the limitation of jgit exception reporting during the buffer memory shortage
    • fileExists

      public boolean fileExists(Path path)
      Description copied from interface: IProjectSourceProvider
      Checks whether a file for the specified path exists.
      Parameters:
      path - the specified path to check the existence for, cannot be null
      Returns:
      true if the file exists, false otherwise
    • getFullImportRequest

      public ImportRequest getFullImportRequest()
      Description copied from interface: IExtendedProjectSourceProvider
      Gets the full import request.
      Returns:
      The definition of sources that should be imported during the full import request
    • getFileListRecursively

      public List<Path> getFileListRecursively(Path path)
      Description copied from interface: IProjectSourceProvider
      Returns the file list for given folder path and all its subfolders.
      Parameters:
      path - the relative folder path to get the file list for, can not be null
      Returns:
      the list of relative file paths, never null
    • getFileStream

      public InputStream getFileStream(Path path)
      Description copied from interface: IProjectSourceProvider
      Returns a file stream for the specified path.
      Parameters:
      path - the string with the path
      Returns:
      the input stream
    • stop

      public void stop()
      Description copied from interface: IProjectSourceProvider
      Stops the project source provider in the flow of the comparison session closure.
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object