Coverage Report - org.apache.commons.betwixt.schema.TranscriptionConfiguration

Classes in this File Line Coverage Branch Coverage Complexity
TranscriptionConfiguration
56% 
N/A 
1

 1  
 /*
 2  
  * Copyright 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  
 
 18  
 package org.apache.commons.betwixt.schema;
 19  
 
 20  
 import org.apache.commons.betwixt.schema.strategy.SchemaTypeNamingStrategy;
 21  
 import org.apache.commons.betwixt.schema.strategy.impl.QualifiedPropertyTypeSchemaNamingStrategy;
 22  
 
 23  
 /**
 24  
  * Configuration for XMLBeanInfo to XML schema transcription.
 25  
  * All settings are gathered into this one class for convenience.
 26  
  * 
 27  
  * @author <a href='http://jakarta.apache.org/'>Apache Commons Team</a>
 28  
  * @version $Revision: 240123 $
 29  
  */
 30  494
 public class TranscriptionConfiguration {
 31  
     
 32  247
     private DataTypeMapper dataTypeMapper = new DefaultDataTypeMapper();
 33  
     
 34  247
     private SchemaTypeNamingStrategy schemaTypeNamingStrategy = new QualifiedPropertyTypeSchemaNamingStrategy();
 35  
     
 36  
     /**
 37  
      * Gets the <code>DataTypeMapper</code> to be used during the transcription.
 38  
      * @return DataTypeMapper, not null
 39  
      */
 40  
     public DataTypeMapper getDataTypeMapper() {
 41  715
         return dataTypeMapper;
 42  
     }
 43  
 
 44  
     /**
 45  
      * Sets the <code>DataTypeMapper</code> to be used during the transcription/
 46  
      * @param mapper DataTypeMapper, not null
 47  
      */
 48  
     public void setDataTypeMapper(DataTypeMapper mapper) {
 49  0
         dataTypeMapper = mapper;
 50  0
     }
 51  
 
 52  
     /**
 53  
      * Gets the stategy to be used for naming types.
 54  
      * @return <code>SchemaTypeNamingStrategy</code>, not null
 55  
      */
 56  
     public SchemaTypeNamingStrategy getSchemaTypeNamingStrategy() {
 57  1131
         return schemaTypeNamingStrategy;
 58  
     }
 59  
 
 60  
     /**
 61  
      * Sets the strategy to be used for naming types.
 62  
      * @param schemaTypeNamingStrategy <code>SchemaTypeNamingStrategy</code>, not null
 63  
      */
 64  
     public void setSchemaTypeNamingStrategy( SchemaTypeNamingStrategy schemaTypeNamingStrategy) {
 65  0
         this.schemaTypeNamingStrategy = schemaTypeNamingStrategy;
 66  0
     }
 67  
     
 68  
     
 69  
 
 70  
 }