home *** CD-ROM | disk | FTP | other *** search
Java Source | 1998-03-20 | 2.0 KB | 69 lines |
- /*
- * @(#)ReflectPermission.java 1.7 98/03/18
- *
- * Copyright 1997 by Sun Microsystems, Inc.,
- * 901 San Antonio Road, Palo Alto, California, 94303, U.S.A.
- * All rights reserved.
- *
- * This software is the confidential and proprietary information
- * of Sun Microsystems, Inc. ("Confidential Information"). You
- * shall not disclose such Confidential Information and shall use
- * it only in accordance with the terms of the license agreement
- * you entered into with Sun.
- */
-
- package java.lang.reflect;
-
- /**
- * The Permission class for reflective operations. A
- * ReflectPermission is a <em>named permission</em> and has no
- * actions. The only name currently defined is <tt>access</tt>,
- * which allows suppressing the standard Java language access checks
- * --for public, default (package) access, protected, and private
- * members--performed by reflected objects at their point of use.
- *
- * <p>An example of permitting the identity "Duke" to suppress the
- * language access checking for reflected members might be:
- * <code>
- * grant signedBy "Duke" {
- * java.lang.reflect.ReflectPermission "access";
- * }
- * </code>
- *
- * @see java.security.Permission
- * @see java.security.BasicPermission
- * @see AccessibleObject
- * @see Field#get
- * @see Field#set
- * @see Method#invoke
- * @see Constructor#newInstance
- *
- * @since JDK1.2
- */
- public final
- class ReflectPermission extends java.security.BasicPermission {
-
- /**
- * Constructs a ReflectPermission with the specified name.
- *
- * @param name the name of the ReflectPermission
- */
- public ReflectPermission(String name) {
- super(name);
- }
-
- /**
- * Constructs a ReflectPermission with the specified name and actions.
- * The actions should be null; they are ignored. This
- * constructor exists for use by the <code>Policy</code> object
- * to instantiate new Permission objects.
- *
- * @param name the name of the ReflectPermission
- * @param actions should be null.
- */
- public ReflectPermission(String name, String actions) {
- super(name, actions);
- }
-
- }
-