X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Firc%2FConnection.java;h=0cbbae83826cc672295397a9d28c79915705e751;hb=64c32d0191b803facf4e867cb94d5eb6812ef1cb;hp=ac29809ba34af27ab440bd7feea70563462b8662;hpb=e3d5be1bb8fb742facae438ae2c36d55331e953e;p=xudocci.git diff --git a/src/main/java/net/pterodactylus/irc/Connection.java b/src/main/java/net/pterodactylus/irc/Connection.java index ac29809..0cbbae8 100644 --- a/src/main/java/net/pterodactylus/irc/Connection.java +++ b/src/main/java/net/pterodactylus/irc/Connection.java @@ -144,6 +144,22 @@ public class Connection extends AbstractExecutionThreadService implements Servic // /** + * Returns the hostname of the remote end of the connection. + * @return The remote’s hostname + */ + public String hostname() { + return hostname; + } + + /** + * Returns the port number of the remote end of the connection. + * @return The remote’s port number + */ + public int port() { + return port; + } + + /** * Returns whether this connection has already been established. * * @return {@code true} as long as this connection is established, {@code