Core Java
-
Convert between URL and URI
With this example we are going to demonstrate how to convert between a URL and a URI. Class URL represents…
Read More » -
Create Server Socket
This is an example of how to create a ServerSocket. A server socket waits for requests to come in over…
Read More » -
Write text to Socket
In this example we shall show you how to write text to a Socket. To write text to a Socket one…
Read More » -
Read text from Socket
With this example we are going to demonstrate how to read text from a Socket. A Socket is an endpoint…
Read More » -
Send HTTP POST request with Socket
This is an example of how to send an HTTP POST request with a Socket. A socket is an endpoint…
Read More » -
Create client Socket with timeout
In this example we shall show you how to create a client Socket with timeout. A client socket is an…
Read More » -
Create client Socket
With this example we are going to demonstrate how to create a client Socket in Java. In short, to create…
Read More » -
Get hostname from IP address
This is an example of how to get the host name of a remote host from its IP address. Doing…
Read More » -
Get IP address and hostname from local machine
In this example we shall show you how to retrieve the IP address and hostname from the local host. To…
Read More » -
Get IP address from hostname
In this example we shall show you how to retrieve the IP address from the hostname of a specific host.…
Read More »