head	1.15;
access;
symbols
	TIGRIS_0_9_2_4:1.10
	TIGRIS_0_9_2_3:1.10
	HELM_PEER_PORT_BRANCH:1.14.0.2
	TURBINE_PEER:1.14
	TIGRIS_0_9_2_1:1.14
	TIGRIS_0_9_2:1.10.0.2
	TIGRIS_0_9_0:1.7.0.2
	TIGRIS_0_8_4:1.5.0.2
	NEWHELM:1.1.1.1
	TIGRIS_NOV_12_2000:1.1.1;
locks; strict;
comment	@# @;


1.15
date	2001.02.21.03.23.56;	author edk;	state dead;
branches;
next	1.14;

1.14
date	2001.01.26.18.29.02;	author edk;	state Exp;
branches
	1.14.2.1;
next	1.13;

1.13
date	2001.01.26.05.24.05;	author edk;	state dead;
branches;
next	1.12;

1.12
date	2001.01.24.23.16.02;	author leonardr;	state Exp;
branches;
next	1.11;

1.11
date	2001.01.24.20.42.48;	author dlr;	state Exp;
branches;
next	1.10;

1.10
date	2001.01.03.22.09.21;	author leonardr;	state Exp;
branches;
next	1.9;

1.9
date	2000.12.23.00.48.18;	author dlr;	state Exp;
branches;
next	1.8;

1.8
date	2000.12.22.03.02.59;	author dlr;	state Exp;
branches;
next	1.7;

1.7
date	2000.12.18.19.51.45;	author leonardr;	state Exp;
branches;
next	1.6;

1.6
date	2000.12.05.23.28.58;	author leonardr;	state Exp;
branches;
next	1.5;

1.5
date	2000.11.29.19.59.33;	author leonardr;	state Exp;
branches;
next	1.4;

1.4
date	2000.11.20.21.43.16;	author leonardr;	state Exp;
branches;
next	1.3;

1.3
date	2000.11.20.20.33.30;	author dlr;	state Exp;
branches;
next	1.2;

1.2
date	2000.11.20.20.07.32;	author leonardr;	state Exp;
branches;
next	1.1;

1.1
date	2000.11.12.21.15.18;	author dlr;	state Exp;
branches
	1.1.1.1;
next	;

1.1.1.1
date	2000.11.12.21.15.18;	author dlr;	state Exp;
branches;
next	;

1.14.2.1
date	2001.01.28.01.02.17;	author dlr;	state dead;
branches;
next	;


desc
@@


1.15
log
@delete stuff from the head which is obsolete in the branch (more changes
are still needed for a clean compile)
@
text
@/* ================================================================
 * Copyright (c) 2000 CollabNet.  All rights reserved.
 * 
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are
 * met:
 * 
 * 1. Redistributions of source code must retain the above copyright
 * notice, this list of conditions and the following disclaimer.
 * 
 * 2. Redistributions in binary form must reproduce the above copyright
 * notice, this list of conditions and the following disclaimer in the
 * documentation and/or other materials provided with the distribution.
 * 
 * 3. The end-user documentation included with the redistribution, if
 * any, must include the following acknowlegement: "This product includes
 * software developed by Collab.Net (http://www.Collab.Net/)."
 * Alternately, this acknowlegement may appear in the software itself, if
 * and wherever such third-party acknowlegements normally appear.
 * 
 * 4. The hosted project names must not be used to endorse or promote
 * products derived from this software without prior written
 * permission. For written permission, please contact info@@collab.net.
 * 
 * 5. Products derived from this software may not use the "Tigris" name
 * nor may "Tigris" appear in their names without prior written
 * permission of Collab.Net.
 * 
 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
 * IN NO EVENT SHALL COLLAB.NET OR ITS CONTRIBUTORS BE LIABLE FOR ANY
 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
 * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
 * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 *
 * ====================================================================
 * 
 * This software consists of voluntary contributions made by many
 * individuals on behalf of CollabNet.
 */

package org.tigris.helm.domain;

import java.util.*;
import java.sql.*;

import org.webmacro.util.*;

import com.workingdogs.village.*;

import org.joist.database.JoistDatabaseException;
import org.joist.database.DataManager;

import org.tigris.helm.*;
import org.tigris.helm.security.AccessControlList;
import org.tigris.helm.security.ACLException;
import org.tigris.helm.database.*;
import org.tigris.helm.project.Project;

public class Category extends ProjectGroup
{
    private static Log log = new Log("ctgry", "Category");

    public Category(Connection c, DataManager dMgr, Record r)
        throws DoesNotExist, DataSetException
    {
        super(c, dMgr, r);
    }
    
    public Category(Connection c, DataManager dMgr, String catID)
        throws DataSetException, SQLException, JoistDatabaseException,
               DoesNotExist, ACLException
    {
        super(c, dMgr, catID);
    }

    public Category(Connection c, DataManager dMgr, AccessControlList acl,
                    String domainID, String name, String shortDescription,
                    String longDescription)
        throws DataSetException, SQLException, JoistDatabaseException,
               DoesNotExist, AlreadyExists, ACLException
    {
        super(c, dMgr, acl, domainID, true, name, shortDescription, 
              longDescription);
    }    

    public void addProject(Project p)
        throws SQLException, DataSetException, JoistDatabaseException,
               DoesNotExist
    {
        addProjectNoPerms(p);
    }

