ActionSource.h

Go to the documentation of this file.
00001 #ifndef JAVA_AWT_EVENT_ACTIONSOURCE_H
00002 #define JAVA_AWT_EVENT_ACTIONSOURCE_H 1
00003 
00004 #ifndef JAVA_UTIL_EVENTSOURCE_H
00005 #include <java_util/EventSource.h>
00006 #endif /* JAVA_UTIL_EVENTSOURCE_H */
00007 #ifndef JAVA_LANG_SYNC_H
00008 #include <java_lang/Sync.h>
00009 #endif /* JAVA_LANG_SYNC_H */
00010 #ifndef JAVA_UTIL_LINKEDLIST_H
00011 #include <java_util/LinkedList.h>
00012 #endif /* JAVA_UTIL_LINKEDLIST_H */
00013 #ifndef JAVA_AWT_EVENT_ACTIONLISTENER_H
00014 #include <java_awt_event/ActionListener.h>
00015 #endif /* JAVA_AWT_EVENT_ACTIONLISTENER_H */
00016 #ifndef JAVA_AWT_SPEC
00017 #include <java_awt/Spec.h>
00018 #endif /* JAVA_AWT_SPEC */
00019 
00020 namespace java {
00021   namespace awt {
00022     namespace event {
00023 
00024       using namespace java::util;
00025 
00037       class JAVA_AWT_SPEC ActionSource 
00038         : virtual public java::util::EventSource
00039         , virtual public Sync
00040       {
00041 
00042       public:
00043 
00044         virtual String getActionCommand() const = 0;
00045 
00051         virtual void addActionListener(const Ref<ActionListener> l);
00052 
00058         virtual void removeActionListener(const Ref<ActionListener> l);
00059 
00063         virtual jboolean hasActionListeners() const;
00064 
00076         virtual Ref<List> getActionListeners() const;
00077 
00083         virtual void processActionEvent(const ActionEvent& e);
00084 
00085       protected:
00086 
00087         LinkedList listeners;
00088         REGISTER_MEMBERS;
00089 
00090       };
00091 
00092     } // namespace event
00093   } // namespace awt
00094 } // namespace java
00095 
00096 #endif /* JAVA_AWT_EVENT_ACTIONSOURCE_H */

Generated on Fri May 16 11:54:42 2008 for CrossPlatformJavaLikeC++API by  doxygen 1.5.3