Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Business Components
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## oracle.jbo.domain
Interface KeyAttributeInterface

All Known Implementing Classes:
  Char, Number, Raw, RowID, Date

public interface KeyAttributeInterface

Implemented by domain classes, instances of which could be an attribute of a oracle.jbo.Key

This interface is used by Key serialization to come up with a string representation of the key that is of a reasonable length. By default the key uses java-serialization to convert an attribute value into bytearray. But that ends up creating a large string, which gets unmanageable when Web/HTML/JSP UIs have to display the key/use the key in URLs. The intent here is to get a shorter but meaningful String representation of this object.

Note that another requirement of this interface is that the domain class should have a public default constructor, so that the framework can call Class.newInstance() to create an instance of this domain class and set the byte array from a key into this instance using setBytes method.

Since:
  JDevloper 3.0
See Also:
  `Key`

Method Summary
`byte[]` | `getBytes()` Converts this attribute value into a byte-array.
`void` | `setBytes(byte[] bArr)` Passes in the bytes that represent the value of this object.

Method Detail

### getBytes

    public byte[] getBytes()

  Converts this attribute value into a byte-array. For domains that extend oracle.sql.* classes, this method is implemented by a baseclass. For others, this method needs to return a byte-array representation of the value held in the domain object.
  Returns:
    a byte array representing this object

### setBytes

    public void setBytes(byte[] bArr)

  Passes in the bytes that represent the value of this object. For domains that extedn oracle.sql.* classes, this method is implemented by a base-class.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Business Components
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD