Class SynchronizationInfo

  • All Implemented Interfaces:
    java.io.Serializable

    public class SynchronizationInfo
    extends java.lang.Object
    implements java.io.Serializable
    The class that represents the information about the synchronization state between the file that is located in the workspace and the file that is located in the repository. A file can exist independently in the workspace and repository. It can be updated in either place at any time. Because of this fact, the data structure contains information that explains the state of the file. Does it exist in the workspace or in the repository? Does it exist in both places? Was the workspace file synchronized with the repository file at some point? If so, which version of the repository file? Is the file in sync with the repository file or has the repository file changed? Or has the workspace file changed?

    All of these questions can be answered with these details. It contains information about the state of the file in the workspace (if it exists). It provides information about the state of the file in the repository (if it exists). It provides information about the synchronization state between the workspace and the repository to tell the user whether the file has been retrieved from the repository. It also provides detailed information about the state of the files in case the files are out-of-sync, details are provided to determine whether the file in the workspace has changed or whether the file in the repository has changed, or both.

    Since:
    1.7
    See Also:
    Serialized Form
    • Constructor Detail

      • SynchronizationInfo

        public SynchronizationInfo​(java.lang.String path,
                                   RepositoryFileInfo repositoryFileInfo,
                                   SynchronizationFileInfo synchronizationFileInfo,
                                   WorkspaceFileInfo workspaceFileInfo,
                                   SynchronizationInfo.FileStatus fileStatus,
                                   SynchronizationInfo.SynchronizationStatus synchronizationStatus,
                                   SynchronizationInfo.CheckoutStatus checkoutStatus)
        Initializing constructor that sets the values of all variables.

        It is not intended or recommended that the consumer of the API construct these objects.

        Parameters:
        path - The full path to the file.
        repositoryFileInfo - The repository file information, if the file exists in the repository.
        synchronizationFileInfo - The synchronization details for the file.
        workspaceFileInfo - The workspace file information, if the file exists in the workspace.
        fileStatus - The location in which the file exists.
        synchronizationStatus - The synchronization status of the file.
        checkoutStatus - The checkout status of the file.
    • Method Detail

      • getPath

        public java.lang.String getPath()
        Gets the file path that is associated with the synchronization information.
        Returns:
        The file path that is associated with the synchronization information.
      • getRepositoryFileInfo

        public RepositoryFileInfo getRepositoryFileInfo()
        Gets the repository file information, if the file exists in the repository. If it does not exist, then this returns null.
        Returns:
        The repository file information if the file exists in the repository. If it does not exist, then this returns null.
      • getSynchronizationFileInfo

        public SynchronizationFileInfo getSynchronizationFileInfo()
        Gets the synchronization file information, if the file was synchronized between the workspace and repository. If it was not synchronized, this returns null.
        Returns:
        The synchronization file information, if the file was synchronized between the workspace and repository. If it was not synchronized, this returns null.
      • getWorkspaceFileInfo

        public WorkspaceFileInfo getWorkspaceFileInfo()
        Gets the workspace file information, if the file exists in the workspace. If it does not exist, this returns null.
        Returns:
        The workspace file information, if the file exists in the workspace. If it does not exist, this returns null.
      • getSynchronizationStatus

        public SynchronizationInfo.SynchronizationStatus getSynchronizationStatus()
        Gets the synchronization status between the repository and workspace files.
        Returns:
        The synchronization status between the repository and workspace files.
      • hashCode

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

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object