Coverage Report - org.apache.commons.workflow.ScopeEvent
 
Classes in this File Line Coverage Branch Coverage Complexity
ScopeEvent
0%
0/11
N/A
1
 
 1  
 /*
 2  
  * Copyright 1999-2001,2004 The Apache Software Foundation.
 3  
  * 
 4  
  * Licensed under the Apache License, Version 2.0 (the "License");
 5  
  * you may not use this file except in compliance with the License.
 6  
  * You may obtain a copy of the License at
 7  
  * 
 8  
  *      http://www.apache.org/licenses/LICENSE-2.0
 9  
  * 
 10  
  * Unless required by applicable law or agreed to in writing, software
 11  
  * distributed under the License is distributed on an "AS IS" BASIS,
 12  
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 13  
  * See the License for the specific language governing permissions and
 14  
  * limitations under the License.
 15  
  */ 
 16  
 
 17  
 package org.apache.commons.workflow;
 18  
 
 19  
 
 20  
 import java.util.EventObject;
 21  
 
 22  
 
 23  
 /**
 24  
  * A <strong>ScopeEvent</strong> provides notification to a
 25  
  * <code>ScopeListener</code> that a specified event has occurred for
 26  
  * the specified scope.
 27  
  *
 28  
  * @version $Revision: 155475 $ $Date: 2005-02-26 13:31:11 +0000 (Sat, 26 Feb 2005) $
 29  
  * @author Craig R. McClanahan
 30  
  */
 31  
 
 32  
 public class ScopeEvent extends EventObject {
 33  
 
 34  
 
 35  
     // ----------------------------------------------------------- Constructors
 36  
 
 37  
 
 38  
     /**
 39  
      * Construct a new immutable ScopeEvent.
 40  
      *
 41  
      * @param scope Scope in which this event occurred
 42  
      * @param key Bean key on which this event occurred
 43  
      * @param value Bean value on which this event occurred
 44  
      */
 45  
     public ScopeEvent(Scope scope, String key, Object value) {
 46  
 
 47  0
         super(scope);
 48  0
         this.scope = scope;
 49  0
         this.key = key;
 50  0
         this.value = value;
 51  
 
 52  0
     }
 53  
         
 54  
 
 55  
     // ------------------------------------------------------------- Properties
 56  
 
 57  
 
 58  
     /**
 59  
      * The bean key upon which this event occurred.
 60  
      */
 61  0
     protected String key = null;
 62  
 
 63  
     public String getKey() {
 64  
 
 65  0
         return (this.key);
 66  
 
 67  
     }
 68  
 
 69  
 
 70  
     /**
 71  
      * The <code>Scope</code> upon which this event occurred.
 72  
      */
 73  0
     protected Scope scope = null;
 74  
 
 75  
     public Scope getScope() {
 76  
 
 77  0
         return (this.scope);
 78  
 
 79  
     }
 80  
 
 81  
 
 82  
     /**
 83  
      * The bean value upon which this event occurred.  For
 84  
      * <code>beanReplaced</code> events, this will be the previous value.
 85  
      */
 86  0
     protected Object value = null;
 87  
 
 88  
     public Object getValue() {
 89  
 
 90  0
         return (this.value);
 91  
 
 92  
     }
 93  
 
 94  
 
 95  
 }