Class AbstractRepository

    • Constructor Detail

      • AbstractRepository

        public AbstractRepository()
      • AbstractRepository

        protected AbstractRepository​(TimeoutConstraint timeoutConstraint)
    • Method Detail

      • addTransferListener

        public void addTransferListener​(TransferListener listener)
        Description copied from interface: Repository
        Add a listener to the repository.
        Specified by:
        addTransferListener in interface Repository
        Parameters:
        listener - The listener to attach to the repository.
      • hasTransferListener

        public boolean hasTransferListener​(TransferListener listener)
        Description copied from interface: Repository
        Determine if a given listener is attached to the repository.
        Specified by:
        hasTransferListener in interface Repository
        Parameters:
        listener - The listener being queried
        Returns:
        true if the provided listener is attached to the repository, false if not.
      • fireTransferInitiated

        protected void fireTransferInitiated​(Resource res,
                                             int requestType)
      • fireTransferStarted

        protected void fireTransferStarted()
      • fireTransferStarted

        protected void fireTransferStarted​(long totalLength)
      • fireTransferProgress

        protected void fireTransferProgress​(long length)
      • fireTransferCompleted

        protected void fireTransferCompleted()
      • fireTransferCompleted

        protected void fireTransferCompleted​(long totalLength)
      • fireTransferError

        protected void fireTransferError()
      • fireTransferError

        protected void fireTransferError​(java.lang.Exception ex)
      • fireTransferEvent

        protected void fireTransferEvent​(TransferEvent evt)
      • getFileSeparator

        public java.lang.String getFileSeparator()
        Description copied from interface: Repository
        Get the repository's file separator string.
        Specified by:
        getFileSeparator in interface Repository
        Returns:
        The repository's file separator delimiter
      • standardize

        public java.lang.String standardize​(java.lang.String source)
        Description copied from interface: Repository
        Normalize a string.
        Specified by:
        standardize in interface Repository
        Parameters:
        source - The string to normalize.
        Returns:
        The normalized string.
      • getName

        public java.lang.String getName()
        Description copied from interface: Repository
        Return the name of the repository
        Specified by:
        getName in interface Repository
        Returns:
        String name
      • setName

        public void setName​(java.lang.String name)
      • toString

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

        public void put​(Artifact artifact,
                        java.io.File source,
                        java.lang.String destination,
                        boolean overwrite)
                 throws java.io.IOException
        Description copied from interface: Repository
        Transfer a resource to the repository
        Specified by:
        put in interface Repository
        Parameters:
        artifact - The artifact to be transferred.
        source - The local file to be transferred.
        destination - Where to transfer the resource.
        overwrite - Whether the transfer should overwrite an existing resource.
        Throws:
        java.io.IOException - On publication failure.
      • put

        protected void put​(java.io.File source,
                           java.lang.String destination,
                           boolean overwrite)
                    throws java.io.IOException
        Throws:
        java.io.IOException