|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.jrockit.mc.flightrecorder.FlightRecording
public final class FlightRecording
The main class for accessing flight recorder events.
See code snippet below for how to open up a recording file and print the start time and the event type of all events using the default file provider.FlightRecording recording = FlightRecording.createFromFile(new File("recording.jfr")); for (IEvent event : recording) { System.out.println(new Date(event.getStartTimestamp() / (1000 * 1000)) + " " + event.getEventType().getName()); }
Constructor Summary | |
---|---|
FlightRecording()
Creates an empty flight recording. |
|
FlightRecording(Provider provider)
Create a flight recording using a provider class as back-end. |
Method Summary | |
---|---|
static FlightRecording |
createFromFile(java.io.File file)
Creates a flight recording using the default file provider. |
IView |
createView()
Returns a view of the recording data. |
java.util.Collection<IEventType> |
getEventTypes()
Returns the event types for all the producers in the repository. |
java.util.Collection<IProducer> |
getProducers()
Return the producers in the recording. |
ITrackGroup |
getRootGroup()
Returns the top node for all tracks. |
ITimeRange |
getTimeRange()
Returns the time range the recording spans. |
java.util.Iterator<IEvent> |
iterator()
Returns an iterator over all the events available in the recording. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FlightRecording()
createFromFile(File)
for how to create a recording from a
file.
public FlightRecording(Provider provider)
createFromFile(File)
for how to create from a file using the
default file provider.
provider
- the back-end provider.Method Detail |
---|
public static FlightRecording createFromFile(java.io.File file)
file
- the recording file
public ITimeRange getTimeRange()
public IView createView()
public java.util.Iterator<IEvent> iterator()
iterator
in interface java.lang.Iterable<IEvent>
public java.util.Collection<IEventType> getEventTypes()
public java.util.Collection<IProducer> getProducers()
public ITrackGroup getRootGroup()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |