Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » Memory Analyzer (MAT) » MAT library API(Analyze memory dump programmatically)
MAT library API [message #509680] Sun, 24 January 2010 12:31 Go to next message
No real name is currently offline No real name
Messages: 1
Registered: January 2010
Junior Member
Do the MAT libraries have a documented API? I want to dynamically generate a memory dump then parse and query the resulting dump programmatically.

I can't find any documentation on this topic.

Any help would be appreciated.
Re: MAT library API [message #509774 is a reply to message #509680] Mon, 25 January 2010 06:15 Go to previous message
Krum Tsvetkov is currently offline Krum Tsvetkov
Messages: 149
Registered: July 2009
Senior Member
A good question. Unfortunately I can't give you the best possible answer.

It's like this - at the moment we don't have any published documentation on how to develop with MAT APIs. There is also no javadoc published, although (most of) the API classes contain javadoc inside.

I would suggest that you start with our Wiki page for contributors:
http://wiki.eclipse.org/index.php?title=MemoryAnalyzer/Contr ibutor_Reference

It describes our SVN location and how to get started with getting and building the sources.

Most of the API is contained in the org.eclipse.mat.api plugin.

You may look into the following two classes as a starting point:
org.eclipse.mat.snapshot.SnapshotFactory

- this is how you can open a heap dump

org.eclipse.mat.snapshot.ISnapshot 

- this is the "central" interface, having all the methods to get to the different classes, their instances, single objects, retained sets, etc... The interface has javadoc in it.

Currently it is not possible to generate the heap dump from within the tool. There are some efforts in this direction - see bugzilla entry https://bugs.eclipse.org/bugs/show_bug.cgi?id=229449

And about using the APIs - we are in the process of getting ready for our graduation, including our 1.0 release. In this process some of the APIs may be changed. The following bugzilla entry should track such changes: https://bugs.eclipse.org/bugs/show_bug.cgi?id=299371

I'll be very interested to get your feedback on the API if you decide to give it a try. And your feedback on the tool in general - any suggestions, comments, critique ...

Let me know if this explanation helps.
Previous Topic:How to Increase heap size for MAT in IBM ISA?
Next Topic:How to pass d64 Parameter to the MAT-JVM
Goto Forum:
  


Current Time: Tue Jul 29 04:52:48 EDT 2014

Powered by FUDForum. Page generated in 0.02064 seconds