2
|
1 |
/*
|
45564
|
2 |
* Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved.
|
2
|
3 |
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
4 |
*
|
|
5 |
* This code is free software; you can redistribute it and/or modify it
|
|
6 |
* under the terms of the GNU General Public License version 2 only, as
|
5506
|
7 |
* published by the Free Software Foundation. Oracle designates this
|
2
|
8 |
* particular file as subject to the "Classpath" exception as provided
|
5506
|
9 |
* by Oracle in the LICENSE file that accompanied this code.
|
2
|
10 |
*
|
|
11 |
* This code is distributed in the hope that it will be useful, but WITHOUT
|
|
12 |
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
13 |
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
|
14 |
* version 2 for more details (a copy is included in the LICENSE file that
|
|
15 |
* accompanied this code).
|
|
16 |
*
|
|
17 |
* You should have received a copy of the GNU General Public License version
|
|
18 |
* 2 along with this work; if not, write to the Free Software Foundation,
|
|
19 |
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
|
20 |
*
|
5506
|
21 |
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
|
22 |
* or visit www.oracle.com if you need additional information or have any
|
|
23 |
* questions.
|
2
|
24 |
*/
|
|
25 |
|
|
26 |
package com.sun.jdi.event;
|
|
27 |
|
45564
|
28 |
import com.sun.jdi.ReferenceType;
|
|
29 |
import com.sun.jdi.ThreadReference;
|
|
30 |
import com.sun.jdi.VirtualMachine;
|
|
31 |
import com.sun.jdi.request.EventRequest;
|
2
|
32 |
|
|
33 |
/**
|
|
34 |
* Notification of a class prepare in the target VM. See the JVM
|
|
35 |
* specification for a definition of class preparation. Class prepare
|
45564
|
36 |
* events are not generated for primitive classes (for example,
|
2
|
37 |
* java.lang.Integer.TYPE).
|
|
38 |
*
|
|
39 |
* @see EventQueue
|
|
40 |
* @see VirtualMachine
|
|
41 |
*
|
|
42 |
* @author Robert Field
|
|
43 |
* @since 1.3
|
|
44 |
*/
|
|
45 |
public interface ClassPrepareEvent extends Event {
|
45564
|
46 |
|
2
|
47 |
/**
|
|
48 |
* Returns the thread in which this event has occurred.
|
|
49 |
* <p>
|
|
50 |
* In rare cases, this event may occur in a debugger system
|
|
51 |
* thread within the target VM. Debugger threads take precautions
|
|
52 |
* to prevent these events, but they cannot be avoided under some
|
|
53 |
* conditions, especially for some subclasses of
|
|
54 |
* {@link java.lang.Error}.
|
|
55 |
* If the event was generated by a debugger system thread, the
|
|
56 |
* value returned by this method is null, and if the requested
|
|
57 |
* suspend policy for the event was
|
45564
|
58 |
* {@link EventRequest#SUSPEND_EVENT_THREAD},
|
2
|
59 |
* all threads will be suspended instead, and the
|
|
60 |
* {@link EventSet#suspendPolicy} will reflect this change.
|
|
61 |
* <p>
|
|
62 |
* Note that the discussion above does not apply to system threads
|
|
63 |
* created by the target VM during its normal (non-debug) operation.
|
|
64 |
*
|
|
65 |
* @return a {@link ThreadReference} which mirrors the event's thread in
|
|
66 |
* the target VM, or null in the rare cases described above.
|
|
67 |
*/
|
|
68 |
public ThreadReference thread();
|
|
69 |
|
|
70 |
/**
|
|
71 |
* Returns the reference type for which this event was generated.
|
|
72 |
*
|
|
73 |
* @return a {@link ReferenceType} which mirrors the class, interface, or
|
|
74 |
* array which has been linked.
|
|
75 |
*/
|
|
76 |
public ReferenceType referenceType();
|
|
77 |
}
|