 |
Kea
1.5.0
|
Go to the documentation of this file.
18 #ifndef CQL_HOST_DATA_SOURCE_H
19 #define CQL_HOST_DATA_SOURCE_H
31 class CqlHostDataSourceImpl;
103 virtual void add(
const HostPtr& host)
override;
132 const uint8_t* identifier_begin,
133 const size_t identifier_len)
override;
150 const uint8_t* identifier_begin,
151 const size_t identifier_len)
override;
168 const uint8_t* identifier_begin,
169 const size_t identifier_len)
const override;
196 const uint8_t* identifier_begin,
197 const size_t identifier_len)
const override;
225 const uint8_t* identifier_begin,
226 const size_t identifier_len)
const override;
238 const uint8_t prefix_len)
const override;
269 virtual std::string
getName()
const;
274 virtual std::string
getType()
const override;
289 virtual void commit()
override;
304 #endif // CQL_HOST_DATA_SOURCE_H
virtual std::string getName() const
Returns the name of the database.
virtual ConstHostCollection getAll(const Host::IdentifierType &identifier_type, const uint8_t *identifier_begin, const size_t identifier_len) const override
Return all hosts connected to any subnet for which reservations have been made using a specified iden...
IdentifierType
Type of the host identifier.
std::pair< uint32_t, uint32_t > VersionPair
Pair containing major and minor versions.
The IOAddress class represents an IP addresses (version agnostic)
CqlHostDataSource(const db::DatabaseConnection::ParameterMap ¶meters)
Constructor.
virtual void rollback() override
Rollback Transactions.
boost::shared_ptr< Host > HostPtr
Pointer to the Host object.
virtual void commit() override
Commit Transactions.
virtual bool del4(const SubnetID &subnet_id, const Host::IdentifierType &identifier_type, const uint8_t *identifier_begin, const size_t identifier_len) override
Attempts to delete a host by (subnet-id4, identifier-type, identifier).
Defines the logger used by the top-level component of kea-dhcp-ddns.
virtual ConstHostCollection getAll4(const asiolink::IOAddress &address) const override
Returns a collection of hosts using the specified IPv4 address.
virtual ConstHostPtr get6(const SubnetID &subnet_id, const Host::IdentifierType &identifier_type, const uint8_t *identifier_begin, const size_t identifier_len) const override
Returns a Host connected to an IPv6 subnet.
virtual bool del(const SubnetID &subnet_id, const asiolink::IOAddress &addr) override
Attempts to delete a host by (subnet-id, address)
Base interface for the classes implementing simple data source for host reservations.
virtual bool del6(const SubnetID &subnet_id, const Host::IdentifierType &identifier_type, const uint8_t *identifier_begin, const size_t identifier_len) override
Attempts to delete a host by (subnet-id6, identifier-type, identifier).
Cassandra host data source.
virtual void add(const HostPtr &host) override
Adds a new host to the collection.
std::vector< ConstHostPtr > ConstHostCollection
Collection of the const Host objects.
boost::shared_ptr< const Host > ConstHostPtr
Const pointer to the Host object.
Implementation of the CqlHostDataSource.
virtual ConstHostCollection getAllHosts() const
Returns a collection of all the hosts.
uint32_t SubnetID
Unique identifier for a subnet (both v4 and v6)
std::map< std::string, std::string > ParameterMap
Database configuration parameter map.
virtual ConstHostPtr get4(const SubnetID &subnet_id, const Host::IdentifierType &identifier_type, const uint8_t *identifier_begin, const size_t identifier_len) const override
Retrieves a Host connected to an IPv4 subnet.
virtual std::string getType() const override
Return backend type.
virtual ~CqlHostDataSource()
Virtual destructor.
virtual db::VersionPair getVersion() const
Retrieves schema version from the DB.
virtual std::string getDescription() const
Returns textual description of the backend.