Interface IFileRevision

All Known Implementing Classes:
FileRevision

public interface IFileRevision
Represents an individual revision of a file.
Since:
3.2
Restriction:
This interface is not intended to be implemented by clients. Clients can instead subclass FileRevision.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Returns whether the file represented by this state exists.
    Returns the author of this revision or null if this information is not available.
    Returns the branches names of file revision.
    Returns the comment for this file revision or null if this information is not available.
    Returns the unique identifier for this file revision or null if one is not available.
    Returns the name of the file to which this state is associated
    Returns the storage for this file revision.
    Returns the set of tags available for this file revision.
    long
    Returns the time stamp of this revision as a long or -1 if the timestamp is unknown.
    Returns the URI of the file to which this state is associated or null if the file does not have a URI.
    boolean
    Returns whether this particular file revision has at least one supported property missing.
    Returns an IFileRevision with all supported properties present.
  • Method Details

    • getStorage

      IStorage getStorage(IProgressMonitor monitor) throws CoreException
      Returns the storage for this file revision. If the returned storage is an instance of IFile clients can assume that this file state represents the current state of the returned IFile.
      Parameters:
      monitor - a progress monitor
      Returns:
      IStorage containing file storage
      Throws:
      CoreException - if an error occurs
    • getName

      String getName()
      Returns the name of the file to which this state is associated
      Returns:
      String containing the name of the file
    • getURI

      URI getURI()
      Returns the URI of the file to which this state is associated or null if the file does not have a URI.
      Returns:
      URI of the file to which this state is associated
    • getTimestamp

      long getTimestamp()
      Returns the time stamp of this revision as a long or -1 if the timestamp is unknown.
      Returns:
      a long that represents the time of this revision as the number of milliseconds since the base time
      See Also:
    • exists

      boolean exists()
      Returns whether the file represented by this state exists.
      Returns:
      whether the file represented by this state exists
    • getContentIdentifier

      String getContentIdentifier()
      Returns the unique identifier for this file revision or null if one is not available. If null is returned, clients can use the timestamp to differentiate revisions.
      Returns:
      the unique identifier for this file revision or null
    • getAuthor

      String getAuthor()
      Returns the author of this revision or null if this information is not available.
      Returns:
      the author of this revision or null
    • getComment

      String getComment()
      Returns the comment for this file revision or null if this information is not available.
      Returns:
      the comment for this file revision or null
    • getBranches

      ITag[] getBranches()
      Returns the branches names of file revision.
      Returns:
      an array of ITag's if branch names exist for this revision or an empty ITag array if no names exist
      Since:
      3.6
    • getTags

      ITag[] getTags()
      Returns the set of tags available for this file revision.
      Returns:
      an array of ITag's if ITags exist for this revision or an empty ITag array if no tags exist
    • isPropertyMissing

      boolean isPropertyMissing()
      Returns whether this particular file revision has at least one supported property missing. If the revision is missing some queries clients can use withAllProperties(IProgressMonitor).
      Returns:
      whether this particular file revision has at least one supported property missing
    • withAllProperties

      IFileRevision withAllProperties(IProgressMonitor monitor) throws CoreException
      Returns an IFileRevision with all supported properties present.
      Parameters:
      monitor - a monitor
      Returns:
      a complete version of this file revision or null
      Throws:
      CoreException - if an error occurs