CVS: TapestryBook/petstore/src/org/apache/tapestry/pets/components DirectArea.java,1.1,1.2

Howard Lewis Ship <[email protected]> Thu, 27 Feb 2003 16:25:50 -0800
Newsgroups gmane.comp.java.tapestry.cvs
Message-ID <[email protected]>
Update of /cvsroot/tapestry/TapestryBook/petstore/src/org/apache/tapestry/pets/components
In directory sc8-pr-cvs1:/tmp/cvs-serv10808/petstore/src/org/apache/tapestry/pets/components

Modified Files:
	DirectArea.java 
Log Message:
Checkpoint; pretty  much done with chapter 3.

Index: DirectArea.java
===================================================================
RCS file: /cvsroot/tapestry/TapestryBook/petstore/src/org/apache/tapestry/pets/components/DirectArea.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** DirectArea.java	7 Feb 2003 16:44:58 -0000	1.1
--- DirectArea.java	28 Feb 2003 00:25:47 -0000	1.2
***************
*** 27,31 ****
  public abstract class DirectArea extends AbstractComponent implements IDirect
  {
!     private IBinding _listenerBinding;;
  
  	public abstract Object getParameters();
--- 27,31 ----
  public abstract class DirectArea extends AbstractComponent implements IDirect
  {
!     public abstract IBinding getListenerBinding();
  
  	public abstract Object getParameters();
***************
*** 50,53 ****
--- 50,54 ----
      public void trigger(IRequestCycle cycle) throws RequestCycleException
      {
+     	IBinding listenerBinding = getListenerBinding();
          IActionListener listener =  null;
    
***************
*** 55,59 ****
          {
              listener =
!                 (IActionListener) _listenerBinding.getObject("listener", IActionListener.class);
  
          }
--- 56,60 ----
          {
              listener =
!                 (IActionListener) listenerBinding.getObject("listener", IActionListener.class);
  
          }
***************
*** 64,68 ****
  
          if (listener == null)
!             throw new RequiredParameterException(this, "listener", _listenerBinding);
  
          listener.actionTriggered(this, cycle);
--- 65,69 ----
  
          if (listener == null)
!             throw new RequiredParameterException(this, "listener", listenerBinding);
  
          listener.actionTriggered(this, cycle);
***************
*** 72,85 ****
      {
          return false;
-     }
- 
-     public IBinding getListenerBinding()
-     {
-         return _listenerBinding;
-     }
- 
-     public void setListenerBinding(IBinding listenerBinding)
-     {
-         _listenerBinding = listenerBinding;
      }
  
--- 73,76 ----



-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf