7#ifndef EXPRESSION_CACHE_H
8#define EXPRESSION_CACHE_H
16#include <boost/algorithm/string/split.hpp>
17#include <boost/algorithm/string/classification.hpp>
84 const std::string& expression_str,
121 std::map<dhcp::SubnetID, dhcp::ExpressionPtr> expressions_;
This class represents configuration element which is associated with database identifier and the modi...
void clear()
Delete all the entries in the cache.
dhcp::ExpressionPtr parseAndCacheExpression(const dhcp::SubnetID &subnet_id, const std::string &expression_str, uint32_t family)
Parses an expression string and caches for the given subnet.
void cacheExpression(const dhcp::SubnetID &subnet_id, dhcp::ExpressionPtr &expression)
Adds (or replaces) the expression for a given subnet to the cache.
size_t size()
Returns number of entries in the cache.
virtual ~ExpressionCache()
Destructor.
ExpressionCache()
Constructor.
boost::posix_time::ptime getLastFlushTime()
Returns the last time the cache was flushed (or the time it was created if it has never been flushed)...
bool findExpression(const dhcp::SubnetID &subnet_id, dhcp::ExpressionPtr &expression)
Fetches the expression for a given subnet.
boost::shared_ptr< Expression > ExpressionPtr
uint32_t SubnetID
Defines unique IPv4 or IPv6 subnet identifier.
Defines the logger used by the top-level component of kea-lfc.