JavaBeat

  • Home
  • Java
    • Java 7
    • Java 8
    • Java EE
    • Servlets
  • Spring Framework
    • Spring Tutorials
    • Spring 4 Tutorials
    • Spring Boot
  • JSF Tutorials
  • Most Popular
    • Binary Search Tree Traversal
    • Spring Batch Tutorial
    • AngularJS + Spring MVC
    • Spring Data JPA Tutorial
    • Packaging and Deploying Node.js
  • About Us
    • Join Us (JBC)
  • Privacy

ClassLoader in Java

September 24, 2013 by Manisha Patil Leave a Comment

In this article we will understand the basics of Classloader in Java. Let us first understand what is the meaning of classloader. What is the ClassLoader ? As its name implies, ClassLoader is a class that loads other classes. More scientific: The Classloader loads the bytecodes in its class to memory, so it can be […]

Filed Under: Java Tagged With: Java

Working with java.util.zip compression API

July 24, 2013 by Manisha Patil Leave a Comment

In this article I shall discuss about how to compress files using Java. Java has a package of classes that allow data compression.Let’s see how easy it is to compress all files in a folder.The first step is to import the classes that we will use: Working with java.util.zip files Package java.io classes will be […]

Filed Under: Java Tagged With: Java

Example for a class implementing comparable interface in Java

February 21, 2013 by Krishna Srinivasan Leave a Comment

When you need some sort of ordering for the classes which you define, you will be going either for a comparable or comparator interface. Consider this example package test; import java.util.*; public class TreeSetTest { private static Set<Person> s = new TreeSet<Person>(); public static void main(String a[]){ s.add(new Person(20)); s.add(new Person(30)); s.add(new Person(10)); s.add(new Person(50)); […]

Filed Under: Java Tagged With: Java

What is super and this keyword in java?

February 21, 2013 by Krishna Srinivasan Leave a Comment

keyword : this ‘this’ is used for pointing the current class instance. It can be used with variables or methods. Look into the following example: class Test{ private int i=10; public void m(){ System.out.println(this.i); } } In the above code this is used for the current instance. Since this is instance of a class it […]

Filed Under: Java Tagged With: Java

How to use BitWise shift operator in Java?

February 21, 2013 by Krishna Srinivasan Leave a Comment

They are called shift operators and they operate by shifting the number of bits being specified as an operand in the operation. >> —> Right shift Operator << —> Left Shift Operator >>> —-> Right bit with zero fill operator. The first two maintain the MSB when shifting thereby they maintain the sign of the […]

Filed Under: Java Tagged With: Java

What is difference between equals() and == ?

February 21, 2013 by Krishna Srinivasan Leave a Comment

Explanation : 1 They both differ very much in their significance. equals() method is present in the java.lang.Object class and it is expected to check for the equivalence of the state of objects! That means, the contents of the objects. Whereas the ‘==’ operator is expected to check the actual object instances are same or […]

Filed Under: Java Tagged With: Java

Difference Between List and ArrayList ?

February 21, 2013 by Krishna Srinivasan Leave a Comment

List is an interface and ArrayList is an implementation of the List interface. The arraylist class has only a few methods in addition to the methods available in the List interface. There is not much difference in this. The only difference is, you are creating a reference of the parent interface in the first one […]

Filed Under: Java Tagged With: Java

What is the difference between JRE,JVM and JDK?

February 21, 2013 by Krishna Srinivasan Leave a Comment

If you are a Java developer, it is very often that you think about understanding the JRE,JVM and JDK. Once if you understand these things, it would be quite easy for you to visualize things in logical manner. Also look at the picture below, that will clear all your questions about the JRE,JVM and JDK. […]

Filed Under: Java Tagged With: Java, JRE, JVM

Java HelloWorld vs Scala HelloWorld

June 17, 2012 by Mohamed Sanaulla Leave a Comment

As a first step into learning Scala and as one who is familiar with Java, let us compare the customary Helloworld programs in Java and Scala. You might already know that to run a Java program, there must be a public class with a main method that takes one parameter, a String[ ], and has a void […]

Filed Under: Scala Tagged With: compare java scala, Java, main, scala

Handling/Avoiding Null’s in Java using Guava versus Scala

June 9, 2012 by Mohamed Sanaulla Leave a Comment

There was a discussion about nulls in the latest episode of JavaPosse. Having been inspired from that discussion and with an urge to check out Google Guava library, I came across a way to handle Null’s in Guava which is very similar to the way Scala handles. also read: Java Tutorials Java EE Tutorials Design […]

Filed Under: Java Tagged With: Java, null, scala

  • « Previous Page
  • 1
  • 2
  • 3
  • 4
  • Next Page »

Follow Us

  • Facebook
  • Pinterest
JavaBeat

FEATURED TUTORIALS

Servlet Life Cycle: Explanation

Servlet Life Cycle: Explanation

What is new in Java 6.0 Collections API?

The Java 6.0 Compiler API

The Java 6.0 Compiler API

Copyright © by JavaBeat · All rights reserved

This website uses cookies to ensure you get the best experience on our website. Learn more.