    public void removeProject(Project p)
        throws SQLException, DataSetException, JoistDatabaseException,
               DoesNotExist
    {
        removeProjectNoPerms(p);
    }

}
@


1.14
log
@readding all the files as part of the process of returning to the way
things were as of tuesday
@
text
@@


1.14.2.1
log
@Porting to the Turbine Peer system.  -dlr and leonardr
@
text
@@


1.13
log
@revert this stuff to its state as of 2001/01/24 12:42:00 GMT -- with
the following exceptions, which have some different modifications so
they'll work with changes which have happened in joist:

ProjectNewsEdit.java
SkinManager.java
SkinStyleElementValueManager.java
StyleElementManager.java
StyleManager.java

it compiles.  i dunno if it works, though.
@
text
@d69 2
a70 2
    public Category(DataManager dMgr, Record r)
        throws DoesNotExist, DBException
d72 1
a72 1
        super(dMgr, r);
d75 3
a77 2
    public Category(DataManager dMgr, String catID)
        throws ACLException, DoesNotExist, DBException
d79 1
a79 1
        super(dMgr, catID);
d82 1
a82 1
    public Category(DataManager dMgr, AccessControlList acl,
d85 2
a86 1
        throws ACLException, AlreadyExists, DoesNotExist, DBException
d88 1
a88 1
        super(dMgr, acl, domainID, true, name, shortDescription, 
d93 2
a94 1
        throws DoesNotExist, DBException
d100 2
a101 1
        throws DoesNotExist, DBException
d105 1
@


1.12
log
@* Removed all references to JDBC connections.  Connections are now pulled
  directly from the connection pool.
* Made use of DBException.
- dlr@@collab.net
@
text
@@


1.11
log
@Making use of DBException.
@
text
@d69 2
a70 2
    public Category(Connection c, DataManager dMgr, Record r)
        throws DoesNotExist, DataSetException
d72 1
a72 1
        super(c, dMgr, r);
d75 2
a76 3
    public Category(Connection c, DataManager dMgr, String catID)
        throws DataSetException, SQLException, JoistDatabaseException,
               DoesNotExist, ACLException
d78 1
a78 1
        super(c, dMgr, catID);
d81 1
a81 1
    public Category(Connection c, DataManager dMgr, AccessControlList acl,
d86 1
a86 1
        super(c, dMgr, acl, domainID, true, name, shortDescription, 
@


1.10
log
@Categories can now be created through the ProjectGroup interface.
@
text
@d85 1
a85 2
        throws DataSetException, SQLException, JoistDatabaseException,
               DoesNotExist, AlreadyExists, ACLException
d92 1
a92 2
        throws SQLException, DataSetException, JoistDatabaseException,
               DoesNotExist
d98 1
a98 2
        throws SQLException, DataSetException, JoistDatabaseException,
               DoesNotExist
a101 1

@


1.9
log
@Removed unnecessary getCache() implementations in BusinessObject subclasses and migrated to a factory method for User's primary database key ctor.
@
text
@d88 2
a89 1
        super(c, dMgr, acl, domainID, name, shortDescription, longDescription);
@


1.8
log
@Propogated object cache interface.
@
text
@a90 5
    protected Dictionary getCache ()
    {
        return null;
    }

@


1.7
log
@Changed constructor to take long description.
@
text
@d91 4
@


1.6
log
@Added a check so that business objects cannot be created with records from the wrong table. Also added some new business objects.
@
text
@d83 2
a84 1
                    String domainID, String name, String description)
d88 1
a88 1
        super(c, dMgr, acl, domainID, name, description);
@


1.5
log
@All project group activity now goes through the ProjectGroup object.
@
text
@d70 1
a70 1
        throws DoesNotExist
@


1.4
log
@Added user group business object.
@
text
@d89 16
@


1.3
log
@Corrected build errors.
@
text
@a63 1
import org.tigris.helm.tool.AccessControlledDatabaseFilter;
d76 2
a77 1
        throws DataSetException, SQLException, DoesNotExist
d84 2
a85 2
        throws DataSetException, SQLException, DoesNotExist, ACLException,
               JoistDatabaseException, AlreadyExists
@


1.2
log
@Initial run at ProjectGroup business object.
@
text
@d59 1
a59 1
import org.tigris.helm.DoesNotExist;
d61 1
d84 2
a85 1
        throws DataSetException, SQLException, DoesNotExist, ACLException
@


1.1
log
@Initial revision
@
text
@d65 1
a65 1
public class Category extends Project
a79 6
    
    public List getProjects(AccessControlList acl)
        throws DataSetException, SQLException, JoistDatabaseException,
               DoesNotExist
    {
        ArrayList projects = new ArrayList();
d81 3
a83 8
        DataSet projectSet = pMgr.getProjectsForCategory(conn, getID());
        return AccessControlledDatabaseFilter.getViewableProjects
            (conn, dMgr, acl, projectSet);
    }

    public int getNumberOfProjects(AccessControlList acl)
        throws DataSetException, SQLException, JoistDatabaseException,
               DoesNotExist
d85 2
a86 4
        DataSet projectSet = pMgr.getProjectsForCategory(conn, getID());
        return AccessControlledDatabaseFilter.getViewableProjects
            (conn, dMgr, acl, projectSet).size();
    }
@


1.1.1.1
log
@Merging newhelm tree into helm, as per IZ issue #557.  Previous major version of helm is tagged TIGRIS_NOV_11_2000.
@
text
@@
