fixed some formatting typos
[vimdoclet.git] / sample / java.util.PropertyPermission.txt
blobc6bbb8aa6c795cd047bc116fb5ad4a96da868297
1 *java.util.PropertyPermission* *PropertyPermission* This class is for property p
3 public final class PropertyPermission
4   extends    |java.security.BasicPermission|
6 |java.util.PropertyPermission_Description|
7 |java.util.PropertyPermission_Fields|
8 |java.util.PropertyPermission_Constructors|
9 |java.util.PropertyPermission_Methods|
11 ================================================================================
13 *java.util.PropertyPermission_Constructors*
14 |java.util.PropertyPermission(String,String)|Creates a new PropertyPermission o
16 *java.util.PropertyPermission_Methods*
17 |java.util.PropertyPermission.equals(Object)|Checks two PropertyPermission obje
18 |java.util.PropertyPermission.getActions()|Returns the "canonical string repres
19 |java.util.PropertyPermission.hashCode()|Returns the hash code value for this o
20 |java.util.PropertyPermission.implies(Permission)|Checks if this PropertyPermis
21 |java.util.PropertyPermission.newPermissionCollection()|Returns a new Permissio
23 *java.util.PropertyPermission_Description*
25 This class is for property permissions. 
27 The name is the name of the property ("java.home", "os.name", etc). The naming 
28 convention follows the hierarchical property naming convention. Also, an 
29 asterisk may appear at the end of the name, following a ".", or by itself, to 
30 signify a wildcard match. For example: "java.*" or "*" is valid, "*java" or 
31 "a*b" is not valid. 
33 The actions to be granted are passed to the constructor in a string containing 
34 a list of zero or more comma-separated keywords. The possible keywords are 
35 "read" and "write". Their meaning is defined as follows: 
37 read read permission. Allows System.getProperty to be called. write write 
38 permission. Allows System.setProperty to be called. 
40 The actions string is converted to lowercase before processing. 
42 Care should be taken before granting code permission to access certain system 
43 properties. For example, granting permission to access the "java.home" system 
44 property gives potentially malevolent code sensitive information about the 
45 system environment (the Java installation directory). Also, granting permission 
46 to access the "user.name" and "user.home" system properties gives potentially 
47 malevolent code sensitive information about the user environment (the user's 
48 account name and home directory). 
52 *java.util.PropertyPermission(String,String)*
54 public PropertyPermission(
55   java.lang.String name,
56   java.lang.String actions)
58 Creates a new PropertyPermission object with the specified name. The name is 
59 the name of the system property, and actions contains a comma-separated list of 
60 the desired actions granted on the property. Possible actions are "read" and 
61 "write". 
63     name - the name of the PropertyPermission. 
64     actions - the actions string. 
66 *java.util.PropertyPermission.equals(Object)*
68 public boolean equals(java.lang.Object obj)
70 Checks two PropertyPermission objects for equality. Checks that obj is a 
71 PropertyPermission, and has the same name and actions as this object. 
74     obj - the object we are testing for equality with this object. 
76     Returns: true if obj is a PropertyPermission, and has the same name and actions as this 
77              PropertyPermission object. 
79 *java.util.PropertyPermission.getActions()*
81 public |java.lang.String| getActions()
83 Returns the "canonical string representation" of the actions. That is, this 
84 method always returns present actions in the following order: read, write. For 
85 example, if this PropertyPermission object allows both write and read actions, 
86 a call to getActions will return the string "read,write". 
90     Returns: the canonical string representation of the actions. 
92 *java.util.PropertyPermission.hashCode()*
94 public int hashCode()
96 Returns the hash code value for this object. The hash code used is the hash 
97 code of this permissions name, that is, getName().hashCode(), where getName is 
98 from the Permission superclass. 
102     Returns: a hash code value for this object. 
104 *java.util.PropertyPermission.implies(Permission)*
106 public boolean implies(java.security.Permission p)
108 Checks if this PropertyPermission object "implies" the specified permission. 
110 More specifically, this method returns true if: 
112 p is an instanceof PropertyPermission, p's actions are a subset of this 
113 object's actions, and p's name is implied by this object's name. For example, 
114 "java.*" implies "java.home". 
117     p - the permission to check against. 
119     Returns: true if the specified permission is implied by this object, false if not. 
121 *java.util.PropertyPermission.newPermissionCollection()*
123 public |java.security.PermissionCollection| newPermissionCollection()
125 Returns a new PermissionCollection object for storing PropertyPermission 
126 objects. 
130     Returns: a new PermissionCollection object suitable for storing PropertyPermissions.