ClassLoader
with additional support for defining
classes with an associated code source and permissions which are
retrieved by the system policy by default.
Modifier and Type | Class and Description |
---|---|
private static record | |
private static class |
Modifier and Type | Field and Description |
---|---|
private final Map |
Access | Constructor and Description |
---|---|
protected | SecureClassLoader(ClassLoader
the parent ClassLoader parent)Creates a new |
protected | SecureClassLoader()
Creates a new |
protected | SecureClassLoader(String
class loader name; or name, ClassLoader null if not namedthe parent class loader parent)Creates a new |
Modifier and Type | Method and Description |
---|---|
protected final Class | Returns: theClass object created from the data,
and optional CodeSource.the expected name of the class, or name, byte[] null
if not known, using '.' and not '/' as the separator
and without a trailing ".class" suffix.the bytes that make up the class data. The bytes in
positions b, int off through off+len-1
should have the format of a valid class file as defined by
The Java Virtual Machine Specification.the start offset in off, int b of the class datathe length of the class data len, CodeSource the associated CodeSource, or cs)null if noneConverts an array of bytes into an instance of class |
protected final Class | Returns: theClass object created from the data,
and optional CodeSource.the expected name of the class, or name, ByteBuffer null
if not known, using '.' and not '/' as the separator
and without a trailing ".class" suffix.the bytes that make up the class data. The bytes from positions
b, CodeSource b.position() through b.position() + b.limit() -1
should have the format of a valid class file as defined by
The Java Virtual Machine Specification.the associated CodeSource, or cs)null if noneConverts a |
protected PermissionCollection | Returns: the permissions granted to the codesource.the codesource. codesource)Returns the permissions for the given CodeSource object. |
private ProtectionDomain | |
private void | resetArchivedStates()
Hides java. Called by the VM, during -Xshare:dump |
pdcache | back to summary |
---|---|
private final Map<SecureClassLoader. |
SecureClassLoader | back to summary |
---|---|
protected SecureClassLoader(ClassLoader parent) Creates a new If there is a security manager, this method first
calls the security manager's
|
SecureClassLoader | back to summary |
---|---|
protected SecureClassLoader() Creates a new If there is a security manager, this method first
calls the security manager's
|
SecureClassLoader | back to summary |
---|---|
protected SecureClassLoader(String name, ClassLoader parent) Creates a new
|
defineClass | back to summary |
---|---|
protected final Class Converts an array of bytes into an instance of class If a non-null CodeSource is supplied a ProtectionDomain is constructed and associated with the class being defined.
|
defineClass | back to summary |
---|---|
protected final Class Converts a If a non-null CodeSource is supplied a ProtectionDomain is constructed and associated with the class being defined.
|
getPermissions | back to summary |
---|---|
protected PermissionCollection getPermissions(CodeSource codesource) Returns the permissions for the given CodeSource object. This method is invoked by the defineClass method which takes a CodeSource as an argument when it is constructing the ProtectionDomain for the class being defined.
|
getProtectionDomain | back to summary |
---|---|
private ProtectionDomain getProtectionDomain(CodeSource cs) |
resetArchivedStates | back to summary |
---|---|
private void resetArchivedStates() Hides java. Called by the VM, during -Xshare:dump |
Modifier and Type | Field and Description |
---|---|
private final CodeSource |
Access | Constructor and Description |
---|---|
private |
Modifier and Type | Method and Description |
---|---|
public CodeSource | |
public boolean | equals(Object
the reference object with which to compare. obj)Implements abstract java. Indicates whether some other object is "equal to" this one. |
public int | |
public final String | toString()
Implements abstract java. Returns a string representation of the record. |
cs | back to summary |
---|---|
private final CodeSource cs Record Component accessed by cs(). |
CodeSourceKey | back to summary |
---|---|
private CodeSourceKey(CodeSource cs) |
cs | back to summary |
---|---|
public CodeSource cs() Record Component getter of cs. |
equals | back to summary |
---|---|
public boolean equals(Object obj) Implements abstract java. Doc from java. Indicates whether some other object is "equal to" this one. In addition
to the general contract of R copy = new R(r.c1(), r.c2(), ..., r.cn());then it must be the case that r.equals(copy) .
|
hashCode | back to summary |
---|---|
public int hashCode() Implements abstract java. Doc from java. Returns a hash code value for the record.
Obeys the general contract of
|
toString | back to summary |
---|---|
public final String toString() Implements abstract java. Doc from java. Returns a string representation of the record.
In accordance with the general contract of In addition to this general contract, record classes must further participate in the invariant that any two records which are equal must produce equal strings. This invariant is necessarily relaxed in the rare case where corresponding equal component values might fail to produce equal strings for themselves.
|
Access | Constructor and Description |
---|---|
private |
debug | back to summary |
---|---|
private static final Debug debug |
DebugHolder | back to summary |
---|---|
private DebugHolder() |