Search:

Type: Posts; User: Norm

Search: Search took 0.09 seconds.

  1. Thread: Interfaces

    by Norm
    Replies
    14
    Views
    2,284

    Re: Interfaces

    The compiler will create an anonymous (no name) class the way that you coded it in post#9.
  2. Thread: Interfaces

    by Norm
    Replies
    14
    Views
    2,284

    Re: Interfaces

    Not quite. You are adding an instance of an ActionListener object to the fileItem class's list of ActionListeners.

    Yes
  3. Thread: Interfaces

    by Norm
    Replies
    14
    Views
    2,284

    Re: Interfaces

    No. Your method of creating an anonymous class is incorrect.
    You need to add the method definition inside of the {}s

    Do a Search on the Forum for ActionListener for sample code.
  4. Thread: Interfaces

    by Norm
    Replies
    14
    Views
    2,284

    Re: Interfaces

    Another way to see interfaces is as a way to give a data type to a class. Java requires most arguments to methods to be of a certain data type. Interfaces allow one class to have many different data...
Results 1 to 4 of 5