Package play.utils

Class Properties

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable, java.util.Map<java.lang.String,​java.lang.String>

    public class Properties
    extends java.util.HashMap<java.lang.String,​java.lang.String>
    like Properties, but with: encoding generic type helper
    See Also:
    Serialized Form
    • Nested Class Summary

      • Nested classes/interfaces inherited from class java.util.AbstractMap

        java.util.AbstractMap.SimpleEntry<K extends java.lang.Object,​V extends java.lang.Object>, java.util.AbstractMap.SimpleImmutableEntry<K extends java.lang.Object,​V extends java.lang.Object>
      • Nested classes/interfaces inherited from interface java.util.Map

        java.util.Map.Entry<K extends java.lang.Object,​V extends java.lang.Object>
    • Constructor Summary

      Constructors 
      Constructor Description
      Properties()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String get​(java.lang.String key, java.lang.String defaultValue)  
      double getDouble​(java.lang.String key)  
      double getDouble​(java.lang.String key, long defaultValue)  
      int getInt​(java.lang.String key)  
      int getInt​(java.lang.String key, int defaultValue)  
      void load​(java.io.InputStream is)  
      void load​(java.io.InputStream is, java.lang.String encoding)  
      void setDouble​(java.lang.String key, double val)  
      void setInt​(java.lang.String key, int val)  
      void setLong​(java.lang.String key, long val)  
      void store​(java.io.OutputStream out)  
      void store​(java.io.OutputStream out, java.lang.String encoding)  
      • Methods inherited from class java.util.HashMap

        clear, clone, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, forEach, get, getOrDefault, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values
      • Methods inherited from class java.util.AbstractMap

        equals, hashCode, toString
      • Methods inherited from class java.lang.Object

        finalize, getClass, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.util.Map

        equals, hashCode
    • Constructor Detail

      • Properties

        public Properties()
    • Method Detail

      • load

        public void load​(java.io.InputStream is)
                  throws java.io.IOException
        Throws:
        java.io.IOException
      • load

        public void load​(java.io.InputStream is,
                         java.lang.String encoding)
                  throws java.io.IOException
        Throws:
        java.io.IOException
      • get

        public java.lang.String get​(java.lang.String key,
                                    java.lang.String defaultValue)
      • store

        public void store​(java.io.OutputStream out)
                   throws java.io.IOException
        Throws:
        java.io.IOException
      • store

        public void store​(java.io.OutputStream out,
                          java.lang.String encoding)
                   throws java.io.IOException
        Throws:
        java.io.IOException
      • getDouble

        public double getDouble​(java.lang.String key)
                         throws java.lang.IllegalArgumentException
        Throws:
        java.lang.IllegalArgumentException
      • getDouble

        public double getDouble​(java.lang.String key,
                                long defaultValue)
                         throws java.lang.IllegalArgumentException
        Throws:
        java.lang.IllegalArgumentException
      • setDouble

        public void setDouble​(java.lang.String key,
                              double val)
      • getInt

        public int getInt​(java.lang.String key)
                   throws java.lang.IllegalArgumentException
        Throws:
        java.lang.IllegalArgumentException
      • getInt

        public int getInt​(java.lang.String key,
                          int defaultValue)
                   throws java.lang.IllegalArgumentException
        Throws:
        java.lang.IllegalArgumentException
      • setInt

        public void setInt​(java.lang.String key,
                           int val)
      • setLong

        public void setLong​(java.lang.String key,
                            long val)