return (configuration_);
}
- /// \brief Result of the getCachedZoneWriter() method.
- enum ReloadResult {
+private:
+ /// \brief Convenience type shortcut
+ typedef boost::shared_ptr<memory::ZoneWriter> ZoneWriterPtr;
+public:
+ /// \brief Codes indicating in-memory cache status for a given zone name.
+ ///
+ /// This is used as a result of the getCachedZoneWriter() method.
+ enum CacheStatus {
CACHE_DISABLED, ///< The cache is not enabled in this list.
ZONE_NOT_CACHED, ///< Zone is served directly, not from cache
/// (including the case cache is disabled for
/// the writer provided.
};
-private:
- /// \brief Convenience type shortcut
- typedef boost::shared_ptr<memory::ZoneWriter> ZoneWriterPtr;
-public:
-
/// \brief Return value of getCachedZoneWriter()
///
/// A pair containing status and the zone writer, for the
/// getCachedZoneWriter() method.
- typedef std::pair<ReloadResult, ZoneWriterPtr> ZoneWriterPair;
+ typedef std::pair<CacheStatus, ZoneWriterPtr> ZoneWriterPair;
/// \brief Return a zone writer that can be used to reload a zone.
///
EXPECT_EQ(cache, list_->getDataSources()[index].cache_ !=
shared_ptr<InMemoryClient>());
}
- ConfigurableClientList::ReloadResult doReload(const Name& origin);
+ ConfigurableClientList::CacheStatus doReload(const Name& origin);
const RRClass rrclass_;
shared_ptr<TestedList> list_;
const ClientList::FindResult negative_result_;
true);
}
-ConfigurableClientList::ReloadResult
+ConfigurableClientList::CacheStatus
ListTest::doReload(const Name& origin) {
ConfigurableClientList::ZoneWriterPair
result(list_->getCachedZoneWriter(origin));