Wednesday, February 27, 2013

difference between static method and instance method in Java

Static Method:
===========
1.A method i.e. declared as static is known as static method.
2.Object is not required to call static method.
3.Non-static (instance) members cannot be accessed in static context (static method, static block and static nested class) directly.
4.For example: public static void show(){..... }.


Instance Method:
============
1.A method i.e. not declared as static is known as instance method.
2.Object is required to call instance methods.
3.static and non-static variables both can be accessed in instance methods.
4.For example: public void show(){...}.


 

Tuesday, February 19, 2013

System.out.println() In Java?

 In Java, the dot operator can only be used to call methods and variables so we know that ‘out’ must be either a method or a variable. Now, how do we categorize ‘out’? Well, ‘out’ could not possibly be a method because of the fact that there are no parentheses – the ‘( )’ – after ‘out’, which means that out is clearly not a method that is being invoked. And, ‘out’ does not accept any arguments because only methods accept arguments – you will never see something like “System.out(5,6).println”. This means ‘out’ must be a variable.

We now know that ‘out’ is a variable, so we must now ask ourselves what kind of variable is it? There are two possibilities – it could be a static or an instance variable. Because ‘out’ is being called with the ‘System’ class name itself, and not an instance of a class (an object), then we know that ‘out’ must be a static variable, since only static variables can be called with just the class name itself. So now we know that ‘out’ is a static member variable belonging to the System class.

The fact that ‘println()’ is clearly a method, we can further classify ‘out’. We have already reasoned that ‘out’ is a static variable belonging to the class System. But now we can see that ‘out’ must be an instance of a class, because it is invoking the method ‘println()’.

When the JVM is initialized, the method initializeSystemClass() is called that does exactly what it’s name says – it initializes the System class and sets the out variable. The initializeSystemClass() method actually calls another method to set the out variable – this method is called setOut().

The more exact answer to the original question is this: inside the System class is the declaration of ‘out’ that looks like: ‘public static final PrintStream out’, and inside the Prinstream class is a declaration of ‘println()’ that has a method signature that looks like: ‘public void println()’.

Here is what the different pieces of System.out.println() actually look like:
//the System class belongs to java.lang package
class System {
  public static final PrintStream out;
  //...
}

//the Prinstream class belongs to java.io package
class PrintStream{
public void println();
//...
}

Tuesday, February 12, 2013

Valentine day special greetins























Scope of Static variables


Static variables cannot be elected for garbage collection while the class is loaded. They can be collected when the respective class loader (that was responsible for loading this class) is itself collected for garbage.


Monday, February 11, 2013

AP EAMCET 2013 Notification

AP EAMCET 2013 Notification Schedule www.apeamcet.org Online Apply AP EAMCET Application form
AP EAMCET
AP EAMCET

AP EAMCET 2013 Notification Schedule - AP EAMCET ( Engineering Agriculture and Medical Common Entrance Test ) Notification 2013 official released by Andhra Pradesh State Government This AP EAMCET conducted by JNTU (Jawaharlal Nehru Technology University ) Hyderabad. The large number of candidates are waiting for this AP EAMCET 2013 Notification. The very good news to this Notification applied Candidates. The EAMCET interested candidates are must qualified in Intermediate. The Intermediate Successfully completed Candidates are eligible for this year EAMCET. This Notification 2013-14 year official published at www.apeamcet.org. 

The Course are offered like B.E., B.Tech, B.Pharmacy, B.Sc Agriculture, B.Sc Horticulture in Engineering and Agriculture courses AND MBBS, BDS, D Phramcy etc. coursed in Medical course. 

This Courses interested candidates are fallow the AP EAMCET official website www.apeamcet.org to download the 2013 year AP EAMCET Online Apply Application form. The Application form submitted along with also paid fee Rupees 250/- paid at nearest E Seva OR AP online Centres. The Completer AP EAMCET Schedule 2013 details are given below. The Interested candidates are fallow the AP EAMCET 2013 Notification Schedule details.


AP EAMCET 2013 Notification Schedule
1For Engineering Entrance Test10-05-2013
10:00 AM to 01:00 PM
2For Agriculture & Medical Entrance Test 10-05-2013
10:00 AM to 01:00 PM
3AP EAMCET Online Application started15-02-2013
3Online Apply Application form Last date 
Without Late Fee
27-03-2013
4Late Fee with 500/-08-04-2013
5EAMCET Application Late Fee 1000/-17-04-2013
6Online Application Late Fee 5000/-27-04-2013
7Last Final Late Fee with 1000/-07-05-2013
8Official Websitewww.apeamcet.org

NOTE :- The AP EAMCET Online Apply Application form started on 15-02-2013.

This Notification is applied candidates are must have age is 17 years to 22 years, SC/ST Candidates upper age 25 years as on 31st December 2012. The AP EAMCET Official notification 2013 link is given below. The Applied candidates are must see the Instructions after then applied this Notification.


Official Website :- www.apeamcet.org

A JiBXException occurred while Unmarshal of request string

This is generally related to :

1. Might may be because of Jars mismatch i.e. There is a mismatch in the jar compilation versions

2. Jars are not builde properly i.e. some classes are missing while builidin Jars.