KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > slide > webdav > util > resourcekind > ResourceKind


1 /*
2  * $Header: /home/cvs/jakarta-slide/src/webdav/server/org/apache/slide/webdav/util/resourcekind/ResourceKind.java,v 1.7 2004/08/05 14:43:32 dflorey Exp $
3  * $Revision: 1.7 $
4  * $Date: 2004/08/05 14:43:32 $
5  *
6  * ====================================================================
7  *
8  * Copyright 1999-2002 The Apache Software Foundation
9  *
10  * Licensed under the Apache License, Version 2.0 (the "License");
11  * you may not use this file except in compliance with the License.
12  * You may obtain a copy of the License at
13  *
14  * http://www.apache.org/licenses/LICENSE-2.0
15  *
16  * Unless required by applicable law or agreed to in writing, software
17  * distributed under the License is distributed on an "AS IS" BASIS,
18  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19  * See the License for the specific language governing permissions and
20  * limitations under the License.
21  *
22  */

23
24 package org.apache.slide.webdav.util.resourcekind;
25
26 import java.util.Set JavaDoc;
27
28
29 /**
30  * Abstraction of a WebDAV-compliant resource kind.
31  */

32 public interface ResourceKind {
33     
34     /**
35      * Get the set live properties supported by this resource kind.
36      */

37     Set JavaDoc getSupportedLiveProperties();
38     
39     /**
40      * Get the set live properties supported by this resource kind.
41      * @param filter Q_PROTECTED_ONLY or Q_COMPUTED_ONLY (no filtering if null)
42      * @see org.apache.slide.webdav.util.WebdavConstants
43      * @see org.apache.slide.webdav.util.DeltavConstants
44      * @see org.apache.slide.webdav.util.AclConstants
45      * @see org.apache.slide.webdav.util.DaslConstants
46      */

47     Set JavaDoc getSupportedLiveProperties( String JavaDoc filter );
48     
49     /**
50      * Get the set live properties supported by this resource kind.
51      * @param excludedFeatures array of F_* constants (no filtering if null or empty)
52      * @see org.apache.slide.webdav.util.WebdavConstants
53      * @see org.apache.slide.webdav.util.DeltavConstants
54      * @see org.apache.slide.webdav.util.AclConstants
55      * @see org.apache.slide.webdav.util.DaslConstants
56      */

57     Set JavaDoc getSupportedLiveProperties( String JavaDoc[] excludedFeatures );
58     
59     /**
60      * Get the set live properties supported by this resource kind.
61      * @param filter Q_PROTECTED_ONLY or Q_COMPUTED_ONLY (no filtering if null)
62      * @param excludedFeatures array of F_* constants (no filtering if null or empty)
63      * @see org.apache.slide.webdav.util.WebdavConstants
64      * @see org.apache.slide.webdav.util.DeltavConstants
65      * @see org.apache.slide.webdav.util.AclConstants
66      * @see org.apache.slide.webdav.util.DaslConstants
67      */

68     Set JavaDoc getSupportedLiveProperties( String JavaDoc filter, String JavaDoc[] excludedFeatures );
69     
70     /**
71      * Get the set methods supported by this resource kind.
72      */

73     Set JavaDoc getSupportedMethods();
74     
75     /**
76      * Return true, if the specified property is supported by this resource kind.
77      */

78     public boolean isSupportedLiveProperty( String JavaDoc prop );
79     
80     /**
81      * Return true, if the specified method is supported by this resource kind.
82      */

83     boolean isSupportedMethod( String JavaDoc method );
84     
85     /**
86      * Get the set reports supported by this resource kind.
87      */

88     Set JavaDoc getSupportedReports();
89     
90     /**
91      * Some properties (e.g. <code>&lt;auto-version&gt;</code>) have a
92      * restricted set of supported values.
93      * If the value set of the given <code>property</code> is restricted and
94      * the given <code>value</code> is not contained in that set, this method
95      * returns <code>false</code>, otherwise <code>true</code>.
96      *
97      * @param propertyName the name of the property.
98      * @param value the value to check.
99      *
100      * @return <code>false</code> if the value is not allowed, otherwise
101      * <code>true</code>.
102      */

103     boolean isSupportedPropertyValue(String JavaDoc propertyName, Object JavaDoc value);
104     
105 }
106
107
Popular Tags