Microsoft SDK for Java

check

This method of the ThreadPermission Class determines whether the specified threading object can be manipulated.

Syntax

public void check(Object param)throws SecurityException;

Parameters

param The security request parameter. It must be an instance of Thread or ThreadGroup.

Remarks

If the specified Object is a Thread, the check takes place as follows:

  1. If the permission allows unrestricted thread access, the check succeeds.

  2. If the Thread exists within the ThreadGroup object associated with this permission or within one of its children, the check succeeds. Otherwise, it fails.

If the specified Object is a ThreadGroup, the check takes place as follows:

  1. If the permission allows unrestricted thread group access, the check succeeds.

  2. If the ThreadGroup is the ThreadGroup object associated with this permission or one of its children, the check succeeds. Otherwise, it fails.

Exceptions

SecurityException if the permission does not allow access to the specified threading object.

© 1999 Microsoft Corporation. All rights reserved. Terms of use.