Class Uploader

    • Constructor Detail

      • Uploader

        public Uploader()
        Constructor to run this application as an Applet.
      • Uploader

        public Uploader​(JFrame ownerFrame,
                        Properties standAloneArgumentProperties)
                 throws org.jets3t.service.S3ServiceException
        Constructor to run this application in a stand-alone window.
        Parameters:
        ownerFrame - the frame the application will be displayed in
        Throws:
        org.jets3t.service.S3ServiceException
    • Method Detail

      • init

        public void init()
        Prepares application to run as a GUI by finding/creating a root owner JFrame, and (if necessary) creating a directory for storing remembered logins.
        Overrides:
        init in class Applet
      • s3ServiceEventPerformed

        public void s3ServiceEventPerformed​(org.jets3t.service.multithread.CreateObjectsEvent event)
        Listener method that responds to events from the jets3t toolkit when objects are created in S3 - ie when files are uploaded.
        Specified by:
        s3ServiceEventPerformed in interface org.jets3t.service.multithread.S3ServiceEventListener
      • followHyperlink

        public void followHyperlink​(URL url,
                                    String target)
        Follows hyperlinks clicked on by a user. This is achieved differently depending on whether Cockpit is running as an applet or as a stand-alone application:
        • Application: Detects the default browser application for the user's system (using BareBonesBrowserLaunch) and opens the link as a new window in that browser
        • Applet: Opens the link in the current browser using the applet's context
        Specified by:
        followHyperlink in interface org.jets3t.gui.HyperlinkActivatedListener
        Parameters:
        url - the url to open
        target - the target pane to open the url in, eg "_blank". This may be null.
      • setCredentials

        public void setCredentials​(org.apache.http.auth.AuthScope authscope,
                                   org.apache.http.auth.Credentials credentials)
        Specified by:
        setCredentials in interface org.apache.http.client.CredentialsProvider
      • clear

        public void clear()
        Clear credentials.
        Specified by:
        clear in interface org.apache.http.client.CredentialsProvider
      • getCredentials

        public org.apache.http.auth.Credentials getCredentials​(org.apache.http.auth.AuthScope scope)
        Implementation method for the CredentialsProvider interface.

        Based on sample code: InteractiveAuthenticationExample

        Specified by:
        getCredentials in interface org.apache.http.client.CredentialsProvider
      • s3ServiceEventPerformed

        public void s3ServiceEventPerformed​(org.jets3t.service.multithread.ListObjectsEvent event)
        Specified by:
        s3ServiceEventPerformed in interface org.jets3t.service.multithread.S3ServiceEventListener
      • s3ServiceEventPerformed

        public void s3ServiceEventPerformed​(org.jets3t.service.multithread.CreateBucketsEvent event)
        Specified by:
        s3ServiceEventPerformed in interface org.jets3t.service.multithread.S3ServiceEventListener
      • s3ServiceEventPerformed

        public void s3ServiceEventPerformed​(org.jets3t.service.multithread.DeleteObjectsEvent event)
        Specified by:
        s3ServiceEventPerformed in interface org.jets3t.service.multithread.S3ServiceEventListener
      • s3ServiceEventPerformed

        public void s3ServiceEventPerformed​(org.jets3t.service.multithread.GetObjectsEvent event)
        Specified by:
        s3ServiceEventPerformed in interface org.jets3t.service.multithread.S3ServiceEventListener
      • s3ServiceEventPerformed

        public void s3ServiceEventPerformed​(org.jets3t.service.multithread.GetObjectHeadsEvent event)
        Specified by:
        s3ServiceEventPerformed in interface org.jets3t.service.multithread.S3ServiceEventListener
      • s3ServiceEventPerformed

        public void s3ServiceEventPerformed​(org.jets3t.service.multithread.LookupACLEvent event)
        Specified by:
        s3ServiceEventPerformed in interface org.jets3t.service.multithread.S3ServiceEventListener
      • s3ServiceEventPerformed

        public void s3ServiceEventPerformed​(org.jets3t.service.multithread.UpdateACLEvent event)
        Specified by:
        s3ServiceEventPerformed in interface org.jets3t.service.multithread.S3ServiceEventListener
      • s3ServiceEventPerformed

        public void s3ServiceEventPerformed​(org.jets3t.service.multithread.DownloadObjectsEvent event)
        Specified by:
        s3ServiceEventPerformed in interface org.jets3t.service.multithread.S3ServiceEventListener
      • s3ServiceEventPerformed

        public void s3ServiceEventPerformed​(org.jets3t.service.multithread.CopyObjectsEvent event)
        Specified by:
        s3ServiceEventPerformed in interface org.jets3t.service.multithread.S3ServiceEventListener
      • s3ServiceEventPerformed

        public void s3ServiceEventPerformed​(org.jets3t.service.multithread.DeleteVersionedObjectsEvent event)
        Specified by:
        s3ServiceEventPerformed in interface org.jets3t.service.multithread.S3ServiceEventListener
      • main

        public static void main​(String[] args)
                         throws Exception
        Run the Uploader as a stand-alone application.
        Parameters:
        args -
        Throws:
        Exception