Class ParameterSweepParser

    • Constructor Detail

      • ParameterSweepParser

        public ParameterSweepParser​(URL paramsURL)
        Creates a ParameterSweepParser to parse the specified URL.
        Parameters:
        paramsURL -
      • ParameterSweepParser

        public ParameterSweepParser​(InputStream in)
      • ParameterSweepParser

        public ParameterSweepParser​(ParameterTreeSweeper sweeper,
                                    URL paramsURL)
        Creates a ParameterSweeper parser to use the specified sweeper and to parse the specified URL.
        Parameters:
        sweeper -
        paramsURL -
    • Method Detail

      • inputFile

        public void inputFile​(String input)
                       throws IOException
        Method writes out string content to a batch xml file used for temporary data storage.
        Parameters:
        input - the input string to write out
        Throws:
        IOException
      • readFile

        public String readFile​(URL url,
                               int size)
                        throws IOException
        Method reads file URL and size (based on content) and returns a string representation of that content.
        Parameters:
        url - the file url
        size - the size of the file
        Returns:
        a string representation of the parameters
        Throws:
        IOException
      • registerStepperCreator

        public void registerStepperCreator​(String typeID,
                                           ParameterSetterCreator creator)
        Register a setter creator to be used during sweeper creation. When a parameter element whose "type" attribute is equal to the specified typeID is encountered, the specified creator will be used to create the ParameterSetter. The attributes of that element will be passed to the creator so that it can create the setter.
        Parameters:
        typeID -
        creator -
      • registerConstantCreator

        public void registerConstantCreator​(String constantTypeID,
                                            ParameterSetterCreator creator)
        Register a setter creator to be used for constant setters during sweeper creation. When a parameter element whose "constant type" attribute is equal to the specified typeID is encountered, the specified creator will be used to create the ParameterSetter. The attributes of that element will be passed to the creator so that it can create the constant setter.
        Parameters:
        constantTypeID - matches agains the constant_type attribute.
        creator -
      • isDouble

        protected boolean isDouble​(String val)
      • isLong

        protected boolean isLong​(String val)
      • isFloat

        protected boolean isFloat​(String val)
      • isInt

        protected boolean isInt​(Double value)