File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Swing / AWT / SWT and the fly likes Listener Declaration/Instantiation Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Listener Declaration/Instantiation " Watch "Listener Declaration/Instantiation " New topic
Author

Listener Declaration/Instantiation

Mark Do
Ranch Hand

Joined: Mar 18, 2014
Posts: 70


Question based on the code provided:
1. What are the type of object and type of reference variable of parameter of the callback?
???
2. What is the central point of the code.
Line 05 is essential because it locates the row that contains the delete button that was clicked.
Line 06 is also essential because it gets the tag button in this row.
Line 07 grabs the text on the tag button.
Line 09 removes tag/value from memory.
???
Brett Spell
Ranch Hand

Joined: Feb 24, 2001
Posts: 96
Mark Do wrote:1. What are the type of object and type of reference variable of parameter of the callback?


The listener is of type OnClickListener . . . but with the caveat that it appears to be intended to be an inner class, so its real type would be something like OuterClass$OnClickListener. I'm guessing that the person (teacher?) asking the question is expecting "OnClickListener" for an answer, though. The parameter type is View, though again its exact provenance is somewhat sketchy.

Mark Do wrote:2. What is the central point of the code.


I think one of us is misinterpreting the question because I have a different understanding of what's being asked. I'd interpret it as a request to summarize what the code does, not identify a particular line (or set of lines) that are of particular importance.
Mark Do
Ranch Hand

Joined: Mar 18, 2014
Posts: 70
I think one of us is misinterpreting the question because I have a different understanding of what's being asked. I'd interpret it as a request to summarize what the code does, not identify a particular line (or set of lines) that are of particular importance.


Ah, you might be right actually.......so would that be just the deleteTag removes both the tag and the value from memory ad deletes the whole row that contains the delete button that was clicked?
Mark Do
Ranch Hand

Joined: Mar 18, 2014
Posts: 70
so what would you say as the central point of the code?
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Listener Declaration/Instantiation