17 #ifndef LIBPKG_COMPONENT_UPDATE 18 #define LIBPKG_COMPONENT_UPDATE 41 std::vector<component> _data;
63 {
return _data.begin(); }
68 const_iterator
end()
const 69 {
return _data.end(); }
75 const_iterator
find(
const std::string& name)
const;
110 bool read(
const string& pathname);
115 public std::runtime_error
const_iterator begin() const
Get const iterator for start of the updates.
Definition: component_update.h:62
const_iterator end() const
Get const iterator for end of the updates.
Definition: component_update.h:68
const_iterator find(const std::string &name) const
Find const iterator for a component name.
Definition: component_update.cc:43
The namespace used to hold the package management library.
Definition: auto_dir.cc:23
const component & operator[](const std::string &name) const
Get component details for a component name The updates cannot be modified using this operator...
Definition: component_update.cc:33
virtual ~component_update()
Destroy component update.
Definition: component_update.cc:30
A class for managing the updating of package components.
Definition: component_update.h:30
void clear()
Clear status of all components.
Definition: component_update.cc:74
component_update(const string &pathname=string())
Construct component update.
Definition: component_update.cc:24
A class to represent a component of a package.
Definition: component.h:38
void rollback()
Roll back changes.
Definition: component_update.cc:119
An exception class for reporting failure to commit table.
Definition: component_update.h:114
void done()
The updates have been completed, so remove the file.
Definition: component_update.cc:130
void commit()
Commit changes.
Definition: component_update.cc:79
A base class to represent a data table.
Definition: table.h:29
std::vector< component >::const_iterator const_iterator
Definition: component_update.h:33
void insert(const component &value)
Add a component.
Definition: component_update.cc:53