01: /**********************************************************************************
02: * $URL: https://source.sakaiproject.org/svn/content/tags/sakai_2-4-1/content-api/api/src/java/org/sakaiproject/content/api/ContentCollection.java $
03: * $Id: ContentCollection.java 19673 2006-12-18 19:26:26Z jimeng@umich.edu $
04: ***********************************************************************************
05: *
06: * Copyright (c) 2003, 2004, 2005, 2006 The Sakai Foundation.
07: *
08: * Licensed under the Educational Community License, Version 1.0 (the "License");
09: * you may not use this file except in compliance with the License.
10: * You may obtain a copy of the License at
11: *
12: * http://www.opensource.org/licenses/ecl1.php
13: *
14: * Unless required by applicable law or agreed to in writing, software
15: * distributed under the License is distributed on an "AS IS" BASIS,
16: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17: * See the License for the specific language governing permissions and
18: * limitations under the License.
19: *
20: **********************************************************************************/package org.sakaiproject.content.api;
21:
22: import java.util.List;
23:
24: import org.sakaiproject.content.api.ContentEntity;
25: import org.sakaiproject.content.api.GroupAwareEntity;
26: import org.sakaiproject.time.api.Time;
27:
28: /**
29: * <p>ContentCollection is the core interface for a Collection object in the GenericContentHostingService.</p>
30: * <p>A Collection has a list of internal members, each a resource id.</p>
31: *
32: * @author University of Michigan, CHEF Software Development Team
33: * @version $Revision: 19673 $
34: */
35: public interface ContentCollection extends ContentEntity {
36: /**
37: * Access a List of the collection's internal members, each a resource id String.
38: * @return a List of the collection's internal members, each a resource id String (may be empty).
39: */
40: public List getMembers();
41:
42: /**
43: * Access a List of the collections' internal members as full ContentResource or
44: * ContentCollection objects.
45: * @return a List of the full objects of the members of the collection.
46: */
47: public List getMemberResources();
48:
49: /**
50: * Access the size of all the resource body bytes within this collection in Kbytes.
51: * @return The size of all the resource body bytes within this collection in Kbytes.
52: */
53: public long getBodySizeK();
54:
55: /**
56: * Access a count of the number of members (resources and collections) within this
57: * collection. This count is not recursive. Only items whose immediate parent is
58: * the current collection are counted.
59: * @return
60: */
61: public int getMemberCount();
62:
63: /**
64: * Access the release date before which this entity should not be available to users
65: * except those with adequate permission (what defines "adequate permission" is TBD).
66: * @return The date/time at which the entity may be accessed by all users.
67: */
68: public Time getReleaseDate();
69:
70: /**
71: * Access the retract date after which this entity should not be available to users
72: * except those with adequate permission (what defines "adequate permission" is TBD).
73: * @return The date/time at which access to the entity should be restricted.
74: */
75: public Time getRetractDate();
76:
77: } // ContentCollection
|