This week's book giveaway is in the Open Source forum.
We're giving away four copies of Programmers Guide to Apache Thrift and have Randy Abernethy on-line!
See this thread for details.
Win a copy of Programmers Guide to Apache Thrift this week in the Open Source forum!
    Bookmark Topic Watch Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Devaka Cooray
  • Knute Snortum
  • Paul Clapham
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Bear Bibeault
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Ron McLeod
  • Piet Souris
  • Frits Walraven
Bartenders:
  • Ganesh Patekar
  • Tim Holloway
  • salvin francis
  • Mark post as helpful
  • send pies
  • Report post to moderator
The only visible pointer in what's officially a language without pointers, the NullPointerException can lead to much frustration.

NullPointerException is similar to a core dump in C++. It basically refers to a situation where the program expected some object to be present but could not find it.

In other words, the calling object expects the called object to be there, but is suddenly surprised to find that the called object has ditched the calling object and has vanished!

This normally happens due to bad programming/design/programmer's carelessness. Typically beginners (even experienced ones for that matter) tend to make this mistake by not initializing objects properly or not taking care of objects properly, mostly because of the liberty GarbageCollection gives them, thereby giving Java a bad name.

- SathyaSrinivasan (9 Nov 2004).



It should be noted that Java _does_ have pointers. It just doesn't have PointerArithmetic like C and C++. An object reference are essentially pointers to objects. (I should probably find some sources to site for these claims. I'll add them later when I get a chance.)

- LayneLund (12 February 2004)

 
    Bookmark Topic Watch Topic
  • New Topic
Boost this thread!