Clover coverage report - JFox Service-Oriented Application Framework - 1.0-RC1
Coverage timestamp: 星期五 八月 19 2005 13:21:55 CST
file stats: LOC: 213   Methods: 15
NCLOC: 110   Classes: 1
30 day Evaluation Version distributed via the Maven Jar Repository. Clover is not free. You have 30 days to evaluate it. Please visit http://www.thecortex.net/clover to obtain a licensed version of Clover
 
 Source file Conditionals Statements Methods TOTAL
ParameterDescriptor.java - 0% 0% 0%
coverage
 1   
 /**
 2   
  * @(#)ParameterDescriptor.java
 3   
  * 
 4   
  * JFoxSOAF, Service-Oriented Application Framework
 5   
  * 
 6   
  * Copyright(c) JFoxSOAF Team
 7   
  * 
 8   
  * Licensed under the GNU LGPL, Version 2.1 (the "License"); 
 9   
  * you may not use this file except in compliance with the License. 
 10   
  * You may obtain a copy of the License at  
 11   
  * 
 12   
  * http://www.gnu.org/copyleft/lesser.html
 13   
  * 
 14   
  * Unless required by applicable law or agreed to in writing, software
 15   
  * distributed under the License is distributed on an "AS IS" BASIS, 
 16   
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
 17   
  * See the License for the specific language governing permissions and 
 18   
  * limitations under the License. 
 19   
  * 
 20   
  * For more information, please visit:
 21   
  * http://www.jfox.cn/confluence/display/JFoxSOAF/Home
 22   
  * http://www.huihoo.org/jfox/jfoxsoaf
 23   
  */
 24   
 
 25   
 package org.huihoo.jfox.soaf.schema.service;
 26   
 
 27   
 import org.exolab.castor.xml.validators.StringValidator;
 28   
 
 29   
 /**
 30   
  * <p>
 31   
  * Class ParameterDescriptor.
 32   
  * </p>
 33   
  * 
 34   
  * @author <a href="mailto:founder_chen@yahoo.com.cn">Peter Cheng </a>
 35   
  * @version $Revision: 1.8 $ $Date: 2005/05/22 06:48:07 $
 36   
  * @version Revision: 1.0
 37   
  */
 38   
 
 39   
 public class ParameterDescriptor extends
 40   
         org.exolab.castor.xml.util.XMLClassDescriptorImpl {
 41   
 
 42   
     /**
 43   
      * Field nsPrefix
 44   
      */
 45   
     private java.lang.String nsPrefix;
 46   
 
 47   
     /**
 48   
      * Field nsURI
 49   
      */
 50   
     private java.lang.String nsURI;
 51   
 
 52   
     /**
 53   
      * Field xmlName
 54   
      */
 55   
     private java.lang.String xmlName;
 56   
 
 57   
     /**
 58   
      * Field identity
 59   
      */
 60   
     private org.exolab.castor.xml.XMLFieldDescriptor identity;
 61   
 
 62  0
     public ParameterDescriptor() {
 63  0
         super();
 64  0
         xmlName = "parameter";
 65   
 
 66   
         //-- set grouping compositor
 67  0
         setCompositorAsSequence();
 68  0
         org.exolab.castor.xml.util.XMLFieldDescriptorImpl desc = null;
 69  0
         org.exolab.castor.xml.XMLFieldHandler handler = null;
 70  0
         org.exolab.castor.xml.FieldValidator fieldValidator = null;
 71   
         //-- initialize attribute descriptors
 72   
 
 73   
         //-- initialize element descriptors
 74   
 
 75   
         //-- _name
 76  0
         desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl(
 77   
                 java.lang.String.class, "_name", "name",
 78   
                 org.exolab.castor.xml.NodeType.Element);
 79  0
         desc.setImmutable(true);
 80  0
         handler = (new org.exolab.castor.xml.XMLFieldHandler() {
 81  0
             public java.lang.Object getValue(java.lang.Object object)
 82   
                     throws IllegalStateException {
 83  0
                 Parameter target = (Parameter) object;
 84  0
                 return target.getName();
 85   
             }
 86   
 
 87  0
             public void setValue(java.lang.Object object, java.lang.Object value)
 88   
                     throws IllegalStateException, IllegalArgumentException {
 89  0
                 try {
 90  0
                     Parameter target = (Parameter) object;
 91  0
                     target.setName((java.lang.String) value);
 92   
                 } catch (java.lang.Exception ex) {
 93  0
                     throw new IllegalStateException(ex.toString());
 94   
                 }
 95   
             }
 96   
 
 97  0
             public java.lang.Object newInstance(java.lang.Object parent) {
 98  0
                 return null;
 99   
             }
 100   
         });
 101  0
         desc.setHandler(handler);
 102  0
         desc.setRequired(true);
 103  0
         desc.setMultivalued(false);
 104  0
         addFieldDescriptor(desc);
 105   
 
 106   
         //-- validation code for: _name
 107  0
         fieldValidator = new org.exolab.castor.xml.FieldValidator();
 108  0
         fieldValidator.setMinOccurs(1);
 109   
         { //-- local scope
 110  0
             StringValidator typeValidator = new StringValidator();
 111  0
             typeValidator.setWhiteSpace("preserve");
 112  0
             fieldValidator.setValidator(typeValidator);
 113   
         }
 114  0
         desc.setValidator(fieldValidator);
 115   
         //-- _value
 116  0
         desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl(
 117   
                 java.lang.String.class, "_value", "value",
 118   
                 org.exolab.castor.xml.NodeType.Element);
 119  0
         desc.setImmutable(true);
 120  0
         handler = (new org.exolab.castor.xml.XMLFieldHandler() {
 121  0
             public java.lang.Object getValue(java.lang.Object object)
 122   
                     throws IllegalStateException {
 123  0
                 Parameter target = (Parameter) object;
 124  0
                 return target.getValue();
 125   
             }
 126   
 
 127  0
             public void setValue(java.lang.Object object, java.lang.Object value)
 128   
                     throws IllegalStateException, IllegalArgumentException {
 129  0
                 try {
 130  0
                     Parameter target = (Parameter) object;
 131  0
                     target.setValue((java.lang.String) value);
 132   
                 } catch (java.lang.Exception ex) {
 133  0
                     throw new IllegalStateException(ex.toString());
 134   
                 }
 135   
             }
 136   
 
 137  0
             public java.lang.Object newInstance(java.lang.Object parent) {
 138  0
                 return null;
 139   
             }
 140   
         });
 141  0
         desc.setHandler(handler);
 142  0
         desc.setRequired(true);
 143  0
         desc.setMultivalued(false);
 144  0
         addFieldDescriptor(desc);
 145   
 
 146   
         //-- validation code for: _value
 147  0
         fieldValidator = new org.exolab.castor.xml.FieldValidator();
 148  0
         fieldValidator.setMinOccurs(1);
 149   
         { //-- local scope
 150  0
             StringValidator typeValidator = new StringValidator();
 151  0
             typeValidator.setWhiteSpace("preserve");
 152  0
             fieldValidator.setValidator(typeValidator);
 153   
         }
 154  0
         desc.setValidator(fieldValidator);
 155   
     }
 156   
 
 157   
     /**
 158   
      * Method getAccessMode
 159   
      */
 160  0
     public org.exolab.castor.mapping.AccessMode getAccessMode() {
 161  0
         return null;
 162   
     }
 163   
 
 164   
     /**
 165   
      * Method getExtends
 166   
      */
 167  0
     public org.exolab.castor.mapping.ClassDescriptor getExtends() {
 168  0
         return null;
 169   
     }
 170   
 
 171   
     /**
 172   
      * Method getIdentity
 173   
      */
 174  0
     public org.exolab.castor.mapping.FieldDescriptor getIdentity() {
 175  0
         return identity;
 176   
     }
 177   
 
 178   
     /**
 179   
      * Method getJavaClass
 180   
      */
 181  0
     public java.lang.Class getJavaClass() {
 182  0
         return org.huihoo.jfox.soaf.schema.service.Parameter.class;
 183   
     }
 184   
 
 185   
     /**
 186   
      * Method getNameSpacePrefix
 187   
      */
 188  0
     public java.lang.String getNameSpacePrefix() {
 189  0
         return nsPrefix;
 190   
     }
 191   
 
 192   
     /**
 193   
      * Method getNameSpaceURI
 194   
      */
 195  0
     public java.lang.String getNameSpaceURI() {
 196  0
         return nsURI;
 197   
     }
 198   
 
 199   
     /**
 200   
      * Method getValidator
 201   
      */
 202  0
     public org.exolab.castor.xml.TypeValidator getValidator() {
 203  0
         return this;
 204   
     }
 205   
 
 206   
     /**
 207   
      * Method getXMLName
 208   
      */
 209  0
     public java.lang.String getXMLName() {
 210  0
         return xmlName;
 211   
     }
 212   
 
 213   
 }