jQuery in Action, 3rd edition
The moose likes Java in General and the fly likes Why some java classes starts with underscore(Ex: _Test) Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of OCA Java SE 8 Programmer I Study Guide this week in the OCAJP 8 forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "Why some java classes starts with underscore(Ex: _Test)" Watch "Why some java classes starts with underscore(Ex: _Test)" New topic

Why some java classes starts with underscore(Ex: _Test)

Srinivas Palam
Ranch Hand

Joined: Oct 20, 2005
Posts: 66
public class Test extends _Test {
Some methods and statements

Togaf Part 1 and 2
Hebert Coelho
Ranch Hand

Joined: Jul 14, 2010
Posts: 754

I have never seen some pattern like that.

The only name pattern with _ that I have seen is the JPA Canonical Metamodel.

[uaiHebert.com] [Full WebApplication JSF EJB JPA JAAS with source code to download] One Table Per SubClass [Web/JSF]
Paul Clapham

Joined: Oct 14, 2005
Posts: 19747

That would be because the person who created the class decided to start its name with an underscore. Nothing else. It doesn't mean anything specific in the Java language, although it might mean something in the mind of the person who wrote the class.
Rob Spoor

Joined: Oct 27, 2005
Posts: 20131

Likewise, and those end with _, not start with it.
[Edit]In response to Hebert

How To Ask Questions How To Answer Questions
Campbell Ritchie

Joined: Oct 13, 2005
Posts: 44524
Underscores starting names were standard practice in some C/C++ conventions. The corresponding Java convention is in this page, ยง13.
I agree. Here's the link: http://aspose.com/file-tools
subject: Why some java classes starts with underscore(Ex: _Test)
It's not a secret anymore!