📄 securitymanager.html
字号:
calling thread is not allowed to read from the specified file descriptor.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#checkRead(java.lang.String)">checkRead</A></B>(<A HREF="../../java/lang/String.html">String</A> file)</CODE><BR> Throws a <code>SecurityException</code> if the calling thread is not allowed to read the file specified by the string argument.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#checkRead(java.lang.String, java.lang.Object)">checkRead</A></B>(<A HREF="../../java/lang/String.html">String</A> file, <A HREF="../../java/lang/Object.html">Object</A> context)</CODE><BR> Throws a <code>SecurityException</code> if the specified security context is not allowed to read the file specified by the string argument.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#checkSecurityAccess(java.lang.String)">checkSecurityAccess</A></B>(<A HREF="../../java/lang/String.html">String</A> target)</CODE><BR> Determines whether the permission with the specified permission target name should be granted or denied.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#checkSetFactory()">checkSetFactory</A></B>()</CODE><BR> Throws a <code>SecurityException</code> if the calling thread is not allowed to set the socket factory used by <code>ServerSocket</code> or <code>Socket</code>, or the stream handler factory used by <code>URL</code>.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#checkSystemClipboardAccess()">checkSystemClipboardAccess</A></B>()</CODE><BR> Throws a <code>SecurityException</code> if the calling thread is not allowed to access the system clipboard.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#checkTopLevelWindow(java.lang.Object)">checkTopLevelWindow</A></B>(<A HREF="../../java/lang/Object.html">Object</A> window)</CODE><BR> Returns <code>false</code> if the calling thread is not trusted to bring up the top-level window indicated by the <code>window</code> argument.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#checkWrite(java.io.FileDescriptor)">checkWrite</A></B>(<A HREF="../../java/io/FileDescriptor.html">FileDescriptor</A> fd)</CODE><BR> Throws a <code>SecurityException</code> if the calling thread is not allowed to write to the specified file descriptor.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#checkWrite(java.lang.String)">checkWrite</A></B>(<A HREF="../../java/lang/String.html">String</A> file)</CODE><BR> Throws a <code>SecurityException</code> if the calling thread is not allowed to write to the file specified by the string argument.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>protected int</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#classDepth(java.lang.String)">classDepth</A></B>(<A HREF="../../java/lang/String.html">String</A> name)</CODE><BR> <B>Deprecated.</B> <I>This type of security checking is not recommended. It is recommended that the <code>checkPermission</code> call be used instead.</I></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>protected int</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#classLoaderDepth()">classLoaderDepth</A></B>()</CODE><BR> <B>Deprecated.</B> <I>This type of security checking is not recommended. It is recommended that the <code>checkPermission</code> call be used instead.</I></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>protected <A HREF="../../java/lang/ClassLoader.html">ClassLoader</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#currentClassLoader()">currentClassLoader</A></B>()</CODE><BR> <B>Deprecated.</B> <I>This type of security checking is not recommended. It is recommended that the <code>checkPermission</code> call be used instead.</I></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>protected <A HREF="../../java/lang/Class.html">Class</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#currentLoadedClass()">currentLoadedClass</A></B>()</CODE><BR> <B>Deprecated.</B> <I>This type of security checking is not recommended. It is recommended that the <code>checkPermission</code> call be used instead.</I></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>protected <A HREF="../../java/lang/Class.html">Class</A>[]</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#getClassContext()">getClassContext</A></B>()</CODE><BR> Returns the current execution stack as an array of classes.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#getInCheck()">getInCheck</A></B>()</CODE><BR> <B>Deprecated.</B> <I>This type of security checking is not recommended. It is recommended that the <code>checkPermission</code> call be used instead.</I></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="../../java/lang/Object.html">Object</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#getSecurityContext()">getSecurityContext</A></B>()</CODE><BR> Creates an object that encapsulates the current execution environment.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="../../java/lang/ThreadGroup.html">ThreadGroup</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#getThreadGroup()">getThreadGroup</A></B>()</CODE><BR> Returns the thread group into which to instantiate any new thread being created at the time this is being called.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>protected boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#inClass(java.lang.String)">inClass</A></B>(<A HREF="../../java/lang/String.html">String</A> name)</CODE><BR> <B>Deprecated.</B> <I>This type of security checking is not recommended. It is recommended that the <code>checkPermission</code> call be used instead.</I></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>protected boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/lang/SecurityManager.html#inClassLoader()">inClassLoader</A></B>()</CODE><BR> <B>Deprecated.</B> <I>This type of security checking is not recommended. It is recommended that the <code>checkPermission</code> call be used instead.</I></TD></TR></TABLE> <A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from class java.lang.<A HREF="../../java/lang/Object.html">Object</A></B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><A HREF="../../java/lang/Object.html#clone()">clone</A>, <A HREF="../../java/lang/Object.html#equals(java.lang.Object)">equals</A>, <A HREF="../../java/lang/Object.html#finalize()">finalize</A>, <A HREF="../../java/lang/Object.html#getClass()">getClass</A>, <A HREF="../../java/lang/Object.html#hashCode()">hashCode</A>, <A HREF="../../java/lang/Object.html#notify()">notify</A>, <A HREF="../../java/lang/Object.html#notifyAll()">notifyAll</A>, <A HREF="../../java/lang/Object.html#toString()">toString</A>, <A HREF="../../java/lang/Object.html#wait()">wait</A>, <A HREF="../../java/lang/Object.html#wait(long)">wait</A>, <A HREF="../../java/lang/Object.html#wait(long, int)">wait</A></CODE></TD></TR></TABLE> <P><!-- ============ FIELD DETAIL =========== --><A NAME="field_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Field Detail</B></FONT></TD></TR></TABLE><A NAME="inCheck"><!-- --></A><H3>inCheck</H3><PRE>protected boolean <B>inCheck</B></PRE><DL><DD><B>Deprecated.</B> <I>This type of security checking is not recommended. It is recommended that the <code>checkPermission</code> call be used instead.</I><P><DD>This field is <code>true</code> if there is a security check in progress; <code>false</code> otherwise.</DL><!-- ========= CONSTRUCTOR DETAIL ======== --><A NAME="constructor_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Constructor Detail</B></FONT></TD></TR></TABLE><A NAME="SecurityManager()"><!-- --></A><H3>SecurityManager</H3><PRE>public <B>SecurityManager</B>()</PRE><DL><DD>Constructs a new <code>SecurityManager</code>. <p> If there is a security manager already installed, this method first calls the security manager's <code>checkPermission</code> method with the <code>RuntimePermission("createSecurityManager")</code> permission to ensure the calling thread has permission to create a new security manager. This may result in throwing a <code>SecurityException</code>.<DD><DL><DT><B>Throws:</B><DD><CODE><A HREF="../../java/lang/SecurityException.html">SecurityException</A></CODE> - if a security manager already exists and its <code>checkPermission</code> method doesn't allow creation of a new security manager.<DT><B>See Also: </B><DD><A HREF="../../java/lang/System.html#getSecurityManager()"><CODE>System.getSecurityManager()</CODE></A>, <A HREF="../../java/lang/SecurityManager.html#checkPermission(java.security.Permission)"><CODE>checkPermission</CODE></A>, <A HREF="../../java/lang/RuntimePermission.html"><CODE>RuntimePermission</CODE></A></DL></DD></DL><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Method Detail</B></FONT></TD></TR></TABLE><A NAME="getInCheck()"><!-- --></A><H3>getInCheck</H3><PRE>public boolean <B>getInCheck</B>()</PRE><DL><DD><B>Deprecated.</B> <I>This type of security checking is not recommended.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -