]> git.cworth.org Git - apitrace/blobdiff - trace_parser.hpp
Some initial thoughts on the on-demand loading api.
[apitrace] / trace_parser.hpp
index 4fff9ad1157129e0da8458f8cca87e68687197ec..a000986c3631299292745dc213dca060406938d2 100644 (file)
 #include <iostream>
 #include <list>
 
+#include "trace_file.hpp"
 #include "trace_format.hpp"
 #include "trace_model.hpp"
 
 
 namespace Trace {
 
-class File;
-
 class Parser
 {
 protected:
@@ -73,6 +72,21 @@ public:
 
     Call *parse_call(void);
 
+    bool supportsOffsets() const
+    {
+        return file-supportsOffsets();
+    }
+
+    File::Offset currentOffset()
+    {
+        return file->currentOffset();
+    }
+
+    void setCurrentOffset(const File::Offset &offset)
+    {
+        file->setCurrentOffset(offset);
+    }
+
 protected:
     void parse_enter(void);