corda/classpath/java/lang/reflect/Modifier.java
Joel Dice 87b02eb949 update copyright years
Previously, I used a shell script to extract modification date ranges
from the Git history, but that was complicated and unreliable, so now
every file just gets the same year range in its copyright header.  If
someone needs to know when a specific file was modified and by whom,
they can look at the Git history themselves; no need to include it
redundantly in the header.
2013-07-02 20:52:38 -06:00

40 lines
1.7 KiB
Java

/* Copyright (c) 2008-2013, Avian Contributors
Permission to use, copy, modify, and/or distribute this software
for any purpose with or without fee is hereby granted, provided
that the above copyright notice and this permission notice appear
in all copies.
There is NO WARRANTY for this software. See license.txt for
details. */
package java.lang.reflect;
public final class Modifier {
public static final int PUBLIC = 1 << 0;
public static final int PRIVATE = 1 << 1;
public static final int PROTECTED = 1 << 2;
public static final int STATIC = 1 << 3;
public static final int FINAL = 1 << 4;
public static final int SUPER = 1 << 5;
public static final int SYNCHRONIZED = SUPER;
public static final int VOLATILE = 1 << 6;
public static final int TRANSIENT = 1 << 7;
public static final int NATIVE = 1 << 8;
public static final int INTERFACE = 1 << 9;
public static final int ABSTRACT = 1 << 10;
public static final int STRICT = 1 << 11;
private Modifier() { }
public static boolean isPublic (int v) { return (v & PUBLIC) != 0; }
public static boolean isPrivate (int v) { return (v & PRIVATE) != 0; }
public static boolean isProtected(int v) { return (v & PROTECTED) != 0; }
public static boolean isStatic (int v) { return (v & STATIC) != 0; }
public static boolean isFinal (int v) { return (v & FINAL) != 0; }
public static boolean isSuper (int v) { return (v & SUPER) != 0; }
public static boolean isNative (int v) { return (v & NATIVE) != 0; }
public static boolean isAbstract (int v) { return (v & ABSTRACT) != 0; }
public static boolean isInterface(int v) { return (v & INTERFACE) != 0; }
}