Overview | Package | Class | Tree | Deprecated | Index | Help
| OracleAS PDK for Java 9.0.4.0.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## oracle.portal.provider.v2.preference
Class NameValuePreferenceDataObject

    java.lang.Object
      |
      +--oracle.portal.provider.v2.preference.NameValuePreferenceDataObject

All Implemented Interfaces:
  PreferenceDataObject

Direct Known Subclasses:
  NameValuePersonalizationObject

public class NameValuePreferenceDataObject
extends java.lang.Object
implements PreferenceDataObject

Base preference data class. Uses proprietary data format rather than native Java serialization so that data classes may be extended and renamed without breaking their existing data.

Constructor Summary
`NameValuePreferenceDataObject()` Null Constructor.

Method Summary
`java.lang.Boolean` | `getBoolean(java.lang.String name)` Retrieves the Boolean value stored against the given name from the content of the `NameValuePreferenceDataObject`.
`java.lang.Boolean[]` | `getBooleanArray(java.lang.String name)` Retrieves the Boolean Array value stored against the given name from the content of the `NameValuePreferenceDataObject`.
`java.lang.String` | `getContentVersion()` Gets the version String associated with the content of the PreferenceDataObject
`java.lang.Double` | `getDouble(java.lang.String name)` Retrieves the Double value stored against the given name from the content of the `NameValuePreferenceDataObject`.
`java.lang.Double[]` | `getDoubleArray(java.lang.String name)` Retrieves the Double Array value stored against the given name from the content of the `NameValuePreferenceDataObject`.
`java.lang.Float` | `getFloat(java.lang.String name)` Retrieves the Float value stored against the given name from the content of the `NameValuePreferenceDataObject`.
`java.lang.Float[]` | `getFloatArray(java.lang.String name)` Retrieves the Float Array value stored against the given name from the content of the `NameValuePreferenceDataObject`.
`java.lang.Integer` | `getInteger(java.lang.String name)` Retrieves the Integer value stored against the given name from the content of the `NameValuePreferenceDataObject`.
`java.lang.Integer[]` | `getIntegerArray(java.lang.String name)` Retrieves the Integer Array value stored against the given name from the content of the `NameValuePreferenceDataObject`.
`java.lang.Long` | `getLong(java.lang.String name)` Retrieves the Long value stored against the given name from the content of the `NameValuePreferenceDataObject`.
`java.lang.Long[]` | `getLongArray(java.lang.String name)` Retrieves the Long Array value stored against the given name from the content of the `NameValuePreferenceDataObject`.
`java.util.Iterator` | `getNames()` Retrieves an Iterator object containing all names in the content of the `NameValuePreferenceDataObject`.
`java.lang.String` | `getString(java.lang.String name)` Retrieves the String value stored against the given name from the content of the `NameValuePreferenceDataObject`.
`java.lang.String[]` | `getStringArray(java.lang.String name)` Retrieves the String Array value stored against the given name from the content of the `NameValuePreferenceDataObject`.
`void` | `putBoolean(java.lang.String name, java.lang.Boolean value)` Records the given Boolean value against the given name in the `NameValuePreferenceDataObject` content.
`void` | `putBooleanArray(java.lang.String name, java.lang.Boolean[] value)` Records the given Boolean Array value against the given name in the `NameValuePreferenceDataObject` content.
`void` | `putDouble(java.lang.String name, java.lang.Double value)` Records the given Double value against the given name in the `NameValuePreferenceDataObject` content.
`void` | `putDoubleArray(java.lang.String name, java.lang.Double[] value)` Records the given Double Array value against the given name in the `NameValuePreferenceDataObject` content.
`void` | `putFloat(java.lang.String name, java.lang.Float value)` Records the given Float value against the given name in the `NameValuePreferenceDataObject` content.
`void` | `putFloatArray(java.lang.String name, java.lang.Float[] value)` Records the given Float Array value against the given name in the `NameValuePreferenceDataObject` content.
`void` | `putInteger(java.lang.String name, java.lang.Integer value)` Records the given Integer value against the given name in the `NameValuePreferenceDataObject` content.
`void` | `putIntegerArray(java.lang.String name, java.lang.Integer[] value)` Records the given Integer Array value against the given name in the `NameValuePreferenceDataObject` content.
`void` | `putLong(java.lang.String name, java.lang.Long value)` Records the given Long value against the given name in the `NameValuePreferenceDataObject` content.
`void` | `putLongArray(java.lang.String name, java.lang.Long[] value)` Records the given Long Array value against the given name in the `NameValuePreferenceDataObject` content.
`void` | `putString(java.lang.String name, java.lang.String value)` Records the given String value against the given name in the `NameValuePreferenceDataObject` content.
`void` | `putStringArray(java.lang.String name, java.lang.String[] value)` Records the given String Array value against the given name in the `NameValuePreferenceDataObject` content.
`void` | `read(java.io.InputStream is)` Populates the `PreferenceDataObject` with content read from a given InputStream
`void` | `remove(java.lang.String name)` Removes the value stored against the given name from the content of the `NameValuePreferenceDataObject`.
`void` | `setContentVersion(java.lang.String version)` Sets the version associated with the content of the `NameValuePreferenceDataObject`.
`void` | `write(java.io.OutputStream os)` Writes the content of the `PreferenceDataObject` to a given OutputStream

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### NameValuePreferenceDataObject

    public NameValuePreferenceDataObject()

  Null Constructor.

