Solved

dollar sign in .class names (and lots of em)?

Posted on 2001-08-06
2
234 Views
Last Modified: 2010-03-31
Hi everyone,

I just had a simple question for a java person.  I recently made a graphical java application named prog.java.  after i compile it, wham! 15 classes appear, named prog.class, prog$1.class, ..., prog$14.class.  

What's that all about?  If anyone has seen a good source on the net explaining this, i would love to see a link.  

Thanks so much,
Jennifer.

Please comment your comments. thanks!
0
Comment
Question by:jenniferx
2 Comments
 
LVL 1

Accepted Solution

by:
dviji earned 35 total points
ID: 6357044
All the $x.class are inner classes.
i.e

if you have the class like

public class A
{
 //..
 class b
 {
  //..
 }
}
If you compile the class you will get A.class & A$b.class. It means class b is an inner class for class A.

In your GUI program you may be used Listener inner classes.

For more detail goto http://java.sun.com/products/jdk/1.1/docs/guide/innerclasses/.

...dviji
0
 

Author Comment

by:jenniferx
ID: 6357640
Thank you dviji,

that helped a lot. you were right, i have many listeners.

Jennifer.
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

For customizing the look of your lightweight component and making it look lucid like it was made of glass. Or: how to make your component more Apple-ish ;) This tip assumes your component to be of rectangular shape and completely opaque. (COD…
Are you developing a Java application and want to create Excel Spreadsheets? You have come to the right place, this article will describe how you can create Excel Spreadsheets from a Java Application. For the purposes of this article, I will be u…
Viewers learn about the scanner class in this video and are introduced to receiving user input for their programs. Additionally, objects, conditional statements, and loops are used to help reinforce the concepts. Introduce Scanner class: Importing…
The viewer will learn how to implement Singleton Design Pattern in Java.

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now