KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > javax > xml > bind > GetPropertyAction


1 package javax.xml.bind;
2
3 import java.security.PrivilegedAction JavaDoc;
4
5 /**
6  * {@link PrivilegedAction} that gets the system property value.
7  * @author Kohsuke Kawaguchi
8  */

9 final class GetPropertyAction implements PrivilegedAction JavaDoc<String JavaDoc> {
10     private final String JavaDoc propertyName;
11
12     public GetPropertyAction(String JavaDoc propertyName) {
13         this.propertyName = propertyName;
14     }
15
16     public String JavaDoc run() {
17         return System.getProperty(propertyName);
18     }
19 }
20
Popular Tags