TAO_PortableGroup
2.3.3
|
#include <PG_Group_List_Store.h>
Public Types | |
typedef std::set< PortableGroup::ObjectGroupId > | Group_Ids |
typedef std::set< PortableGroup::ObjectGroupId >::iterator | Group_Id_Iterator |
typedef std::set< PortableGroup::ObjectGroupId >::reverse_iterator | Group_Id_Revers_Iterator |
typedef std::set< PortableGroup::ObjectGroupId >::const_iterator | Group_Id_Const_Iterator |
Public Member Functions | |
PG_Group_List_Store (Storable_Factory &storable_factory) | |
~PG_Group_List_Store () | |
PortableGroup::ObjectGroupId | get_next_group_id () |
int | add (PortableGroup::ObjectGroupId id) |
int | remove (PortableGroup::ObjectGroupId id) |
Group_Ids & | get_group_ids () |
void | stale (bool is_stale) |
bool | stale () |
bool | list_obsolete () |
Private Member Functions | |
TAO::Storable_Base * | create_stream (const char *mode) |
void | read (TAO::Storable_Base &stream) |
void | write (TAO::Storable_Base &stream) |
bool | is_obsolete (time_t stored_time) |
Private Attributes | |
Group_Ids | group_ids_ |
PortableGroup::ObjectGroupId | next_group_id_ |
Storable_Factory & | storable_factory_ |
bool | loaded_from_stream_ |
time_t | last_changed_ |
bool | stale_ |
TAO_SYNCH_MUTEX | lock_ |
Friends | |
class | PG_Group_List_Store_File_Guard |
Persists a list of object groups that are themselves persisted. All creation and deletion of persistent object groups should result in the list store being updated. This is done to support multiple group factories using the same persistent object groups.
typedef std::set<PortableGroup::ObjectGroupId>::const_iterator TAO::PG_Group_List_Store::Group_Id_Const_Iterator |
typedef std::set<PortableGroup::ObjectGroupId>::iterator TAO::PG_Group_List_Store::Group_Id_Iterator |
typedef std::set<PortableGroup::ObjectGroupId>::reverse_iterator TAO::PG_Group_List_Store::Group_Id_Revers_Iterator |
typedef std::set<PortableGroup::ObjectGroupId> TAO::PG_Group_List_Store::Group_Ids |
TAO::PG_Group_List_Store::PG_Group_List_Store | ( | Storable_Factory & | storable_factory | ) |
TAO::PG_Group_List_Store::~PG_Group_List_Store | ( | ) |
int TAO::PG_Group_List_Store::add | ( | PortableGroup::ObjectGroupId | id | ) |
|
private |
TAO::PG_Group_List_Store::Group_Ids & TAO::PG_Group_List_Store::get_group_ids | ( | ) |
PortableGroup::ObjectGroupId TAO::PG_Group_List_Store::get_next_group_id | ( | ) |
Return a group ID that can be used for creating a new object group.
|
private |
bool TAO::PG_Group_List_Store::list_obsolete | ( | ) |
Answer if the list is obsolete because the persistent store has been updated. Used by PG_Group_Factory to avoid having to compare IDs in group_map_ with the list contained here.
|
private |
int TAO::PG_Group_List_Store::remove | ( | PortableGroup::ObjectGroupId | id | ) |
void TAO::PG_Group_List_Store::stale | ( | bool | is_stale | ) |
Make explicit that state is stale instead of relying only on persistent file time stamp.
bool TAO::PG_Group_List_Store::stale | ( | ) |
|
private |
|
friend |
|
private |
|
private |
|
private |
|
private |
|
private |
Ensure ID is monotonically increasing even when groups gets removed.
|
private |
|
private |