Class SCMFileSystem

  • All Implemented Interfaces:
    Closeable, AutoCloseable

    public abstract class SCMFileSystem
    extends Object
    implements Closeable
    A virtual file system for a specific SCM potentially pinned to a specific SCMRevision. In contrast to SCMProbe, implementations should not cache results between SCMFileSystem instantiations.

    While some DVCS implementations may need to perform a local checkout in order to be able to implement this API it should be noted that in such cases the local checkout is not a cache but rather a copy of the immutable revisions - this may look and sound like a cache but it isn't as the revision itself is immutable. When a new SCMFileSystem if being instantiated against a null SCMRevision the DVCS system can re-use the previous local checkout after reconfirming that the current revision for the head matches that of the local checkout.

    Where the getRevision() is null or SCMRevision.isDeterministic() a SCMFileSystem can choose to keep the results locally (up to close()) or re-query against the remote.