com.sun.jini.discovery
Class MulticastMaxPacketSize
java.lang.Object
com.sun.jini.discovery.MulticastMaxPacketSize
- All Implemented Interfaces:
- Serializable, InvocationConstraint
public final class MulticastMaxPacketSize
- extends Object
- implements InvocationConstraint, Serializable
Represents a constraint on the size (in bytes) of multicast packets used in
the multicast request and multicast announcement discovery protocols.
Lookup services and discovery clients can use this constraint to limit the
size of multicast request and announcement packets sent, so as to avoid
fragmentation or loss when the packets traverse routers. This constraint
can also be used to control the size of the buffers used to receive incoming
multicast request and announcement packets.
- Since:
- 2.0
- Author:
- Sun Microsystems, Inc.
- See Also:
- Serialized Form
Field Summary |
static int |
MIN_MAX_PACKET_SIZE
The minimum allowable multicast packet size limit. |
Constructor Summary |
MulticastMaxPacketSize(int size)
Creates a MulticastMaxPacketSize constraint for the given
multicast packet size limit. |
MIN_MAX_PACKET_SIZE
public static final int MIN_MAX_PACKET_SIZE
- The minimum allowable multicast packet size limit.
- See Also:
- Constant Field Values
MulticastMaxPacketSize
public MulticastMaxPacketSize(int size)
- Creates a
MulticastMaxPacketSize
constraint for the given
multicast packet size limit.
- Parameters:
size
- the multicast packet size limit
- Throws:
IllegalArgumentException
- if the given size is less than
MIN_MAX_PACKET_SIZE
.
getSize
public int getSize()
- Returns the multicast packet size limit.
- Returns:
- the multicast packet size limit
hashCode
public int hashCode()
- Overrides:
hashCode
in class Object
equals
public boolean equals(Object obj)
- Overrides:
equals
in class Object
toString
public String toString()
- Overrides:
toString
in class Object
Copyright © GigaSpaces.