Class RecordingPrinter


  • public final class RecordingPrinter
    extends java.lang.Object
    Prints a flight recording to a PrintWriter.
    • Field Detail

      • formatValues

        private final boolean formatValues
      • out

        private final java.io.PrintWriter out
    • Method Detail

      • main

        public static void main​(java.lang.String[] args)
                         throws java.io.IOException,
                                java.lang.InterruptedException,
                                CouldNotLoadRecordingException
        Main method that will print a recording Usage:
         java org.openjdk.jmc.flightrecorder [-formatValues] [-brief] fileName
        
         - formatValues will format values in a suitable unit (may loose precision)
        
         - brief will print only parts of all event values.
         
        Throws:
        java.io.IOException
        java.lang.InterruptedException
        CouldNotLoadRecordingException
      • buildFromOptions

        private static RecordingPrinter buildFromOptions​(java.io.PrintWriter output,
                                                         java.lang.String[] args)
                                                  throws java.text.ParseException
        Throws:
        java.text.ParseException
      • printHelp

        private static void printHelp()
      • printEvent

        public void printEvent​(IItem e)
      • printValues

        private void printValues​(IItem event)
      • stringify

        private java.lang.String stringify​(java.lang.String indent,
                                           java.lang.Object value)
      • printFrame

        private static void printFrame​(java.lang.String indent,
                                       IMCFrame frame,
                                       java.io.PrintWriter out)
      • stringifyType

        private static java.lang.String stringifyType​(IMCType type)
      • stringifyMethod

        private static java.lang.String stringifyMethod​(IMCMethod method)
      • formatPackage

        private static java.lang.String formatPackage​(IMCPackage mcPackage)