KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jboss > portal > setup > impl > dl > dbloader > hibernate > HibernateDataLoaderConfigImpl


1 /*****************************************
2  * *
3  * JBoss Portal: The OpenSource Portal *
4  * *
5  * Distributable under LGPL license. *
6  * See terms of license at gnu.org. *
7  * *
8  *****************************************/

9 package org.jboss.portal.setup.impl.dl.dbloader.hibernate;
10
11 import org.jboss.portal.setup.dl.HibernateDataLoaderConfig;
12 import org.jboss.portal.setup.config.HibernateConfig;
13 import org.jboss.portal.setup.PortalSetupException;
14 import org.jboss.portal.setup.impl.config.ConfigurationImpl;
15
16 import java.util.List JavaDoc;
17
18 /**
19  * @author <a HREF="mailto:palber@novell.com">Polina Alber</a>
20  * Date: Apr 14, 2005; Time: 4:02:41 PM
21  * @jmx.mbean
22  * @jboss.xmbean
23  * @since JBoss portal 2.0
24  * Class org.jboss.portal.setup.impl.dl.dbloader.hibernate.HibernateDataLoaderConfigImpl
25  */

26 public class HibernateDataLoaderConfigImpl extends ConfigurationImpl implements HibernateDataLoaderConfig
27 {
28
29    private HibernateConfig m_hibernateConfig;
30    private String JavaDoc m_dataQueryStr;
31    private String JavaDoc m_dataLoaderClassname;
32
33
34    /**
35     * @return a sql query string that will be used to validae data existence.
36     * @jmx.managed-attribute
37     * access="read-write"
38     */

39    public String JavaDoc getDataQueryString()
40    {
41       return m_dataQueryStr;
42    }
43
44    /**
45     * @param queryString a sql query string that will be used to validae data existence.
46     * @jmx.managed-attribute
47     * access="read-write"
48     */

49    public void setDataQueryString(String JavaDoc queryString)
50    {
51       m_dataQueryStr = queryString;
52    }
53
54
55    /**
56     * @return a data loader implementation class name
57     * @jmx.managed-attribute
58     * access="read-write"
59     */

60    public String JavaDoc getDataLoaderClass()
61    {
62       return m_dataLoaderClassname;
63    }
64
65    /**
66     * @param className a class name of DataLoader implementation
67     * @jmx.managed-attribute
68     * access="read-write"
69     */

70    public void setDataLoaderClass(String JavaDoc className)
71    {
72       m_dataLoaderClassname = className;
73    }
74
75    /**
76     * @return hibernate configuration
77     * @jmx.managed-attribute
78     * access="read-write"
79     */

80    public HibernateConfig getHibernateConfig()
81    {
82       return m_hibernateConfig;
83    }
84
85    /**
86     * @param hbConfig a hibernate configuration
87     * @jmx.managed-attribute
88     * access="read-write"
89     */

90    public void setHibernateConfig(HibernateConfig hbConfig)
91    {
92       m_hibernateConfig = (HibernateConfig)hbConfig.getConfiguration();
93    }
94
95
96    /**
97     * @return DataLoader action type : suppoprted types are JDBC, CMS, Hibernate
98     *
99     *
100     * @jmx.managed-attribute
101     * access="read-only"
102     */

103
104    public String JavaDoc getActionType()
105    {
106       return "Hibernate";
107    }
108
109
110 }
111
Popular Tags