[Rapforums-developer] src/source/edu/fullcoll/uportal/channels/rap/forum/xml ViewXMLFactory.java,NON
Status: Beta
Brought to you by:
brippe
From: <br...@pr...> - 2004-01-26 19:03:22
|
Update of /cvsroot/rapforums/src/source/edu/fullcoll/uportal/channels/rap/forum/xml In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24345 Added Files: ViewXMLFactory.java Log Message: Update to version 0.8.3 --- NEW FILE: ViewXMLFactory.java --- /** * Copyright (c) 2004, Fullerton College. All Rights Reserved. (http://www.fullcoll.edu) * This software is distributed under the IBM Public Licence. Please see * the license infomation for more details at http://www.opensource.org/licenses/ibmpl.php. * EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED * ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER * EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS * OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. * Each Recipient is solely responsible for determining the appropriateness of using * and distributing the Program and assumes all risks associated with its exercise * of rights under this Agreement, including but not limited to the risks and costs * of program errors, compliance with applicable laws, damage to or loss of data, * programs or equipment, and unavailability or interruption of operations. * This software is OSI Certified Open Source Software. OSI Certified is a certification * mark of the Open Source Initiative */ package edu.fullcoll.uportal.channels.rap.forum.xml; import edu.fullcoll.uportal.channels.rap.forum.database.RAPDBConfig; /** * This class handles creation of RAPViewXML classes which build xml documents which are forwarded to * the xsl for transformations into HTML. RAPViewXML is dependent on the particular database product * being used to take advantage of the features in those systems. * * <ul>To use the appropriate RAPViewXML class you MUST configure the channel parameter "dbProduct" to one * of the following: * <li>MSSQL - Microsoft SQL Server Database configuration * <li>MYSQL - MySQL Database Configuration * <li>ORACLE - Oracle Database Configuration * </ul> * * By default the forums use "MSSQL" as the supported database. * * @author Brad Rippe (br...@fu...) * @version 0.8.3 * * @see edu.fullcoll.uportal.channels.rap.forum.xml.MSViewXML * @see edu.fullcoll.uportal.channels.rap.forum.xml.MySQLViewXML * @see edu.fullcoll.uportal.channels.rap.forum.xml.OracleViewXML */ public class ViewXMLFactory { /** * This method returns the appropriate RAPViewXML based on the database the forums are using. * @return the appropriate RAPViewXML class */ public static RAPViewXML createRAPViewXML() { if(RAPDBConfig.getInstance().getDatabaseProduct().equals("MYSQL")) return new MySQLViewXML(); else if(RAPDBConfig.getInstance().getDatabaseProduct().equals("ORACLE")) return new OracleViewXML(); else return new MSViewXML(); } } |