Method Detail

### setContentVersion

    public void setContentVersion(java.lang.String version)

  Sets the version associated with the content of the `NameValuePreferenceDataObject`. The version number is a String to allow you to define the structure of your version numbers.

  Specified by:
    `setContentVersion` in interface `PreferenceDataObject`
  Parameters:
    `version` - version string to be associated with the content of the `NameValuePreferenceDataObject`

### getContentVersion

    public java.lang.String getContentVersion()

  Description copied from interface: `PreferenceDataObject`
  Gets the version String associated with the content of the PreferenceDataObject

  Specified by:
    `getContentVersion` in interface `PreferenceDataObject`
  Returns:
    the version String associated with the content of the `NameValuePreferenceDataObject`

### putInteger

    public void putInteger(java.lang.String name,
                           java.lang.Integer value)

  Records the given Integer value against the given name in the `NameValuePreferenceDataObject` content. If the name already exists, then the value for that name will be overwritten with the new value given

  Parameters:
    `name` - String name against which the value is to be stored
    `value` - Integer value

### putDouble

    public void putDouble(java.lang.String name,
                          java.lang.Double value)

  Records the given Double value against the given name in the `NameValuePreferenceDataObject` content. If the name already exists, then the value for that name will be overwritten with the new value given

  Parameters:
    `name` - String name against which the value is to be stored
    `value` - Double value

### putFloat

    public void putFloat(java.lang.String name,
                         java.lang.Float value)

  Records the given Float value against the given name in the `NameValuePreferenceDataObject` content. If the name already exists, then the value for that name will be overwritten with the new value given

  Parameters:
    `name` - String name against which the value is to be stored
    `value` - Float value

### putLong

    public void putLong(java.lang.String name,
                        java.lang.Long value)

  Records the given Long value against the given name in the `NameValuePreferenceDataObject` content. If the name already exists, then the value for that name will be overwritten with the new value given

  Parameters:
    `name` - String name against which the value is to be stored
    `value` - Long value

### putBoolean

    public void putBoolean(java.lang.String name,
                           java.lang.Boolean value)

  Records the given Boolean value against the given name in the `NameValuePreferenceDataObject` content. If the name already exists, then the value for that name will be overwritten with the new value given

  Parameters:
    `name` - String name against which the value is to be stored
    `value` - Boolean value

### putString

    public void putString(java.lang.String name,
                          java.lang.String value)

  Records the given String value against the given name in the `NameValuePreferenceDataObject` content. If the name already exists, then the value for that name will be overwritten with the new value given

  Parameters:
    `name` - String name against which the value is to be stored
    `value` - String value

