|
@@ -94,14 +94,15 @@ public:
|
|
|
static WritableFactory *const NullFactory;
|
|
static WritableFactory *const NullFactory;
|
|
|
|
|
|
|
|
// The primary interface for a caller.
|
|
// The primary interface for a caller.
|
|
|
- BamReader(DatagramGenerator *generator);
|
|
|
|
|
|
|
+ BamReader(DatagramGenerator *generator, const Filename &name="");
|
|
|
~BamReader();
|
|
~BamReader();
|
|
|
|
|
|
|
|
bool init();
|
|
bool init();
|
|
|
|
|
|
|
|
void set_aux_data(const string &name, void *data);
|
|
void set_aux_data(const string &name, void *data);
|
|
|
void *get_aux_data(const string &name) const;
|
|
void *get_aux_data(const string &name) const;
|
|
|
-
|
|
|
|
|
|
|
+ const Filename &get_filename() const;
|
|
|
|
|
+
|
|
|
TypedWritable *read_object();
|
|
TypedWritable *read_object();
|
|
|
INLINE bool is_eof() const;
|
|
INLINE bool is_eof() const;
|
|
|
bool resolve();
|
|
bool resolve();
|
|
@@ -142,7 +143,6 @@ public:
|
|
|
|
|
|
|
|
TypeHandle read_handle(DatagramIterator &scan);
|
|
TypeHandle read_handle(DatagramIterator &scan);
|
|
|
|
|
|
|
|
-
|
|
|
|
|
public:
|
|
public:
|
|
|
INLINE static WritableFactory *get_factory();
|
|
INLINE static WritableFactory *get_factory();
|
|
|
private:
|
|
private:
|
|
@@ -172,6 +172,9 @@ private:
|
|
|
typedef phash_map<int, TypeHandle, int_hash> IndexMap;
|
|
typedef phash_map<int, TypeHandle, int_hash> IndexMap;
|
|
|
IndexMap _index_map;
|
|
IndexMap _index_map;
|
|
|
|
|
|
|
|
|
|
+ // This is the filename of the BAM, or null string if not in a file.
|
|
|
|
|
+ Filename _filename;
|
|
|
|
|
+
|
|
|
// This maps the object ID numbers encountered within the Bam file
|
|
// This maps the object ID numbers encountered within the Bam file
|
|
|
// to the actual pointers of the corresponding generated objects.
|
|
// to the actual pointers of the corresponding generated objects.
|
|
|
class CreatedObj {
|
|
class CreatedObj {
|