summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormday <mday>2003-04-02 16:49:02 +0000
committermday <mday>2003-04-02 16:49:02 +0000
commit54d9aecc44025276e876c409ca620473e17003ea (patch)
treeb6506b82b15188c13af40d2b030980df3a392fec
parent601bbf77336540a35811058db1b87039748335f1 (diff)
downloadtog-pegasus-mday-2-0-patches.zip
tog-pegasus-mday-2-0-patches.tar.gz
tog-pegasus-mday-2-0-patches.tar.xz
*** empty log message ***mday-2-0-patches
-rw-r--r--src/Pegasus/Server/reg_table.cpp26
1 files changed, 22 insertions, 4 deletions
diff --git a/src/Pegasus/Server/reg_table.cpp b/src/Pegasus/Server/reg_table.cpp
index 5fa6b96..f0b4c53 100644
--- a/src/Pegasus/Server/reg_table.cpp
+++ b/src/Pegasus/Server/reg_table.cpp
@@ -190,6 +190,8 @@ class reg_table_rep : public Sharable
void destroy_all(void);
+ void remove_by_router(const reg_table_record& rec);
+
reg_table_rep(void) ;
~reg_table_rep(void) ;
@@ -198,6 +200,8 @@ class reg_table_rep : public Sharable
static const Uint32 MULTIPLE;
static const Uint32 DESTROY;
static const Uint32 EXTENDED;
+ static const Uint32 SERVICE;
+
reg_table_record * _find(const reg_table_record & rec,
Uint32 flags,
@@ -226,7 +230,7 @@ const Uint32 reg_table_rep::REMOVE = 0x00000002;
const Uint32 reg_table_rep::MULTIPLE = 0x00000004;
const Uint32 reg_table_rep::DESTROY = 0x00000008;
const Uint32 reg_table_rep::EXTENDED = 0x00000010;
-
+const Uint32 reg_table_rep::SERVICE = 0x00000020;
// insert optimized for simplicity, not speed
Boolean
@@ -297,7 +301,7 @@ reg_table_rep::release_extended(const reg_table_record &rec)
void
-reg_table_rep::release(const reg_table_record & rec,
+reg_table_rep::release(const reg_table_record& rec,
Array<reg_table_record *> *results)
{
_find(rec,
@@ -305,7 +309,7 @@ reg_table_rep::release(const reg_table_record & rec,
}
void
-reg_table_rep::release_extended(const reg_table_record & rec,
+reg_table_rep::release_extended(const reg_table_record& rec,
Array<reg_table_record *> *results)
{
_find(rec,
@@ -319,7 +323,7 @@ reg_table_rep::destroy(const reg_table_record & rec)
}
void
-reg_table_rep::destroy_extended(const reg_table_record & rec)
+reg_table_rep::destroy_extended(const reg_table_record& rec)
{
_find(rec, (FIND | REMOVE | DESTROY | EXTENDED));
}
@@ -332,6 +336,13 @@ reg_table_rep::destroy_all(void)
}
+void
+reg_table_rep::remove_by_router(const reg_table_record& rec)
+{
+ _find(rec, (FIND | REMOVE | DESTROY | MULTIPLE | SERVICE));
+}
+
+
reg_table_record *
reg_table_rep::_find(const reg_table_record &rec,
Uint32 flags,
@@ -432,12 +443,19 @@ reg_table_rep::_enumerate(const reg_table_record & rec,
if(rec.flags != 0xffffffff)
if(tmp->flags != rec.flags)
continue;
+
if(flags & EXTENDED)
{
if(false == _extended_match(rec, *tmp))
continue;
}
+ if(flags & SERVICE)
+ {
+ if(rec.service != tmp->service)
+ continue;
+ }
+
if(flags & REMOVE || flags & DESTROY)
{
y.value()->remove(x.key());