28INLINE
bool BamCacheRecord::
30 return (_source_pathname == other._source_pathname &&
31 _cache_filename == other._cache_filename &&
32 _recorded_time == other._recorded_time &&
33 _record_size == other._record_size);
41INLINE
const Filename &BamCacheRecord::
42get_source_pathname()
const {
43 return _source_pathname;
51INLINE
const Filename &BamCacheRecord::
52get_cache_filename()
const {
53 return _cache_filename;
61INLINE time_t BamCacheRecord::
62get_source_timestamp()
const {
63 return _source_timestamp;
69INLINE time_t BamCacheRecord::
70get_recorded_time()
const {
71 return _recorded_time;
77INLINE
int BamCacheRecord::
78get_num_dependent_files()
const {
86INLINE
const Filename &BamCacheRecord::
87get_dependent_pathname(
int n)
const {
88 nassertr(n >= 0 && n < (
int)_files.size(), _files[0]._pathname);
89 return _files[n]._pathname;
96INLINE
bool BamCacheRecord::
98 return (_ptr !=
nullptr);
105INLINE
void BamCacheRecord::
107 if (_ref_ptr !=
nullptr) {
138 return (ptr !=
nullptr);
158 if (_ref_ptr !=
nullptr) {
188 nassertv(dummy == 0);
195INLINE
bool BamCacheRecord::SortByAccessTime::
197 return (a->_record_access_time < b->_record_access_time);
An instance of this class is written to the front of a Bam or Txo file to make the file a cached inst...
get_data
Returns a pointer to the data stored in the record, or NULL if there is no data.
bool extract_data(TypedWritable *&ptr, ReferenceCount *&ref_ptr)
Fills ptr and ref_ptr with the two different-typed pointers to the same object, the data stored withi...
set_data
Stores a new data object on the record.
The name of a file, such as a texture file or an Egg file.
A base class for all things that want to be reference-counted.
void ref() const
Explicitly increments the reference count.
A base class for things which need to inherit from both TypedWritable and from ReferenceCount.
Base class for objects that can be written to and read from Bam files.
virtual ReferenceCount * as_reference_count()
Returns the pointer cast to a ReferenceCount pointer, if it is in fact of that type.
void unref_delete(RefCountType *ptr)
This global helper function will unref the given ReferenceCount object, and if the reference count re...