Overview | Package | Class | Tree | Deprecated | Index | Help
| BEA Systems, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.compoze.collab
Class FetchProfile

    java.lang.Object
      |
      +--com.compoze.collab.FetchProfile

All Implemented Interfaces:
  com.compoze.collab.util.IDigestSupport, java.io.Serializable

public class FetchProfile
extends java.lang.Object
implements java.io.Serializable, com.compoze.collab.util.IDigestSupport

This class holds a list of keys to be retrieved from the server. `FetchProfile`s can be used to bring back only those properties on an item that you need, which will increase the performance of your application.

See Also:
  Serialized Form

Field Summary
`static FetchProfile` | `ALL` Represents a `FetchProfile` that includes only the keys specified by a `TYPE_ALL` `FetchProfile`.
`static FetchProfile` | `CONTAINER_DEFAULT` Represents a `FetchProfile` that includes only the keys specified by a `TYPE_CONTAINER_DEFAULT` `FetchProfile`.
`static FetchProfile` | `DEFAULT` Represents a `FetchProfile` that includes only the keys specified by a `TYPE_DEFAULT` `FetchProfile`.
`static FetchProfile` | `MINIMUM` Represents a `FetchProfile` that includes only the keys specified by a `TYPE_MINIMUM` `FetchProfile`.
`static int` | `TYPE_ALL` Represents a `FetchProfile` type that includes all keys for an `Item` (as defined by the provider).
`static int` | `TYPE_CONTAINER_DEFAULT` Represents a `FetchProfile` type that includes all default keys for the default `ItemClass` defined for the `Container` in which the query occurs.
`static int` | `TYPE_DEFAULT` Represents a `FetchProfile` type that includes the default keys for each `Item` based on its `ItemClass`.
`static int` | `TYPE_MINIMUM` Represents a `FetchProfile` type that includes the minimum keys for the `Item`.

Constructor Summary
`FetchProfile()` Constructor (no initial keys).
`FetchProfile(Key[] keys)` Constructor.
`FetchProfile(Key[] keys, int iType)` Constructor.

Method Summary
`void` | `addKey(Key key)` Adds a key to the profile.
`void` | `addKeys(Key[] keys)` Adds keys to the profile.
`boolean` | `contains(Key key)` Determines if the profile contains the specified key.
`boolean` | `equals(java.lang.Object obj)`
`Key[]` | `getKeys()` Gets all of the keys in the profile.
`int` | `getType()` Gets the `FetchProfile` type which defines what if any standard keys are to be retrieved in addition to the specified keys.
`int` | `hashCode()`
`int` | `size()` Gets the number of keys specified in the `FetchProfile` (does not include the keys specified by the `TYPE_` constants).
`java.lang.String` | `toString()` Returns a string representation of the object.
`void` | `updateDigest(java.security.MessageDigest digest)`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Field Detail

### TYPE_ALL

    public static final int TYPE_ALL

  Represents a `FetchProfile` type that includes all keys for an `Item` (as defined by the provider).

### TYPE_DEFAULT

    public static final int TYPE_DEFAULT

  Represents a `FetchProfile` type that includes the default keys for each `Item` based on its `ItemClass`. Note that, depending on the provider implementation using this `FetchProfile` may require two queries, one to retrieve the `ItemClass`es so that the default properties are known and one to actually retrieve the `Item`s.

### TYPE_MINIMUM

    public static final int TYPE_MINIMUM

  Represents a `FetchProfile` type that includes the minimum keys for the `Item`.

### TYPE_CONTAINER_DEFAULT

    public static final int TYPE_CONTAINER_DEFAULT

  Represents a `FetchProfile` type that includes all default keys for the default `ItemClass` defined for the `Container` in which the query occurs.

### ALL

    public static final FetchProfile ALL

  Represents a `FetchProfile` that includes only the keys specified by a `TYPE_ALL` `FetchProfile`. No keys may be added to this fixed `FetchProfile`.

### DEFAULT

    public static final FetchProfile DEFAULT

  Represents a `FetchProfile` that includes only the keys specified by a `TYPE_DEFAULT` `FetchProfile`. No keys may be added to this fixed `FetchProfile`.

### MINIMUM

    public static final FetchProfile MINIMUM

  Represents a `FetchProfile` that includes only the keys specified by a `TYPE_MINIMUM` `FetchProfile`. No keys may be added to this fixed `FetchProfile`.

### CONTAINER_DEFAULT

    public static final FetchProfile CONTAINER_DEFAULT

  Represents a `FetchProfile` that includes only the keys specified by a `TYPE_CONTAINER_DEFAULT` `FetchProfile`. No keys may be added to this fixed `FetchProfile`.

Constructor Detail

### FetchProfile

    public FetchProfile()

  Constructor (no initial keys).

### FetchProfile

    public FetchProfile(Key[] keys)

  Constructor.
  Parameters:
    `keys` - the keys for the profile

### FetchProfile

    public FetchProfile(Key[] keys,
                        int iType)

  Constructor.

Method Detail

### addKey

    public void addKey(Key key)

  Adds a key to the profile.
  Parameters:
    `key` - the key to add (not `null`)
  Throws:
    `CollaborationRuntimeException` - when the `FetchProfile` is one of the fixed profiles specified in the members of this class

### addKeys

    public void addKeys(Key[] keys)

  Adds keys to the profile.
  Parameters:
    `keys` - the keys to add (not `null`)

### contains

    public boolean contains(Key key)

  Determines if the profile contains the specified key.
  Parameters:
    `key` - the key to check (not `null`)
  Returns:
    `true` if the profile contains the specified key

### getKeys

    public Key[] getKeys()

  Gets all of the keys in the profile.
  Returns:
    a copy of all of the keys in the profile (not `null`)

### size

    public int size()

  Gets the number of keys specified in the `FetchProfile` (does not include the keys specified by the `TYPE_` constants).
  Returns:
    the size (0 if there are no keys specified)

### getType

    public int getType()

  Gets the `FetchProfile` type which defines what if any standard keys are to be retrieved in addition to the specified keys.
  Returns:
    the type (one of the `TYPE_` constants)

### equals

    public boolean equals(java.lang.Object obj)

  Overrides:
    `equals` in class `java.lang.Object`
  See Also:
    `Object.equals(java.lang.Object)`

### hashCode

    public int hashCode()

  Overrides:
    `hashCode` in class `java.lang.Object`
  See Also:
    `Object.hashCode()`

### toString

    public java.lang.String toString()

  Returns a string representation of the object.
  Overrides:
    `toString` in class `java.lang.Object`

### updateDigest

    public void updateDigest(java.security.MessageDigest digest)

  Specified by:
    `updateDigest` in interface `com.compoze.collab.util.IDigestSupport`

Overview | Package | Class | Tree | Deprecated | Index | Help
| BEA Systems, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright ©1999-2005 BEA Systems, Inc. All rights reserved.