public class SlaveAddress
extends java.lang.Object
Modifier and Type | Field | Description |
---|---|---|
static int |
DEFAULT_PORT_NO |
Used as the default port number if the port number
is not mentioned.
|
private java.net.InetAddress |
hostAddress |
Contains the IP Address of the slave to replicate to.
|
private int |
portNumber |
Contains the port number at which the slave is listening for
connections from the master.
|
Constructor | Description |
---|---|
SlaveAddress(java.lang.String hostName,
int portNumber) |
Constructor initializes the host name and the port number with
valid values.
|
Modifier and Type | Method | Description |
---|---|---|
java.net.InetAddress |
getHostAddress() |
Used to get the IP Address corresponding to the host name of the
slave.
|
int |
getPortNumber() |
Used to get the port number of the slave.
|
private final java.net.InetAddress hostAddress
private final int portNumber
public static final int DEFAULT_PORT_NO
public SlaveAddress(java.lang.String hostName, int portNumber) throws java.net.UnknownHostException
hostName
- a String
that contains the host name of
the slave.portNumber
- an int
that contains the port number
of the slave.java.net.UnknownHostException
- If an exception occurs while trying to
resolve the host name.public java.net.InetAddress getHostAddress()
public int getPortNumber()
Apache Derby V10.14 Internals - Copyright © 2004,2018 The Apache Software Foundation. All Rights Reserved.