Class ListPackages

  • All Implemented Interfaces:
    adams.core.Destroyable, adams.core.GlobalInfoSupporter, adams.core.logging.LoggingLevelHandler, adams.core.logging.LoggingSupporter, adams.core.option.OptionHandler, adams.core.QuickInfoSupporter, adams.core.SizeOfHandler, adams.flow.core.FlowContextHandler, Serializable

    public class ListPackages
    extends AbstractWekaPackageManagerAction
    Lists the packages.
    Author:
    fracpete (fracpete at waikato dot ac dot nz)
    See Also:
    Serialized Form
    • Constructor Detail

      • ListPackages

        public ListPackages()
    • Method Detail

      • globalInfo

        public String globalInfo()
        Returns a string describing the object.
        Specified by:
        globalInfo in interface adams.core.GlobalInfoSupporter
        Specified by:
        globalInfo in class adams.core.option.AbstractOptionHandler
        Returns:
        a description suitable for displaying in the gui
      • defineOptions

        public void defineOptions()
        Adds options to the internal list of options.
        Specified by:
        defineOptions in interface adams.core.option.OptionHandler
        Overrides:
        defineOptions in class adams.core.option.AbstractOptionHandler
      • setListType

        public void setListType​(ListPackages.ListType value)
        Sets the type of list to generate.
        Parameters:
        value - the type
      • getListType

        public ListPackages.ListType getListType()
        Returns the type of list to generate.
        Returns:
        the type
      • listTypeTipText

        public String listTypeTipText()
        Returns the tip text for this property.
        Returns:
        tip text for this property suitable for displaying in the GUI or for listing the options.
      • setOutputFormat

        public void setOutputFormat​(ListPackages.OutputFormat value)
        Sets the type of output format to generate.
        Parameters:
        value - the type
      • getOutputFormat

        public ListPackages.OutputFormat getOutputFormat()
        Returns the type of output format to generate.
        Returns:
        the type
      • outputFormatTipText

        public String outputFormatTipText()
        Returns the tip text for this property.
        Returns:
        tip text for this property suitable for displaying in the GUI or for listing the options.
      • getQuickInfo

        public String getQuickInfo()
        Returns a quick info about the actor, which will be displayed in the GUI.
        Specified by:
        getQuickInfo in interface adams.core.QuickInfoSupporter
        Overrides:
        getQuickInfo in class AbstractWekaPackageManagerAction
        Returns:
        null if no info available, otherwise short string
      • getPackages

        protected List<weka.core.packageManagement.Package> getPackages()
                                                                 throws Exception
        Returns the packages to output.
        Returns:
        the packages
        Throws:
        Exception - if retrieval of packages fails
      • doExecute

        public Object doExecute​(adams.core.MessageCollection errors)
        Executes the action.
        Specified by:
        doExecute in class AbstractWekaPackageManagerAction
        Parameters:
        errors - for collecting errors
        Returns:
        the generated output, null if failed to generated