1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.acegisecurity;
17
18 import java.io.Serializable;
19
20
21 /***
22 * Stores a security system related configuration attribute.
23 *
24 * <p>
25 * When an {@link org.acegisecurity.intercept.AbstractSecurityInterceptor}
26 * is setup, a list of configuration attributes is defined for secure object
27 * patterns. These configuration attributes have special meaning to a {@link
28 * RunAsManager}, {@link AccessDecisionManager} or
29 * <code>AccessDecisionManager</code> delegate.
30 * </p>
31 *
32 * <P>
33 * Stored at runtime with other <code>ConfigAttribute</code>s for the same
34 * secure object target within a {@link ConfigAttributeDefinition}.
35 * </p>
36 *
37 * @author Ben Alex
38 * @version $Id: ConfigAttribute.java,v 1.6 2005/11/17 00:55:49 benalex Exp $
39 */
40 public interface ConfigAttribute extends Serializable {
41
42
43 /***
44 * If the <code>ConfigAttribute</code> can be represented as a
45 * <code>String</code> and that <code>String</code> is sufficient in
46 * precision to be relied upon as a configuration parameter by a {@link
47 * RunAsManager}, {@link AccessDecisionManager} or
48 * <code>AccessDecisionManager</code> delegate, this method should return
49 * such a <code>String</code>.
50 *
51 * <p>
52 * If the <code>ConfigAttribute</code> cannot be expressed with sufficient
53 * precision as a <code>String</code>, <code>null</code> should be
54 * returned. Returning <code>null</code> will require any relying classes
55 * to specifically support the <code>ConfigAttribute</code>
56 * implementation, so returning <code>null</code> should be avoided
57 * unless actually required.
58 * </p>
59 *
60 * @return a representation of the configuration attribute (or
61 * <code>null</code> if the configuration attribute cannot be
62 * expressed as a <code>String</code> with sufficient precision).
63 */
64 public String getAttribute();
65 }