### putIntegerArray

    public void putIntegerArray(java.lang.String name,
                                java.lang.Integer[] value)

  Records the given Integer Array value against the given name in the `NameValuePreferenceDataObject` content. If the name already exists, then the value for that name will be overwritten with the new value given

  Parameters:
    `name` - String name against which the value is to be stored
    `value` - Integer array value

### putDoubleArray

    public void putDoubleArray(java.lang.String name,
                               java.lang.Double[] value)

  Records the given Double Array value against the given name in the `NameValuePreferenceDataObject` content. If the name already exists, then the value for that name will be overwritten with the new value given

  Parameters:
    `name` - String name against which the value is to be stored
    `value` - Double array value

### putFloatArray

    public void putFloatArray(java.lang.String name,
                              java.lang.Float[] value)

  Records the given Float Array value against the given name in the `NameValuePreferenceDataObject` content. If the name already exists, then the value for that name will be overwritten with the new value given

  Parameters:
    `name` - String name against which the value is to be stored
    `value` - Float array value

### putLongArray

    public void putLongArray(java.lang.String name,
                             java.lang.Long[] value)

  Records the given Long Array value against the given name in the `NameValuePreferenceDataObject` content. If the name already exists, then the value for that name will be overwritten with the new value given

  Parameters:
    `name` - String name against which the value is to be stored
    `value` - Long array value

### putBooleanArray

    public void putBooleanArray(java.lang.String name,
                                java.lang.Boolean[] value)

  Records the given Boolean Array value against the given name in the `NameValuePreferenceDataObject` content. If the name already exists, then the value for that name will be overwritten with the new value given

  Parameters:
    `name` - String name against which the value is to be stored
    `value` - Boolean array value

### putStringArray

    public void putStringArray(java.lang.String name,
                               java.lang.String[] value)

  Records the given String Array value against the given name in the `NameValuePreferenceDataObject` content. If the name already exists, then the value for that name will be overwritten with the new value given

  Parameters:
    `name` - String name against which the value is to be stored
    `value` - String array value

### getInteger

    public java.lang.Integer getInteger(java.lang.String name)

  Retrieves the Integer value stored against the given name from the content of the `NameValuePreferenceDataObject`.

  Parameters:
    `name` - String name against which the value is stored
  Returns:
    Integer value stored against the given name if one exists, or null otherwise
  Throws:
    `java.lang.ClassCastException` - if the value stored against the given name is not an Integer.

### getDouble

    public java.lang.Double getDouble(java.lang.String name)

  Retrieves the Double value stored against the given name from the content of the `NameValuePreferenceDataObject`.

  Parameters:
    `name` - String name against which the value is stored
  Returns:
    Double value stored against the given name if one exists, or null otherwise
  Throws:
    `java.lang.ClassCastException` - if the value stored against the given name is not a Double.

### getFloat

    public java.lang.Float getFloat(java.lang.String name)

  Retrieves the Float value stored against the given name from the content of the `NameValuePreferenceDataObject`.

  Parameters:
    `name` - String name against which the value is stored
  Returns:
    Float value stored against the given name if one exists, or null otherwise
  Throws:
    `java.lang.ClassCastException` - if the value stored against the given name is not a Float.

### getLong

    public java.lang.Long getLong(java.lang.String name)

  Retrieves the Long value stored against the given name from the content of the `NameValuePreferenceDataObject`.

  Parameters:
    `name` - String name against which the value is stored
  Returns:
    Long value stored against the given name if one exists, or null otherwise
  Throws:
    `java.lang.ClassCastException` - if the value stored against the given name is not a Long.

### getBoolean

    public java.lang.Boolean getBoolean(java.lang.String name)

  Retrieves the Boolean value stored against the given name from the content of the `NameValuePreferenceDataObject`.

  Parameters:
    `name` - String name against which the value is stored
  Returns:
    Boolean value stored against the given name if one exists, or null otherwise
  Throws:
    `java.lang.ClassCastException` - if the value stored against the given name is not a Boolean.

