public class BinaryRefAddr extends RefAddr
A BinaryRefAddr consists of a type that describes the communication mechanism and an opaque buffer containing the address description specific to that communication mechanism. The format and interpretation of the address type and the contents of the opaque buffer are based on the agreement of three parties: the client that uses the address, the object/server that can be reached using the address, and the administrator or program that creates the address.
An example of a binary reference address is an BER X.500 presentation address. Another example of a binary reference address is a serialized form of a service's object handle.
A binary reference address is immutable in the sense that its fields once created, cannot be replaced. However, it is possible to access the byte array used to hold the opaque buffer. Programs are strongly recommended against changing this byte array. Changes to this byte array need to be explicitly synchronized.
RefAddr
,
StringRefAddr
,
Serialized FormConstructor and Description |
---|
BinaryRefAddr(String addrType,
byte[] src)
Constructs a new instance of BinaryRefAddr using its address type and a byte
array for contents.
|
BinaryRefAddr(String addrType,
byte[] src,
int offset,
int count)
Constructs a new instance of BinaryRefAddr using its address type and
a region of a byte array for contents.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj)
Determines whether obj is equal to this address.
|
Object |
getContent()
Retrieves the contents of this address as an Object.
|
int |
hashCode()
Computes the hash code of this address using its address type and contents.
|
String |
toString()
Generates the string representation of this address.
|
public BinaryRefAddr(String addrType, byte[] src)
addrType
- A non-null string describing the type of the address.src
- The non-null contents of the address as a byte array.
The contents of src is copied into the new BinaryRefAddr.public BinaryRefAddr(String addrType, byte[] src, int offset, int count)
addrType
- A non-null string describing the type of the address.src
- The non-null contents of the address as a byte array.
The contents of src is copied into the new BinaryRefAddr.offset
- The starting index in src to get the bytes.
0 <= offset <= src.length.count
- The number of bytes to extract from src.
0 <= count <= src.length-offset.public Object getContent()
getContent
in class RefAddr
public boolean equals(Object obj)
equals
in class RefAddr
obj
- The possibly null object to check.RefAddr.getContent()
,
RefAddr.getType()
public int hashCode()
hashCode
in class RefAddr
Object.hashCode()
public String toString()
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2011, Oracle and/or its affiliates. All rights reserved.
DRAFT ea-b138