diff options
author | pixel <pixel> | 2007-06-19 21:31:51 +0000 |
---|---|---|
committer | pixel <pixel> | 2007-06-19 21:31:51 +0000 |
commit | dd689636c1e82bb0c773f98cc3595c3002b12837 (patch) | |
tree | 7b9fe840b5da5553fc422a35a502ff267c23c8ca | |
parent | 2ea3dc07618405c5bfdc8b7a550acb3a3e81d6b2 (diff) |
Adding the possibility to browse and inspect the domains.
-rw-r--r-- | include/Domain.h | 5 | ||||
-rw-r--r-- | lib/Domain.cc | 15 |
2 files changed, 18 insertions, 2 deletions
diff --git a/include/Domain.h b/include/Domain.h index 964b33c..2c7d97c 100644 --- a/include/Domain.h +++ b/include/Domain.h @@ -17,7 +17,7 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -/* $Id: Domain.h,v 1.3 2007-05-30 11:57:08 pixel Exp $ */ +/* $Id: Domain.h,v 1.4 2007-06-19 21:31:51 pixel Exp $ */ #ifndef __DOMAIN_H__ #define __DOMAIN_H__ @@ -32,6 +32,9 @@ class Domain : public Base { static Domain * find_domain(const String & url); void OnTop(); virtual void Do(const HttpRequest &, HttpResponse *) throw (GeneralException) = 0; + static Domain * First(); + Domain * Next(); + String GetPattern(); private: Domain * find_domain_r(const String & url); static Domain * head; diff --git a/lib/Domain.cc b/lib/Domain.cc index eb087f9..6f06476 100644 --- a/lib/Domain.cc +++ b/lib/Domain.cc @@ -17,13 +17,26 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -/* $Id: Domain.cc,v 1.3 2007-05-30 11:57:09 pixel Exp $ */ +/* $Id: Domain.cc,v 1.4 2007-06-19 21:31:51 pixel Exp $ */ #include "Domain.h" Domain * Domain::head = 0; +Domain * Domain::First() { + return head; +} + +Domain * Domain::Next() { + return next; +} + +String Domain::GetPattern() { + pattern.GetPattern(); +} + Domain::Domain(const Regex & _pattern) : pattern(_pattern) { + printm(M_INFO, "Creating Domain @ %p, with pattern = " + pattern.GetPattern() + "\n", this); prev = 0; next = head; head = this; |