Example usage for java.lang.reflect Member PUBLIC

List of usage examples for java.lang.reflect Member PUBLIC

Introduction

In this page you can find the example usage for java.lang.reflect Member PUBLIC.

Prototype

int PUBLIC

To view the source code for java.lang.reflect Member PUBLIC.

Click Source Link

Document

Identifies the set of all public members of a class or interface, including inherited members.

Usage

From source file:Main.java

public static void main(String[] args) {
    System.setProperty("java.security.policy", "file:/C:/java.policy");

    SecurityManager sm = new Main();

    System.setSecurityManager(sm);

    sm.checkMemberAccess(Main.class, Member.PUBLIC);

    System.out.println("Allowed!");
}