Class AbstractLaunchStep

  • All Implemented Interfaces:
    LaunchStep
    Direct Known Subclasses:
    BaseStep

    public abstract class AbstractLaunchStep
    extends java.lang.Object
    implements LaunchStep
    • Field Detail

      • changeSupport

        protected java.beans.PropertyChangeSupport changeSupport
    • Constructor Detail

      • AbstractLaunchStep

        public AbstractLaunchStep()
    • Method Detail

      • newConnection

        protected static java.net.HttpURLConnection newConnection​(java.lang.String url)
                                                           throws java.io.IOException,
                                                                  java.net.MalformedURLException,
                                                                  java.net.ProtocolException
        Throws:
        java.io.IOException
        java.net.MalformedURLException
        java.net.ProtocolException
      • newConnection

        protected static java.net.HttpURLConnection newConnection​(java.lang.String url,
                                                                  int readTimeout)
                                                           throws java.io.IOException,
                                                                  java.net.MalformedURLException,
                                                                  java.net.ProtocolException
        Throws:
        java.io.IOException
        java.net.MalformedURLException
        java.net.ProtocolException
      • getString

        protected abstract java.lang.String getString​(java.lang.String resourceKey)
        Abstraction to accommodate different methods of looking up bundle strings
      • log

        public abstract void log​(java.lang.String message,
                                 java.lang.Object... args)
        Abstraction to accommodate different logging methods
        Specified by:
        log in interface LaunchStep
      • getMessage

        public java.lang.String getMessage()
        Description copied from interface: LaunchStep
        When active, this message describes what the step is currently doing
        Specified by:
        getMessage in interface LaunchStep
      • getProgress

        public int getProgress()
        Description copied from interface: LaunchStep
        The current progress (when running), from 0 to 100
        Specified by:
        getProgress in interface LaunchStep
      • isIndeterminate

        public boolean isIndeterminate()
        Description copied from interface: LaunchStep
        If this step can currently not calculate its progress, it is considered indeterminate
        Specified by:
        isIndeterminate in interface LaunchStep
      • setMessagef

        public void setMessagef​(java.lang.String bundleKey,
                                java.lang.Object... formatArgs)
        Sets the message after passing the key through the bundle, and the result through String.format()
        Specified by:
        setMessagef in interface LaunchStep
      • setMessage

        public void setMessage​(java.lang.String message)
        Sets the message to this literal string
        Specified by:
        setMessage in interface LaunchStep
      • setProgress

        public void setProgress​(int progress)
        Specified by:
        setProgress in interface LaunchStep
      • setIndeterminate

        public void setIndeterminate​(boolean indeterminate)
        Specified by:
        setIndeterminate in interface LaunchStep
      • firePropertyChange

        protected void firePropertyChange​(java.lang.String propertyName,
                                          java.lang.Object oldValue,
                                          java.lang.Object newValue)
      • addPropertyChangeListener

        public void addPropertyChangeListener​(java.lang.String propertyName,
                                              java.beans.PropertyChangeListener listener)
        Specified by:
        addPropertyChangeListener in interface LaunchStep
      • addPropertyChangeListener

        public void addPropertyChangeListener​(java.beans.PropertyChangeListener listener)
        Specified by:
        addPropertyChangeListener in interface LaunchStep
      • removePropertyChangeListener

        public void removePropertyChangeListener​(java.beans.PropertyChangeListener listener)
        Specified by:
        removePropertyChangeListener in interface LaunchStep
      • removePropertyChangeListener

        public void removePropertyChangeListener​(java.lang.String propertyName,
                                                 java.beans.PropertyChangeListener listener)
        Specified by:
        removePropertyChangeListener in interface LaunchStep