/// This function returns the number of bytes in the file.
/// @throws std::string if an error occurs
/// This function returns the number of bytes in the file.
/// @throws std::string if an error occurs
/// @}
/// @name Mutators
/// @}
/// @name Mutators
sys::Path path_; ///< Path to the file.
int options_; ///< Options used to create the mapping
void* base_; ///< Pointer to the base memory address
sys::Path path_; ///< Path to the file.
int options_; ///< Options used to create the mapping
void* base_; ///< Pointer to the base memory address
- MappedFileInfo* info_; ///< Platform specific info for the mapping
+ mutable MappedFileInfo* info_; ///< Platform specific info for the mapping
/// @}
/// @name Disabled
/// @}
/// @name Disabled
-size_t MappedFile::size() {
+size_t MappedFile::size() const {
assert(info_ && "MappedFile not initialized");
return info_->sbuf_.st_size;
}
assert(info_ && "MappedFile not initialized");
return info_->sbuf_.st_size;
}
-size_t MappedFile::size() {
+size_t MappedFile::size() const {
assert(info_ && "MappedFile not initialized");
return info_->sbuf_.st_size;
}
assert(info_ && "MappedFile not initialized");
return info_->sbuf_.st_size;
}