version 1.24, 2004/05/05 17:44:47
|
version 1.25, 2004/06/15 18:38:24
|
|
|
//throw Exception("object not found"); | //throw Exception("object not found"); |
} | } |
| |
#ifdef PEGASUS_USE_DEPRECATED_INTERFACES |
|
const OperationContext::Container & OperationContext::get(const Uint32 key) const |
|
{ |
|
for(Uint32 i = 0, n = _rep->containers.size(); i < n; i++) |
|
{ |
|
if(key == _rep->containers[i]->getKey()) |
|
{ |
|
Container * p = _rep->containers[i]; |
|
|
|
return(*p); |
|
} |
|
} |
|
|
|
//l10n |
|
MessageLoaderParms parms("Common.OperationContext.OBJECT_NOT_FOUND", |
|
"object not found"); |
|
throw Exception(parms); |
|
//throw Exception("object not found"); |
|
} |
|
#endif |
|
|
|
void OperationContext::set(const OperationContext::Container & container) | void OperationContext::set(const OperationContext::Container & container) |
{ | { |
for(Uint32 i = 0, n = _rep->containers.size(); i < n; i++) | for(Uint32 i = 0, n = _rep->containers.size(); i < n; i++) |
|
|
//throw Exception("object not found"); | //throw Exception("object not found"); |
} | } |
| |
#ifdef PEGASUS_USE_DEPRECATED_INTERFACES |
|
void OperationContext::remove(const Uint32 key) |
|
{ |
|
for(Uint32 i = 0, n = _rep->containers.size(); i < n; i++) |
|
{ |
|
if(key == _rep->containers[i]->getKey()) |
|
{ |
|
delete _rep->containers[i]; |
|
_rep->containers.remove(i); |
|
|
|
return; |
|
} |
|
} |
|
|
|
//l10n |
|
MessageLoaderParms parms("Common.OperationContext.OBJECT_NOT_FOUND", |
|
"object not found"); |
|
throw Exception(parms); |
|
//throw Exception("object not found"); |
|
} |
|
#endif |
|
| |
// | // |
// OperationContext::Container | // OperationContext::Container |
// | // |
| |
#ifdef PEGASUS_USE_DEPRECATED_INTERFACES |
|
OperationContext::Container::Container(const Uint32 key) : _key(key) |
|
{ |
|
} |
|
#endif |
|
|
|
OperationContext::Container::~Container(void) | OperationContext::Container::~Container(void) |
{ | { |
} | } |
| |
#ifdef PEGASUS_USE_DEPRECATED_INTERFACES |
|
const Uint32 & OperationContext::Container::getKey(void) const |
|
{ |
|
return(_key); |
|
} |
|
#endif |
|
| |
// | // |
// IdentityContainer | // IdentityContainer |
|
|
const String IdentityContainer::NAME = "IdentityContainer"; | const String IdentityContainer::NAME = "IdentityContainer"; |
| |
IdentityContainer::IdentityContainer(const OperationContext::Container & container) | IdentityContainer::IdentityContainer(const OperationContext::Container & container) |
#ifdef PEGASUS_USE_DEPRECATED_INTERFACES |
|
: OperationContext::Container(container.getKey()) |
|
#endif |
|
{ | { |
const IdentityContainer * p = dynamic_cast<const IdentityContainer *>(&container); | const IdentityContainer * p = dynamic_cast<const IdentityContainer *>(&container); |
| |
|
|
} | } |
| |
IdentityContainer::IdentityContainer(const String & userName) | IdentityContainer::IdentityContainer(const String & userName) |
#ifdef PEGASUS_USE_DEPRECATED_INTERFACES |
|
: OperationContext::Container(CONTEXT_IDENTITY) |
|
#endif |
|
{ | { |
_rep = new IdentityContainerRep(); | _rep = new IdentityContainerRep(); |
_rep->userName = userName; | _rep->userName = userName; |