Eclipse template

Eclipse Util Method Templates
This template is used to create Util method automatically in eclipse java editor, and use can use in your super class.

Download template here

How to import to Eclipse
1. Select Preference -> Java -> Editor -> Templates
2. Select Import -> select downloaded xml file.

01. java_convertInt - Get integer value from String
02. java_convertingStringToHex - Convert string value to hex
03. java_creatingFile - Creating new file with directory structure
04. java_daoFactory - Create the DB connection using datasource
05. java_dateComparision - This method used to compare two dates and return integer value
06. java_dbConnection - Creating DB connection
07. java_formatDate - Format date from 2011-10-10 17:00:00 to 10/10/11 5:00:00 PM
08. java_getDay - Get day of the week using date
09. java_getDbInformation - Get database information using DB connection
10. java_imageEncodeDecode - Image encoding/decoding using base64
11. java_isNull - Check selected string is not equal to null
12. java_isNullorEmpty - Check the string value null or empty
13. java_isValidEmail - Check email address is valid or not
14. java_isValidExtension - Check valid extension file using filename
15. java_isValidPassword - Check valid password
16. java_mailNotification - Method to send mail from <address>
17. java_readContentFromExcel - Read content from Excel file
18. java_readFileContent - Content read from file
19. java_readProperty - This method used to load and read the key value from properties
20. java_removeDuplicateFromList - Remove duplicate values from list
21. java_resultSet - Creating resultsets for Query
22. java_rssReader - Read the rss value from rss xml, and also we can use URL
23. java_searchAllFiles - This method is display files using directory input and extension
24. java_servletProtoType - Create servlet doGet and doPost methods
25. java_sortingArray - Sorting the array and reverse order
26. java_writeContentToExcel - Create a new excel file and write to content
27. java_XMLxPathReader - Read the node value using xPath expression
28. java_zipEntries - Read all the file name, size from zip file

How to import template in Eclipse
1. Create java class
2. type "java_zip" ctrl + space, then select method. It will automatically add the below code to your class with imports.
3. You have to download jar and set path manually to remove compilation error.

Sample Output

import java.util.regex.Matcher;
import java.util.regex.Pattern;

* This method show all entries of zip file
public static void doEntry(String inputFile) throws IOException {
FileInputStream fileStream = new FileInputStream(inputFile);
ZipInputStream zipStream = new ZipInputStream(fileStream);
ZipEntry zipEntry;
while ((zipEntry = zipStream.getNextEntry()) != null) {