BDE 4.39.x Production Release
Loading...
Searching...
No Matches
bdlt::TimetableCache_Entry Class Reference

#include <bdlt_timetablecache.h>

Detailed Description

This class defines the type of objects that are inserted into the timetable cache. Each entry contains a shared pointer to a read-only timetable and the time at which that timetable was loaded.

Note
Note that an explicit allocator is required to create an entry object.

See bdlt_timetablecache

Public Member Functions

 TimetableCache_Entry ()
 
 TimetableCache_Entry (Timetable *timetable, const Datetime &loadTime, bslma::Allocator *allocator)
 
 TimetableCache_Entry (const TimetableCache_Entry &original)
 
 ~TimetableCache_Entry ()
 
TimetableCache_Entryoperator= (const TimetableCache_Entry &rhs)
 
bsl::shared_ptr< const Timetableget () const
 
Datetime loadTime () const
 

Constructor & Destructor Documentation

◆ TimetableCache_Entry() [1/3]

bdlt::TimetableCache_Entry::TimetableCache_Entry ( )

Create an empty cache entry object.

Note
Note that an empty cache entry is never actually inserted into the cache.

◆ TimetableCache_Entry() [2/3]

bdlt::TimetableCache_Entry::TimetableCache_Entry ( Timetable timetable,
const Datetime loadTime,
bslma::Allocator allocator 
)

Create a cache entry object for managing the specified timetable that was loaded at the specified loadTime using the specified allocator.

Precondition
The behavior is undefined unless timetable uses allocator to obtain memory.

◆ TimetableCache_Entry() [3/3]

bdlt::TimetableCache_Entry::TimetableCache_Entry ( const TimetableCache_Entry original)

Create a cache entry object having the value of the specified original object.

◆ ~TimetableCache_Entry()

bdlt::TimetableCache_Entry::~TimetableCache_Entry ( )

Destroy this cache entry object.

Member Function Documentation

◆ get()

bsl::shared_ptr< const Timetable > bdlt::TimetableCache_Entry::get ( ) const

Return a shared pointer providing non-modifiable access to the timetable referred to by this cache entry object.

◆ loadTime()

Datetime bdlt::TimetableCache_Entry::loadTime ( ) const

Return the time at which the timetable referred to by this cache entry object was loaded.

◆ operator=()

TimetableCache_Entry & bdlt::TimetableCache_Entry::operator= ( const TimetableCache_Entry rhs)

Assign to this cache entry object the value of the specified rhs object, and return a reference providing modifiable access to this object.


The documentation for this class was generated from the following file: