ParamsHolder
org.encog.util

Class ParamsHolder



  • public class ParamsHolderextends Object
    A class that can be used to parse parameters stored in a map. Allows the params to be accessed as various data types and to be validated.
    • Constructor Detail

      • ParamsHolder

        public ParamsHolder(Map<String,String> theParams,            CSVFormat theFormat)
        Construct the object. Allow the format to be specified.
        Parameters:
        theParams - The params to be used.
        theFormat - The format to be used.
      • ParamsHolder

        public ParamsHolder(Map<String,String> theParams)
        Construct the object. Allow the format to be specified.
        Parameters:
        theParams - The params to be used.
    • Method Detail

      • getString

        public String getString(String name,               boolean required,               String defaultValue)
        Get a param as a string.
        Parameters:
        name - The name of the string.
        required - True if this value is required.
        defaultValue - The default value.
        Returns:
        The value.
      • getInt

        public int getInt(String name,         boolean required,         int defaultValue)
        Get a param as a integer.
        Parameters:
        name - The name of the integer.
        required - True if this value is required.
        defaultValue - The default value.
        Returns:
        The value.
      • getDouble

        public double getDouble(String name,               boolean required,               double defaultValue)
        Get a param as a double.
        Parameters:
        name - The name of the double.
        required - True if this value is required.
        defaultValue - The default value.
        Returns:
        The value.
      • getBoolean

        public boolean getBoolean(String name,                 boolean required,                 boolean defaultValue)
        Get a param as a boolean.
        Parameters:
        name - The name of the double.
        required - True if this value is required.
        defaultValue - The default value.
        Returns:
        The value.

SCaVis 2.0 © jWork.ORG