public class HostPortCfg extends SelfDescribingMarshallable
The `HostPortCfg` class is designed to encapsulate the details of a network host's name and its associated port. By default, if the hostname is not provided, it defaults to "localhost".
EMPTYDISCARD| Constructor and Description |
|---|
HostPortCfg(String hostname,
int port)
Constructs a new configuration with the specified hostname and port.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object o) |
int |
hashCode() |
String |
hostname()
Retrieves the configured hostname.
|
int |
port()
Retrieves the configured port.
|
String |
toString() |
usesSelfDescribingMessageclone, finalize, getClass, notify, notifyAll, wait, wait, wait$equals, $fieldInfoMap, $fieldInfos, $hashCode, $toString, className, copyTo, deepCopy, fromFile, fromFile, fromString, fromString, fromString, getField, getLongField, mergeToMap, readMarshallable, reset, setField, setLongField, streamFromFile, streamFromFile, writeMarshallablebinaryLengthLength, writeValueunexpectedFieldpublic HostPortCfg(String hostname, int port)
hostname - The network host's name. If null, defaults to "localhost".port - The port associated with the hostname.public String hostname()
public int port()
Copyright © 2024. All rights reserved.