### getString

    public java.lang.String getString(java.lang.String name)

  Retrieves the String value stored against the given name from the content of the `NameValuePreferenceDataObject`.

  Parameters:
    `name` - String name against which the value is stored
  Returns:
    String value stored against the given name if one exists, or null otherwise
  Throws:
    `java.lang.ClassCastException` - if the value stored against the given name is not a String.

### getIntegerArray

    public java.lang.Integer[] getIntegerArray(java.lang.String name)

  Retrieves the Integer Array value stored against the given name from the content of the `NameValuePreferenceDataObject`.

  Parameters:
    `name` - String name against which the value is stored
  Returns:
    Integer Array value stored against the given name if one exists, or null otherwise
  Throws:
    `java.lang.ClassCastException` - if the value stored against the given name is not an Integer array.

### getDoubleArray

    public java.lang.Double[] getDoubleArray(java.lang.String name)

  Retrieves the Double Array value stored against the given name from the content of the `NameValuePreferenceDataObject`.

  Parameters:
    `name` - String name against which the value is stored
  Returns:
    Double Array value stored against the given name if one exists, or null otherwise
  Throws:
    `java.lang.ClassCastException` - if the value stored against the given name is not a Double array.

### getFloatArray

    public java.lang.Float[] getFloatArray(java.lang.String name)

  Retrieves the Float Array value stored against the given name from the content of the `NameValuePreferenceDataObject`.

  Parameters:
    `name` - String name against which the value is stored
  Returns:
    Float Array value stored against the given name if one exists, or null otherwise
  Throws:
    `java.lang.ClassCastException` - if the value stored against the given name is not a Float array.

### getLongArray

    public java.lang.Long[] getLongArray(java.lang.String name)

  Retrieves the Long Array value stored against the given name from the content of the `NameValuePreferenceDataObject`.

  Parameters:
    `name` - String name against which the value is stored
  Returns:
    Long Array value stored against the given name if one exists, or null otherwise
  Throws:
    `java.lang.ClassCastException` - if the value stored against the given name is not a Long array.

### getBooleanArray

    public java.lang.Boolean[] getBooleanArray(java.lang.String name)

  Retrieves the Boolean Array value stored against the given name from the content of the `NameValuePreferenceDataObject`.

  Parameters:
    `name` - String name against which the value is stored
  Returns:
    Boolean Array value stored against the given name if one exists, or null otherwise
  Throws:
    `java.lang.ClassCastException` - if the value stored against the given name is not a Boolean array.

### getStringArray

    public java.lang.String[] getStringArray(java.lang.String name)

  Retrieves the String Array value stored against the given name from the content of the `NameValuePreferenceDataObject`.

  Parameters:
    `name` - String name against which the value is stored
  Returns:
    String Array value stored against the given name if one exists, or null otherwise
  Throws:
    `java.lang.ClassCastException` - if the value stored against the given name is not a String array.

### getNames

    public java.util.Iterator getNames()

  Retrieves an Iterator object containing all names in the content of the `NameValuePreferenceDataObject`.

  Returns:
    Iterator object containing all names

### remove

    public void remove(java.lang.String name)

  Removes the value stored against the given name from the content of the `NameValuePreferenceDataObject`.

  Parameters:
    `name` - String name against which the value is stored

### write

    public void write(java.io.OutputStream os)
               throws java.io.IOException

  Writes the content of the `PreferenceDataObject` to a given OutputStream

  Specified by:
    `write` in interface `PreferenceDataObject`
  Parameters:
    `os` - OutputStream to which content should be written
    `java.io.IOException`

### read

    public void read(java.io.InputStream is)
              throws java.io.IOException

  Populates the `PreferenceDataObject` with content read from a given InputStream

  Specified by:
    `read` in interface `PreferenceDataObject`
  Parameters:
    `is` - InputStream from which content should be read
    `java.io.IOException`

Overview | Package | Class | Tree | Deprecated | Index | Help
| OracleAS PDK for Java 9.0.4.0.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright (c) 2002,2003 Oracle Corporation. All Rights Reserved.