Beispiel #1
0
        /// <summary>
        /// Retrieves a list of long values from the specified path in the configuration.
        /// </summary>
        /// <param name="path">The path that contains the values to retrieve.</param>
        /// <returns>The list of long values defined in the specified path.</returns>
        public virtual IList <long> GetLongList(string path)
        {
            HoconValue value = GetNode(path);

            return(value.GetLongList());
        }
Beispiel #2
0
        /// <summary>
        /// Retrieves a list of byte values from the specified path in the configuration.
        /// </summary>
        /// <param name="path">The path that contains the values to retrieve.</param>
        /// <returns>The list of byte values defined in the specified path.</returns>
        public virtual IList <byte> GetByteList(string path)
        {
            HoconValue value = GetNode(path);

            return(value.GetByteList());
        }
Beispiel #3
0
 public Pair(Path path, HoconValue value)
 {
     Path = path;
     Value = value;
 }
Beispiel #4
0
        public IList <int> GetIntList(string path)
        {
            HoconValue value = GetNode(path);

            return(value.GetIntList());
        }
Beispiel #5
0
        /// <summary>
        /// Retrieves a list of float values from the specified path in the configuration.
        /// </summary>
        /// <param name="path">The path that contains the values to retrieve.</param>
        /// <returns>The list of float values defined in the specified path.</returns>
        public virtual IList <float> GetFloatList(string path)
        {
            HoconValue value = GetNode(path);

            return(value.GetFloatList());
        }
Beispiel #6
0
 public Config(Config source, Config fallback)
 {
     _node          = source._node;
     this._fallback = fallback;
 }
 public static object ParseIntList(HoconValue e)
 {
     return(e.GetIntList());
 }
Beispiel #8
0
        /// <summary>
        /// Retrieves a list of boolean values from the specified path in the configuration.
        /// </summary>
        /// <param name="path">The path that contains the values to retrieve.</param>
        /// <returns>The list of boolean values defined in the specified path.</returns>
        public virtual IList <Boolean> GetBooleanList(string path)
        {
            HoconValue value = GetNode(path);

            return(value.GetBooleanList());
        }
 public static object ParseByteList(HoconValue e)
 {
     return(e.GetByteList());
 }
 public static object ParseShortList(HoconValue e)
 {
     return(e.GetArray().ConvertAll((HoconValue val) => (short)val.GetInt()));
 }
 public static object ParseBoolList(HoconValue e)
 {
     return(e.GetBooleanList());
 }
 public static object ParseShort(HoconValue e)
 {
     return((short)e.GetInt());
 }
Beispiel #13
0
 public Pair(Path path, HoconValue value)
 {
     Path  = path;
     Value = value;
 }
Beispiel #14
0
        /// <summary>
        /// Retrieves a <see cref="HoconValue"/> from a specific path.
        /// </summary>
        /// <param name="path">The path that contains the value to retrieve.</param>
        /// <returns>The <see cref="HoconValue"/> found at the location if one exists, otherwise <c>null</c>.</returns>
        public HoconValue GetValue(string path)
        {
            HoconValue value = GetNode(path);

            return(value);
        }
 public static object ParseLongList(HoconValue e)
 {
     return(e.GetLongList());
 }
Beispiel #16
0
        /// <summary>
        /// Determine if a HOCON configuration element exists at the specified location
        /// </summary>
        /// <param name="path">The location to check for a configuration value.</param>
        /// <returns><c>true</c> if a value was found, <c>false</c> otherwise.</returns>
        public virtual bool HasPath(string path)
        {
            HoconValue value = GetNode(path);

            return(value != null);
        }
 public static object ParseFloatList(HoconValue e)
 {
     return(e.GetFloatList());
 }
Beispiel #18
0
        /// <summary>
        /// Retrieves a list of decimal values from the specified path in the configuration.
        /// </summary>
        /// <param name="path">The path that contains the values to retrieve.</param>
        /// <returns>The list of decimal values defined in the specified path.</returns>
        public virtual IList <decimal> GetDecimalList(string path)
        {
            HoconValue value = GetNode(path);

            return(value.GetDecimalList());
        }
 public static object ParseDoubleList(HoconValue e)
 {
     return(e.GetDoubleList());
 }
Beispiel #20
0
        /// <summary>
        /// Retrieves a list of double values from the specified path in the configuration.
        /// </summary>
        /// <param name="path">The path that contains the values to retrieve.</param>
        /// <returns>The list of double values defined in the specified path.</returns>
        public virtual IList <double> GetDoubleList(string path)
        {
            HoconValue value = GetNode(path);

            return(value.GetDoubleList());
        }
Beispiel #21
0
 public Config(HoconValue node)
 {
     this._node = node;
 }