示例#1
0
        /// <summary>
        /// Construct a trace replay.
        /// </summary>
        /// <param name="fn">The filename of the trace to play back</param>
        /// <exception cref="IOException">If anything is wrong with the file.</exception>
        protected TraceProcessorBase(string fn)
        {
            FileName = fn;
            MetaData = new TraceMeta();
            MetaData.Load(fn);

            // Don't mmap the file right away, do so lazily to avoid locking the file handle for updates in other parts of the UI.
        }
示例#2
0
        public TraceTranscoder(Stream outStream)
        {
            MetaData = new TraceMeta();

            m_Out = new BinaryWriter(outStream, Encoding.UTF8, /*leaveOpen:*/ true);

            // Reserve space for two offsets used when decoding.
            m_Out.Write((ulong)0);
            m_Out.Write((ulong)0);
        }
示例#3
0
 internal TraceListItem(string fn, TraceMeta meta, TraceRecorder recorder)
 {
   m_FileName = fn;
   Meta = meta;
   Recorder = recorder;
 }
示例#4
0
 public LiveTraceAnalyzer(TraceMeta meta)
 {
   m_MetaData = meta;
 }
示例#5
0
 public LiveTraceAnalyzer(TraceMeta meta)
 {
     m_MetaData = meta;
 }
示例#6
0
 void ITraceFileHandler.OnRecordingProgress(object context, TraceMeta meta)
 {
   this.BeginInvoke((Action)delegate()
   {
     m_TraceList.UpdateObject(context);
   });
 }
示例#7
0
 object ITraceFileHandler.OnRecordingStarted(string filename, TraceMeta meta, TraceRecorder recorder)
 {
   var item = new TraceListItem(filename, meta, recorder);
   this.Invoke((Action)delegate()
     {
       m_TraceItems.Add(item);
       m_TraceList.SetObjects(m_TraceItems);
     });
   return item;
 }