turbineusergrouprolemapbuilder.java

来自「jetspeed源代码」· Java 代码 · 共 79 行

JAVA
79
字号
package org.apache.jetspeed.om.security.turbine.map;import java.util.Date;import java.math.BigDecimal;import org.apache.torque.Torque;import org.apache.torque.TorqueException;import org.apache.torque.map.MapBuilder;import org.apache.torque.map.DatabaseMap;import org.apache.torque.map.TableMap;/**  *  This class was autogenerated by Torque on:  *  * [Thu Apr 22 15:30:48 PDT 2004]  *  */public class TurbineUserGroupRoleMapBuilder implements MapBuilder{    /**     * The name of this class     */    public static final String CLASS_NAME =        "org.apache.jetspeed.om.security.turbine.map.TurbineUserGroupRoleMapBuilder";    /**     * The database map.     */    private DatabaseMap dbMap = null;    /**     * Tells us if this DatabaseMapBuilder is built so that we     * don't have to re-build it every time.     *     * @return true if this DatabaseMapBuilder is built     */    public boolean isBuilt()    {        return (dbMap != null);    }    /**     * Gets the databasemap this map builder built.     *     * @return the databasemap     */    public DatabaseMap getDatabaseMap()    {        return this.dbMap;    }    /**     * The doBuild() method builds the DatabaseMap     *     * @throws TorqueException     */    public void doBuild() throws TorqueException    {        dbMap = Torque.getDatabaseMap("default");        dbMap.addTable("TURBINE_USER_GROUP_ROLE");        TableMap tMap = dbMap.getTable("TURBINE_USER_GROUP_ROLE");        tMap.setPrimaryKeyMethod("none");              tMap.addForeignPrimaryKey(                "TURBINE_USER_GROUP_ROLE.USER_ID", new Integer(0) , "TURBINE_USER" ,                "USER_ID");                    tMap.addForeignPrimaryKey(                "TURBINE_USER_GROUP_ROLE.GROUP_ID", new Integer(0) , "TURBINE_GROUP" ,                "GROUP_ID");                    tMap.addForeignPrimaryKey(                "TURBINE_USER_GROUP_ROLE.ROLE_ID", new Integer(0) , "TURBINE_ROLE" ,                "ROLE_ID");          }}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?