Coverage report

  %line %branch
org.apache.torque.engine.platform.PlatformOracleImpl
91% 
100% 

 1  
 package org.apache.torque.engine.platform;
 2  
 
 3  
 /*
 4  
  * Licensed to the Apache Software Foundation (ASF) under one
 5  
  * or more contributor license agreements.  See the NOTICE file
 6  
  * distributed with this work for additional information
 7  
  * regarding copyright ownership.  The ASF licenses this file
 8  
  * to you under the Apache License, Version 2.0 (the
 9  
  * "License"); you may not use this file except in compliance
 10  
  * with the License.  You may obtain a copy of the License at
 11  
  *
 12  
  *   http://www.apache.org/licenses/LICENSE-2.0
 13  
  *
 14  
  * Unless required by applicable law or agreed to in writing,
 15  
  * software distributed under the License is distributed on an
 16  
  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 17  
  * KIND, either express or implied.  See the License for the
 18  
  * specific language governing permissions and limitations
 19  
  * under the License.
 20  
  */
 21  
 
 22  
 import org.apache.torque.engine.database.model.Domain;
 23  
 import org.apache.torque.engine.database.model.SchemaType;
 24  
 
 25  
 /**
 26  
  * Oracle Platform implementation.
 27  
  *
 28  
  * @author <a href="mailto:mpoeschl@marmot.at">Martin Poeschl</a>
 29  
  * @version $Id: PlatformOracleImpl.java 473814 2006-11-11 22:30:30Z tv $
 30  
  */
 31  
 public class PlatformOracleImpl extends PlatformDefaultImpl
 32  
 {
 33  
     /**
 34  
      * Default constructor.
 35  
      */
 36  
     public PlatformOracleImpl()
 37  
     {
 38  7
         super();
 39  7
         initialize();
 40  7
     }
 41  
 
 42  
     /**
 43  
      * Initializes db specific domain mapping.
 44  
      */
 45  
     private void initialize()
 46  
     {
 47  7
         setSchemaDomainMapping(new Domain(SchemaType.TINYINT, "NUMBER", "3", "0"));
 48  7
         setSchemaDomainMapping(new Domain(SchemaType.SMALLINT, "NUMBER", "5", "0"));
 49  7
         setSchemaDomainMapping(new Domain(SchemaType.INTEGER, "NUMBER", "10", "0"));
 50  7
         setSchemaDomainMapping(new Domain(SchemaType.BOOLEANINT, "NUMBER", "1", "0"));
 51  7
         setSchemaDomainMapping(new Domain(SchemaType.BIGINT, "NUMBER", "20", "0"));
 52  7
         setSchemaDomainMapping(new Domain(SchemaType.REAL, "NUMBER"));
 53  7
         setSchemaDomainMapping(new Domain(SchemaType.DOUBLE, "FLOAT"));
 54  7
         setSchemaDomainMapping(new Domain(SchemaType.DECIMAL, "NUMBER"));
 55  7
         setSchemaDomainMapping(new Domain(SchemaType.NUMERIC, "NUMBER"));
 56  7
         setSchemaDomainMapping(new Domain(SchemaType.VARCHAR, "VARCHAR2"));
 57  7
         setSchemaDomainMapping(new Domain(SchemaType.LONGVARCHAR, "VARCHAR2", "2000"));
 58  7
         setSchemaDomainMapping(new Domain(SchemaType.TIME, "DATE"));
 59  7
         setSchemaDomainMapping(new Domain(SchemaType.TIMESTAMP, "TIMESTAMP"));
 60  7
         setSchemaDomainMapping(new Domain(SchemaType.BINARY, "LONG RAW"));
 61  7
         setSchemaDomainMapping(new Domain(SchemaType.VARBINARY, "BLOB"));
 62  7
         setSchemaDomainMapping(new Domain(SchemaType.LONGVARBINARY, "LONG RAW"));
 63  7
     }
 64  
 
 65  
     /**
 66  
      * @see Platform#getMaxColumnNameLength()
 67  
      */
 68  
     public int getMaxColumnNameLength()
 69  
     {
 70  0
         return 30;
 71  
     }
 72  
 
 73  
     /**
 74  
      * @see Platform#getNativeIdMethod()
 75  
      */
 76  
     public String getNativeIdMethod()
 77  
     {
 78  0
         return Platform.SEQUENCE;
 79  
     }
 80  
 
 81  
     /**
 82  
      * @see Platform#getAutoIncrement()
 83  
      */
 84  
     public String getAutoIncrement()
 85  
     {
 86  14
         return "";
 87  
     }
 88  
 }

This report is generated by jcoverage, Maven and Maven JCoverage Plugin.