Top 10 Java Features (or What Makes Java Great)May 3rd, 2006 Here is a list of top 10 java features I constantly use and highly recommend; features which makes Java great as a language and platform. JSP & Servlets - Most of java development today is arguably done on JSP & Servlets.
Python: A recipe for cryptic code?April 13th, 2005 I have heard that Python is a great programming language which is so much superior to everything around etc. The following code in python is touted as the world's smallest p2p client & server.
How to run javac 1.5 (or beyond) compiler for JSP compilation in Tomcat 5.5 with generics enabled (and other Java 1.5 only features like autoboxing)February 3rd, 2005 Target Audience
Java/JSP developers on Tomcat and Application Server administrators. Problem
Tomcat 5.5 (unlike Tomcat 5.0 and versions below) comes with Eclipse JDT compiler enabled by default for JSP compilation.
Fibonacci Series in 1-Line PHP / Java SoftwareOctober 22nd, 2005 No, I am not competing for obfuscated code context. I realized while showing it to someone that Fibonacci series can be written much more succintly using modern programming languages like c, java or php.
GCJ is Dangerously BuggyJune 13th, 2007 GCJ 1.4.2 which was forcefully bundled with Fedora Core 6 (and has been updated from their repository to the latest available version) must not be used with any enterprise product, nay for any Java project at all. I know it is being used in OpenOffice, which I think is a serious mistake.
JDK1.5 - Painful bugs: SolvedAugust 29th, 2004 Defects in early release of jdk.5 which have been solved.
Java Software: 1-Line Sort & Uniq UtilityOctober 18th, 2005 I had to sort and uniq (create a unique set of strings) a large list with lots of duplicate. My options were to write it in Java or download cygwin and run: cat file | sort | uniq > result
Cygwin download never works for me.
How To Install JDK 6 / Java SE 6 (+ Tomcat) in Fedora Core 6 / Fedora 7 in 5 MinutesAugust 7th, 2007 Fedora Core developers make it rather hard to install and properly configure Sun's JVM. All said and done Sun's JVM (comes with JDK) is the best JVM implementation out there; not to mention that it is the reference implementation.
Program (Source Code) to Trim Whitespaces from Files...April 20th, 2008 PHP is not only a very competent web development language (and part of LAMP stack). It is also a very capable language for writing (command line) scripts.
Introduction To Ruby For Java DevelopersJune 30th, 2006 Most Java programmers attempt to use Ruby like they use Java, similar to the mistakes C/C++ programmers commit when transitioning to Java. However Ruby provides a cleaner programming paradigm which if embibed can be effectively used to solve your problems.
How To Connect To CVS Via Proxy ServerFebruary 10th, 2007 CVS is commonly used by open source project to provide access to their source code. Here is a simple way how you can connect to CVS server from behind a proxy server.
Core Java: How To Get Java Source Code Line Number & File Name in CodeSeptember 8th, 2008 While debugging code Java programmers often use System.out.println(). It is important to write separate message in each System.out.println() so you can understand from the output where the problem lies.
Code: FIFO List in JavaFebruary 25th, 2006 One of the common questions I hear from Java newcomers is - where is a FIFO list in Java?
Java does have a FIFO list capability built-in with LinkedList and ArrayList, but they are not well advertized. A FIFO interface should at least have:
public interface FIFO {
/** Add an object to the end of the FIFO queue */
boolean add(Object o);
/** Remove an object from the front of the FIFO queue */
Object remove();
/** Return the number of elements in the FIFO queue */
int size();
}
A FIFOList class implementing the above would simply be:
public class FIFOList extends LinkedList implements FIFO {
public Object remove() {
return remove(0);
}
}
I prefer this setup instead of using a LinkedList.remove(0) directly.
JInvite - Java Invitation APIApril 10th, 2008 JInvite is a simple Java API which makes it easy to add invite capabilities to Java - the ability for existing members of your web service to invite other members. This capability was in the early days of GMail and now widely adopted by Web 2.0 (beta) sites for limiting site load and gradually increasing capacities.
Access Microsoft Access Database From Java Using JDBC-ODBC Bridge - Sample Code March 28th, 2006 Previously I had provided the gist of how to access MS Access database from JDBC using JDBC-ODBC bridge. Today I will elaborate on that and provide you with two sample classes.