How to build our own profiler in java?
<p>Want to create customized profiler for java. In search of that got to know about the Hprof tool ... for creating profiler the i reffered the details given...but it is creating a profiler which is of my requirement...then when searched again another link</p>

<p><a href="http://www.ibm.com/developerworks/java/library/j-jip/?ca=dgr-lnxw07JavaProfiling" rel="nofollow">http://www.ibm.com/developerworks/java/library/j-jip/?ca=dgr-lnxw07JavaProfiling</a></p>

<p>and
<a href="http://java.dzone.com/articles/java-profiling-under-covers" rel="nofollow">http://java.dzone.com/articles/java-profiling-under-covers</a></p>

<p>I followed the steps i created a project by copying the program for profile agent code from the first link..then a manifest file was created 
Version No:1
Xcomment: Main will be automatically detected </p>

<p>I replaced the second line with 
Line given in that link then pasted that file in the src folder of the Netbeans project
cleaned and build &amp; created a .jar file. </p>

<p>but java -javaagent:Vc.jar classfile
when executed in command prompt errors are coming ...
Errors
Exception in thread "main" java.lang.NoclassFoundException : C:/documents/Main.class</p>

<p>at java.net .URLClassLoader
...
..</p>

<p>I needed get only the cpu time for each class i used and the cpu time of each method in each class... what shall I do?</p>

<p>Error opening Zipfile or manifest missing
error occurred during initialization of vm agent library failed to init instrument in command prompt</p>
