Core Java
-
client server communication example
The Server.java import gnu.cajo.Cajo; // The cajo implementation of the Grail public class Server { public static class Test {…
Read More » -
Logging aspect example
Once upon time I was writing a plugin for a closed-source LMS J2EE application having such dependencies that it wasn’t…
Read More » -
JUnit Rules Example
The implementation of a Rule might look like this: import org.junit.rules.TestRule; import org.junit.runner.Description; import org.junit.runners.model.Statement; public class LoggingRule implements TestRule…
Read More » -
Create a simple BasicDataSource object
With this example we are going to demonstrate how to create a simple org.apache.commons.dbcp.BasicDataSource object, that is the basic implementation…
Read More » -
Delete File from FTP Server
This is an example of how to delete a File from an FTP Server. We are using the org.apache.commons.net.ftp.FTPClient Class that…
Read More » -
Get list of files from FTP Server
In this example we shall show you how to get a list of files from an FTP Server. We are using…
Read More » -
Establish connection with FTP Server
With this example we are going to demonstrate how to establish a connection with an FTP Server. We are using…
Read More » -
Download file from FTP Server
This is an example of how to download a File from an FTP Server, using the org.apache.commons.net.ftp.FTPClient Class, that encapsulates…
Read More » -
File Upload to FTP Server
In this example we shall show you how to upload a File to an FTP Server, using the org.apache.commons.net.ftp.FTPClient Class,…
Read More » -
Check if Days and Calendars match
With this example we are going to demonstrate how to check if Days and Calendars match. We are using the…
Read More »