Supporting classes

Vector vs ArrayList

When to prefer Vector vs ArrayList? By functionality, both are very similar. Both are derived from List interface. The most important difference is that Vector methods are synchronized where as ArrayList methods are not. In a multithreaded environment, when a number clients access same instance where data is very critical and important, it is advised …

Vector vs ArrayList Read More »

Java UnsupportedOperationException

Java UnsupportedOperationException Summary: Java UnsupportedOperationException explained in simple words for a beginner. Possibility of throwing is illustrated. UnsupportedOperationException is thrown by the JVM at runtime. It is called when the method called is not supported by a data structure. java.lang.UnsupportedOperationException is paced in collections framework. Following is the class signature public class UnsupportedOperationException extends RuntimeException …

Java UnsupportedOperationException Read More »