public enum TcpUtil extends Enum<TcpUtil>
| Modifier and Type | Method and Description |
|---|---|
static ByteBuffer |
createBuffer(int minSize,
ByteOrder byteOrder) |
static void |
readAvailable(SocketChannel socket,
ByteBuffer bb) |
static void |
readFullyOrEOF(SocketChannel socket,
ByteBuffer bb) |
static TcpUtil |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static TcpUtil[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
static void |
writeAll(SocketChannel sc,
ByteBuffer bb) |
static void |
writeAllOrEOF(SocketChannel sc,
ByteBuffer bb) |
public static TcpUtil[] values()
for (TcpUtil c : TcpUtil.values()) System.out.println(c);
public static TcpUtil valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant
with the specified nameNullPointerException - if the argument is nullpublic static ByteBuffer createBuffer(int minSize, ByteOrder byteOrder)
public static void writeAllOrEOF(@NotNull
SocketChannel sc,
@NotNull
ByteBuffer bb)
throws IOException
IOExceptionpublic static void writeAll(@NotNull
SocketChannel sc,
@NotNull
ByteBuffer bb)
throws IOException
IOExceptionpublic static void readFullyOrEOF(@NotNull
SocketChannel socket,
@NotNull
ByteBuffer bb)
throws IOException
IOExceptionpublic static void readAvailable(@NotNull
SocketChannel socket,
@NotNull
ByteBuffer bb)
throws IOException
IOExceptionCopyright © 2014. All Rights Reserved.