B4J Programming Press on the image to return to the main documentation page.

jSLPreferences

Written by Steve Laming

List of types:

SLPreferences

SLPreferences


Events:

None

Members:


  Clear

  Flush

  GetBoolean (key As String, def As Boolean) As Boolean

  GetByteArray (key As String, def() As Byte) As Byte()

  GetDouble (key As String, def As Double) As Double

  GetFloat (key As String, def As Float) As Float

  GetInt (key As String, def As Int) As Int

  GetKeys As String()

  GetLong (key As String, def As Long) As Long

  GetString (key As String, def As String) As String

  Initialize

  prefs As java.util.prefs.Preferences

  PutBoolean (key As String, value As Boolean)

  PutByteArray (key As String, value() As Byte)

  PutDouble (key As String, value As Double)

  PutFloat (key As String, value As Float)

  PutInt (key As String, value As Int)

  PutLong (key As String, value As Long)

  PutString (key As String, value As String)

  Remove (key As String)

Members description:

Clear
Removes all of the preferences (key-value associations) in this preference node.
Flush
Forces any changes in the contents of this preference node and its descendants to the persistent store.
GetBoolean (key As String, def As Boolean) As Boolean
Returns the boolean value represented by the string associated with the specified key in this preference node.
Returns def if key is not found
GetByteArray (key As String, def() As Byte) As Byte()
Returns the byte array value represented by the string associated with the specified key in this preference node.
Returns def if key is not found
GetDouble (key As String, def As Double) As Double
Returns the double value represented by the string associated with the specified key in this preference node.
Returns def if key is not found
GetFloat (key As String, def As Float) As Float
Returns the float value represented by the string associated with the specified key in this preference node.
Returns def if key is not found
GetInt (key As String, def As Int) As Int
Returns the int value represented by the string associated with the specified key in this preference node.
Returns def if key is not found
GetKeys As String()
Returns all of the keys that have an associated value in this preference node.
GetLong (key As String, def As Long) As Long
Returns the long value represented by the string associated with the specified key in this preference node.
Returns def if key is not found
GetString (key As String, def As String) As String
Returns the String value associated with the specified key in this preference node.
Returns def if key is not found
Initialize
Initialize preferences
prefs As java.util.prefs.Preferences
PutBoolean (key As String, value As Boolean)
Associates a string representing the specified boolean value with the specified key in this preference node.
PutByteArray (key As String, value() As Byte)
Associates a string representing the specified byte array with the specified key in this preference node.
PutDouble (key As String, value As Double)
Associates a string representing the specified double value with the specified key in this preference node.
PutFloat (key As String, value As Float)
Associates a string representing the specified float value with the specified key in this preference node.
PutInt (key As String, value As Int)
Associates a string representing the specified int value with the specified key in this preference node.
PutLong (key As String, value As Long)
Associates a string representing the specified long value with the specified key in this preference node.
PutString (key As String, value As String)
Associates the specified String value with the specified key in this preference node.
Remove (key As String)
Removes the value associated with the specified key in this preference node, if any.
Top