Clover coverage report - JGAP 3.1
Coverage timestamp: Mo Dez 11 2006 21:16:18 CET
file stats: LOC: 65   Methods: 2
NCLOC: 19   Classes: 1
 
 Source file Conditionals Statements Methods TOTAL
BaseChromosome.java 50% 75% 100% 75%
coverage coverage
 1    /*
 2    * This file is part of JGAP.
 3    *
 4    * JGAP offers a dual license model containing the LGPL as well as the MPL.
 5    *
 6    * For licencing information please see the file license.txt included with JGAP
 7    * or have a look at the top of class org.jgap.Chromosome which representatively
 8    * includes the JGAP license policy applicable for any file delivered with JGAP.
 9    */
 10    package org.jgap;
 11   
 12    /**
 13    * Base class for any implementation of interface IChromosome.
 14    *
 15    * @author Klaus Meffert
 16    * @since 3.0
 17    */
 18    public abstract class BaseChromosome
 19    implements IChromosome, IInitializer {
 20    /** String containing the CVS revision. Read out via reflection!*/
 21    private final static String CVS_REVISION = "$Revision: 1.6 $";
 22   
 23    /**
 24    * The configuration object to use
 25    */
 26    private /*transient*/ Configuration m_configuration;
 27   
 28    /**
 29    * The only constructor in this class. Sets the immutable configuration.
 30    * @param a_configuration the configuration to set
 31    * @throws InvalidConfigurationException if configuration is null
 32    *
 33    * @author Klaus Meffert
 34    * @since 3.0
 35    */
 36  28099 public BaseChromosome(Configuration a_configuration)
 37    throws InvalidConfigurationException {
 38  28099 if (a_configuration == null) {
 39  0 throw new InvalidConfigurationException(
 40    "Configuration to be set must not"
 41    + " be null!");
 42    }
 43  28099 m_configuration = a_configuration;
 44    }
 45   
 46    /**
 47    * @return the configuration used
 48    *
 49    * @author Klaus Meffert
 50    * @since 3.0
 51    */
 52  82919 public Configuration getConfiguration() {
 53  82919 return m_configuration;
 54    }
 55   
 56    /**
 57    * Creates and returns a copy of this object.
 58    * @return a clone of this instance
 59    * @throws IllegalStateException instead of CloneNotSupportedException
 60    *
 61    * @author Klaus Meffert
 62    * @since 3.0
 63    */
 64    public abstract Object clone();
 65    }