Source for org.jfree.serializer.JCommonSerializerBoot

   1: /**
   2:  * ===================================================
   3:  * JCommon-Serializer : a free serialization framework
   4:  * ===================================================
   5:  *
   6:  * Project Info:  http://www.jfree.org/jfreereport/jcommon-serializer/
   7:  * Project Lead:  Thomas Morgner;
   8:  *
   9:  * (C) Copyright 2006, by Object Refinery Limited and Pentaho Corporation.
  10:  *
  11:  * This library is free software; you can redistribute it and/or modify it under the terms
  12:  * of the GNU Lesser General Public License as published by the Free Software Foundation;
  13:  * either version 2.1 of the License, or (at your option) any later version.
  14:  *
  15:  * This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
  16:  * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  17:  * See the GNU Lesser General Public License for more details.
  18:  *
  19:  * You should have received a copy of the GNU Lesser General Public License along with this
  20:  * library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330,
  21:  * Boston, MA 02111-1307, USA.
  22:  *
  23:  * [Java is a trademark or registered trademark of Sun Microsystems, Inc.
  24:  * in the United States and other countries.]
  25:  *
  26:  * ------------
  27:  * JCommonSerializerBoot.java
  28:  * ------------
  29:  * (C) Copyright 2006, by Object Refinery Limited and Pentaho Corporation.
  30:  *
  31:  * Original Author:  Thomas Morgner;
  32:  * Contributor(s):   -;
  33:  *
  34:  * $Id: JCommonSerializerBoot.java 1776 2006-04-17 16:03:24Z taqua $
  35:  *
  36:  * Changes
  37:  * -------
  38:  *
  39:  *
  40:  */
  41: package org.jfree.serializer;
  42: 
  43: import org.jfree.base.AbstractBoot;
  44: import org.jfree.base.BootableProjectInfo;
  45: import org.jfree.util.Configuration;
  46: 
  47: /**
  48:  * Creation-Date: 17.02.2006, 21:54:24
  49:  *
  50:  * @author Thomas Morgner
  51:  */
  52: public class JCommonSerializerBoot extends AbstractBoot
  53: {
  54:   private static JCommonSerializerBoot instance;
  55: 
  56:   public static synchronized JCommonSerializerBoot getInstance()
  57:   {
  58:     if (instance == null)
  59:     {
  60:       instance = new JCommonSerializerBoot();
  61:     }
  62:     return instance;
  63:   }
  64: 
  65:   private JCommonSerializerBoot()
  66:   {
  67:   }
  68: 
  69:   /**
  70:    * Loads the configuration. This will be called exactly once.
  71:    *
  72:    * @return The configuration.
  73:    */
  74:   protected Configuration loadConfiguration()
  75:   {
  76:     return createDefaultHierarchicalConfiguration
  77:             ("/org/jfree/serializer/jcommon-serializer.properties",
  78:              "/jcommon-serializer.properties", true);
  79:   }
  80: 
  81:   /** Performs the boot. */
  82:   protected void performBoot()
  83:   {
  84: 
  85:   }
  86: 
  87:   /**
  88:    * Returns the project info.
  89:    *
  90:    * @return The project info.
  91:    */
  92:   protected BootableProjectInfo getProjectInfo()
  93:   {
  94:     return JCommonSerializerInfo.getInstance();
  95:   }
  96: }