2009/05/20 - Apache Shale has been retired.

For more information, please explore the Attic.

Coverage Report - org.apache.shale.dialog.base.AbstractDialogListener
 
Classes in this File Line Coverage Branch Coverage Complexity
AbstractDialogListener
0% 
N/A 
1
 
 1  
 /*
 2  
  * Licensed to the Apache Software Foundation (ASF) under one or more
 3  
  * contributor license agreements.  See the NOTICE file distributed with
 4  
  * this work for additional information regarding copyright ownership.
 5  
  * The ASF licenses this file to you under the Apache License, Version 2.0
 6  
  * (the "License"); you may not use this file except in compliance with
 7  
  * the License.  You may obtain a copy of the License at
 8  
  *
 9  
  *      http://www.apache.org/licenses/LICENSE-2.0
 10  
  *
 11  
  * Unless required by applicable law or agreed to in writing, software
 12  
  * distributed under the License is distributed on an "AS IS" BASIS,
 13  
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 14  
  * See the License for the specific language governing permissions and
 15  
  * limitations under the License.
 16  
  */
 17  
 
 18  
 package org.apache.shale.dialog.base;
 19  
 
 20  
 import java.io.Serializable;
 21  
 
 22  
 import org.apache.shale.dialog.DialogContext;
 23  
 import org.apache.shale.dialog.DialogListener;
 24  
 
 25  
 /**
 26  
  * <p>Convenience abstract {@link DialogListener} implementation. Subclasses
 27  
  * are expected to be serializable.</p>
 28  
  *
 29  
  * @since 1.0.4
 30  
  */
 31  0
 public abstract class AbstractDialogListener implements DialogListener, Serializable {
 32  
 
 33  
     //------------------------------------------------------------- Properties
 34  
 
 35  
     /**
 36  
      * The {@link DialogContext} we are interested in.
 37  
      */
 38  
     private DialogContext dialogContext;
 39  
 
 40  
 
 41  
     //------------------------------------------------- DialogListener methods
 42  
 
 43  
     /**
 44  
      * {@inheritDoc}
 45  
      *
 46  
      * @see org.apache.shale.dialog.DialogListener#onStart()
 47  
      */
 48  
     public void onStart() {
 49  
 
 50  
         // Do nothing
 51  
 
 52  0
     }
 53  
 
 54  
     /**
 55  
      * {@inheritDoc}
 56  
      *
 57  
      * @see org.apache.shale.dialog.DialogListener#onStop()
 58  
      */
 59  
     public void onStop() {
 60  
 
 61  
         // Do nothing
 62  
 
 63  0
     }
 64  
 
 65  
     /**
 66  
      * {@inheritDoc}
 67  
      *
 68  
      * @see org.apache.shale.dialog.DialogListener#onException(java.lang.Exception)
 69  
      */
 70  
     public void onException(Exception e) {
 71  
 
 72  
         // Do nothing
 73  
 
 74  0
     }
 75  
 
 76  
     /**
 77  
      * {@inheritDoc}
 78  
      *
 79  
      * @see org.apache.shale.dialog.DialogListener#onEntry(java.lang.String)
 80  
      */
 81  
     public void onEntry(String stateId) {
 82  
 
 83  
         // Do nothing
 84  
 
 85  0
     }
 86  
 
 87  
     /**
 88  
      * {@inheritDoc}
 89  
      *
 90  
      * @see org.apache.shale.dialog.DialogListener#onExit(java.lang.String)
 91  
      */
 92  
     public void onExit(String stateId) {
 93  
 
 94  
         // Do nothing
 95  
 
 96  0
     }
 97  
 
 98  
     /**
 99  
      * {@inheritDoc}
 100  
      *
 101  
      * @see org.apache.shale.dialog.DialogListener#onTransition(java.lang.String,java.lang.String)
 102  
      */
 103  
     public void onTransition(String fromStateId, String toStateId) {
 104  
 
 105  
         // Do nothing
 106  
 
 107  0
     }
 108  
 
 109  
     /**
 110  
      * {@inheritDoc}
 111  
      *
 112  
      * @see org.apache.shale.dialog.DialogListener#getDialogContext()
 113  
      */
 114  
     public DialogContext getDialogContext() {
 115  
 
 116  0
         return dialogContext;
 117  
 
 118  
     }
 119  
 
 120  
     /**
 121  
      * {@inheritDoc}
 122  
      *
 123  
      * @see org.apache.shale.dialog.DialogListener#setDialogContext(org.apache.shale.dialog.DialogContext)
 124  
      */
 125  
     public void setDialogContext(DialogContext dialogContext) {
 126  
 
 127  0
         this.dialogContext = dialogContext;
 128  
 
 129  0
     }
 130  
 
 131  
 }