public abstract class ManagementProtocolHeader extends Object
Modifier | Constructor and Description |
---|---|
protected |
ManagementProtocolHeader(int version)
Construct an instance with the protocol version for the header.
|
Modifier and Type | Method and Description |
---|---|
protected <T extends ManagementProtocolHeader> |
cast(Class<T> expected) |
abstract byte |
getType()
The type
|
int |
getVersion()
The protocol version for the current communication.
|
static ManagementProtocolHeader |
parse(DataInput input)
Parses the input stream to read the header
|
protected static void |
validateSignature(DataInput input)
Validate the header signature.
|
void |
write(DataOutput output)
Write the header information to the provided
DataOutput . |
protected ManagementProtocolHeader(int version)
version
- The protocol versionpublic void write(DataOutput output) throws IOException
DataOutput
.output
- The output to write toIOException
- If any problems occur writing to the outputpublic int getVersion()
public abstract byte getType()
protected static void validateSignature(DataInput input) throws IOException
input
- The input to read the signature fromIOException
- If any read problems occurprotected <T extends ManagementProtocolHeader> T cast(Class<T> expected)
public static ManagementProtocolHeader parse(DataInput input) throws IOException
input
- data input to read fromIOException
Copyright © 2023 JBoss by Red Hat. All rights reserved.