[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[certi-cvs] certi/libCERTI fed.cc RootObject.hh ObjectClass...
From: |
certi-cvs |
Subject: |
[certi-cvs] certi/libCERTI fed.cc RootObject.hh ObjectClass... |
Date: |
Fri, 31 Oct 2008 13:50:25 +0000 |
CVSROOT: /sources/certi
Module name: certi
Changes by: Eric NOULARD <erk> 08/10/31 13:50:25
Modified files:
libCERTI : fed.cc RootObject.hh ObjectClass.hh
Interaction.cc Interaction.hh XmlParser.cc
ObjectClassSet.cc RootObject.cc ObjectClass.cc
Log message:
More parser clean-up...
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/certi/libCERTI/fed.cc?cvsroot=certi&r1=3.18&r2=3.19
http://cvs.savannah.gnu.org/viewcvs/certi/libCERTI/RootObject.hh?cvsroot=certi&r1=3.30&r2=3.31
http://cvs.savannah.gnu.org/viewcvs/certi/libCERTI/ObjectClass.hh?cvsroot=certi&r1=3.38&r2=3.39
http://cvs.savannah.gnu.org/viewcvs/certi/libCERTI/Interaction.cc?cvsroot=certi&r1=3.45&r2=3.46
http://cvs.savannah.gnu.org/viewcvs/certi/libCERTI/Interaction.hh?cvsroot=certi&r1=3.31&r2=3.32
http://cvs.savannah.gnu.org/viewcvs/certi/libCERTI/XmlParser.cc?cvsroot=certi&r1=3.27&r2=3.28
http://cvs.savannah.gnu.org/viewcvs/certi/libCERTI/ObjectClassSet.cc?cvsroot=certi&r1=3.39&r2=3.40
http://cvs.savannah.gnu.org/viewcvs/certi/libCERTI/RootObject.cc?cvsroot=certi&r1=3.35&r2=3.36
http://cvs.savannah.gnu.org/viewcvs/certi/libCERTI/ObjectClass.cc?cvsroot=certi&r1=3.54&r2=3.55
Patches:
Index: fed.cc
===================================================================
RCS file: /sources/certi/certi/libCERTI/fed.cc,v
retrieving revision 3.18
retrieving revision 3.19
diff -u -b -r3.18 -r3.19
--- fed.cc 30 Oct 2008 16:01:38 -0000 3.18
+++ fed.cc 31 Oct 2008 13:50:24 -0000 3.19
@@ -19,7 +19,7 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
// USA
//
-// $Id: fed.cc,v 3.18 2008/10/30 16:01:38 erk Exp $
+// $Id: fed.cc,v 3.19 2008/10/31 13:50:24 erk Exp $
// ----------------------------------------------------------------------------
// CERTI header
@@ -106,11 +106,11 @@
federate = "" ;
attribute = 0 ;
parameter = 0 ;
- #ifndef _WIN32
+#ifndef _WIN32
/* we may need to restart parsing after previous parse error */
rewind(yyin);
yyrestart(yyin);
- #endif
+#endif
int result = yyparse();
fclose(file);
return result ;
@@ -155,7 +155,7 @@
{
indent();
if(verbose) {
- cout << "(federation \"" << arg.c_str() << "\")" ;
+ cout << "(federation \"" << arg << "\")" ;
}
}
@@ -165,7 +165,7 @@
{
indent();
if(verbose) {
- cout << "(FEDversion \"" << arg.c_str() << "\")" ;
+ cout << "(FEDversion \"" << arg << "\")" ;
}
}
@@ -223,12 +223,12 @@
void
endFederate()
{
- SecurityLevelID level = root_object->GetSecurityLevelID(arg.c_str());
- root_object->registerFederate(federate.c_str(), level);
+ SecurityLevelID level = root_object->getSecurityLevelID(arg);
+ root_object->registerFederate(federate, level);
indent();
if(verbose) {
- cout <<"(federate \"" << federate.c_str() << "\" \""
- << arg.c_str() << "\")" ;
+ cout <<"(federate \"" << federate << "\" \""
+ << arg << "\")" ;
}
}
@@ -255,7 +255,7 @@
indent();
if(verbose) {
- cout << "(class \"" << arg.c_str() << "\" (id "
+ cout << "(class \"" << arg << "\" (id "
<< object->getHandle() << ")" ;
}
++indentation ;
@@ -265,11 +265,11 @@
void
addObjectSecLevel(string name)
{
- SecurityLevelID level = root_object->GetSecurityLevelID(name.c_str());
- objects.back()->setLevelId(level);
+ SecurityLevelID level = root_object->getSecurityLevelID(name);
+ objects.back()->setSecurityLevelId(level);
indent();
if(verbose) {
- cout << "(sec_level \"" << name.c_str() << "\")" ;
+ cout << "(sec_level \"" << name << "\")" ;
}
}
@@ -282,7 +282,7 @@
indent();
if(verbose) {
- cout << "(attribute \"" << arg.c_str() << "\" (id "
+ cout << "(attribute \"" << arg << "\" (id "
<< attribute->getHandle() << ")" ;
}
printTransport();
@@ -308,22 +308,23 @@
void
startInteraction()
{
- Interaction *interaction = new Interaction();
- interaction->setHandle(interactionHandle++);
- interaction->setName(arg.c_str());
- interaction->transport = transport ;
- interaction->order = order ;
+ Interaction *parent = NULL;
+ Interaction *interaction = new
Interaction(arg,interactionHandle++,transport,order);
+ /* does this interaction class have a parent ? */
if (interactions.size() > 0) {
- Interaction *parent = interactions.back();
- root_object->Interactions->buildParentRelation(interaction, parent);
+ parent = interactions.back();
}
+
+ root_object->addInteractionClass(interaction,parent);
+ /* put the freshly created interaction on the interaction stack
+ * (for inheritance handle)
+ */
interactions.push_back(interaction);
- root_object->Interactions->addClass(interaction);
indent();
if(verbose)
- cout << "(interaction \"" << arg.c_str() << "\" (id "
+ cout << "(interaction \"" << arg << "\" (id "
<< interaction->getHandle() << ")" ;
printTransport();
printOrder();
@@ -334,22 +335,22 @@
void
addInteractionSecurityLevel()
{
- SecurityLevelID level = root_object->GetSecurityLevelID(arg.c_str());
+ SecurityLevelID level = root_object->getSecurityLevelID(arg);
interactions.back()->setLevelId(level);
indent();
if(verbose)
- cout << "(sec_level \"" << arg.c_str() << "\")" ;
+ cout << "(sec_level \"" << arg << "\")" ;
}
// ----------------------------------------------------------------------------
void
addObjectSecurityLevel()
{
- SecurityLevelID level = root_object->GetSecurityLevelID(arg.c_str());
- objects.back()->setLevelId(level);
+ SecurityLevelID level = root_object->getSecurityLevelID(arg);
+ objects.back()->setSecurityLevelId(level);
indent();
if(verbose) {
- cout << "(sec_level \"" << arg.c_str() << "\")" ;
+ cout << "(sec_level \"" << arg << "\")" ;
}
}
@@ -359,12 +360,12 @@
{
parameter = new Parameter();
parameter->setHandle(parameterHandle++);
- parameter->setName(arg.c_str());
+ parameter->setName(arg);
interactions.back()->addParameter(parameter);
indent();
if(verbose) {
- cout << "(parameter \"" << arg.c_str() << "\" (id "
+ cout << "(parameter \"" << arg << "\" (id "
<< parameter->getHandle() << "))" << std::flush;
}
}
@@ -416,7 +417,7 @@
indent();
if(verbose) {
- cout << "(space \"" << arg.c_str() << "\" (id "
+ cout << "(space \"" << arg << "\" (id "
<< routing_space.getHandle() << ")" ;
}
++indentation ;
@@ -444,11 +445,11 @@
indent();
if(verbose) {
- cout << "(dimension \"" << arg.c_str() << "\" (id "
+ cout << "(dimension \"" << arg << "\" (id "
<< dimension.getHandle() << "))" ;
}
}
}} // namespaces
-// $Id: fed.cc,v 3.18 2008/10/30 16:01:38 erk Exp $
+// $Id: fed.cc,v 3.19 2008/10/31 13:50:24 erk Exp $
Index: RootObject.hh
===================================================================
RCS file: /sources/certi/certi/libCERTI/RootObject.hh,v
retrieving revision 3.30
retrieving revision 3.31
diff -u -b -r3.30 -r3.31
--- RootObject.hh 30 Oct 2008 16:01:37 -0000 3.30
+++ RootObject.hh 31 Oct 2008 13:50:24 -0000 3.31
@@ -19,7 +19,7 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
// USA
//
-// $Id: RootObject.hh,v 3.30 2008/10/30 16:01:37 erk Exp $
+// $Id: RootObject.hh,v 3.31 2008/10/31 13:50:24 erk Exp $
// ----------------------------------------------------------------------------
#ifndef LIBCERTI_ROOT_OBJECT
@@ -79,9 +79,16 @@
void display() const;
- SecurityLevelID GetSecurityLevelID(const char *the_name);
+ /**
+ * Return the security LevelID corresponding to a security level name.
+ * @param[in] levelName the security level name
+ * @return the LevelID of the level whose name is levelName if
+ * a security server exists
+ * PublicLevelID if no security server exists.
+ */
+ SecurityLevelID getSecurityLevelID(const std::string& levelName);
- void registerFederate(const char *the_federate,
+ void registerFederate(const std::string& the_federate,
SecurityLevelID the_level_id);
// Data Distribution Management
@@ -137,8 +144,10 @@
/**
* Add an interaction class to the ObjectRoot
* @param[in] currentIC the interaction class to be added.
+ * @param[in] parentIC the parent interaction class of currentIC
+ * this may be NULL.
*/
- void addInteractionClass(Interaction* currentIC);
+ void addInteractionClass(Interaction* currentIC, Interaction* parentIC);
/**
* The set of object classes.
@@ -173,4 +182,4 @@
#endif // LIBCERTI_ROOT_OBJECT
-// $Id: RootObject.hh,v 3.30 2008/10/30 16:01:37 erk Exp $
+// $Id: RootObject.hh,v 3.31 2008/10/31 13:50:24 erk Exp $
Index: ObjectClass.hh
===================================================================
RCS file: /sources/certi/certi/libCERTI/ObjectClass.hh,v
retrieving revision 3.38
retrieving revision 3.39
diff -u -b -r3.38 -r3.39
--- ObjectClass.hh 30 Oct 2008 16:01:38 -0000 3.38
+++ ObjectClass.hh 31 Oct 2008 13:50:24 -0000 3.39
@@ -19,7 +19,7 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
// USA
//
-// $Id: ObjectClass.hh,v 3.38 2008/10/30 16:01:38 erk Exp $
+// $Id: ObjectClass.hh,v 3.39 2008/10/31 13:50:24 erk Exp $
// ----------------------------------------------------------------------------
#ifndef _CERTI_OBJECT_CLASS_HH
@@ -94,9 +94,9 @@
void checkFederateAccess(FederateHandle, const char *)
throw (SecurityError);
- SecurityLevelID getLevelId() const { return levelId ; };
+ SecurityLevelID getSecurityLevelId() const { return securityLevelId ; };
- void setLevelId(SecurityLevelID NewLevelID);
+ void setSecurityLevelId(SecurityLevelID newLevelID) throw (SecurityError);
AttributeHandle addAttribute(ObjectClassAttribute *the_attribute,
bool is_inherited = false);
@@ -261,7 +261,11 @@
// Attributes
ObjectClassHandle handle ;
FederateHandle maxSubscriberHandle ; //! greatest subscriber handle
- SecurityLevelID levelId ; //! default level for non inherited attributes
+ /**
+ * The security level ID attached to this object class.
+ * default level for non inherited attributes.
+ */
+ SecurityLevelID securityLevelId ;
std::list<ObjectClassAttribute *> attributeSet ;
std::list<Object *> objectSet ;
ObjectClassHandle superClass;
@@ -275,4 +279,4 @@
#endif // _CERTI_OBJECT_CLASS_HH
-// $Id: ObjectClass.hh,v 3.38 2008/10/30 16:01:38 erk Exp $
+// $Id: ObjectClass.hh,v 3.39 2008/10/31 13:50:24 erk Exp $
Index: Interaction.cc
===================================================================
RCS file: /sources/certi/certi/libCERTI/Interaction.cc,v
retrieving revision 3.45
retrieving revision 3.46
diff -u -b -r3.45 -r3.46
--- Interaction.cc 30 Oct 2008 10:11:41 -0000 3.45
+++ Interaction.cc 31 Oct 2008 13:50:24 -0000 3.46
@@ -19,7 +19,7 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
// USA
//
-// $Id: Interaction.cc,v 3.45 2008/10/30 10:11:41 erk Exp $
+// $Id: Interaction.cc,v 3.46 2008/10/31 13:50:24 erk Exp $
// ----------------------------------------------------------------------------
@@ -199,10 +199,11 @@
// ----------------------------------------------------------------------------
//! Interaction.
-Interaction::Interaction()
- : parent(0), depth(0), transport(BEST_EFFORT), order(RECEIVE), handle(0),
+Interaction::Interaction(const std::string& name, InteractionClassHandle
handle, TransportType transport, OrderType order)
+ : parent(0), depth(0), transport(transport), order(order), handle(handle),
id(PublicLevelID)
{
+ setName(name);
}
// ----------------------------------------------------------------------------
@@ -532,4 +533,4 @@
} // namespace certi
-// $Id: Interaction.cc,v 3.45 2008/10/30 10:11:41 erk Exp $
+// $Id: Interaction.cc,v 3.46 2008/10/31 13:50:24 erk Exp $
Index: Interaction.hh
===================================================================
RCS file: /sources/certi/certi/libCERTI/Interaction.hh,v
retrieving revision 3.31
retrieving revision 3.32
diff -u -b -r3.31 -r3.32
--- Interaction.hh 30 Oct 2008 10:11:41 -0000 3.31
+++ Interaction.hh 31 Oct 2008 13:50:25 -0000 3.32
@@ -19,7 +19,7 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
// USA
//
-// $Id: Interaction.hh,v 3.31 2008/10/30 10:11:41 erk Exp $
+// $Id: Interaction.hh,v 3.32 2008/10/31 13:50:25 erk Exp $
// ----------------------------------------------------------------------------
#ifndef _CERTI_INTERACTION_HH
@@ -46,7 +46,17 @@
class CERTI_EXPORT Interaction : public Subscribable
{
public:
- Interaction();
+ /**
+ * Build an interaction class object.
+ * @param[in] name the name of the interaction class
+ * @param[in] handle the handle of this class
+ * @param[in] transport the transport type
+ * @param[in] order the receive order type
+ */
+ Interaction(const std::string& name, InteractionClassHandle handle,
TransportType transport, OrderType order);
+ /**
+ * Destructor.
+ */
~Interaction();
void setSpace(SpaceHandle);
@@ -149,6 +159,12 @@
OrderType order ;
private:
+ /*
+ * private default constructor with no code
+ * one should not call it.
+ */
+ Interaction();
+
InteractionClassHandle handle ; //!< Interaction class handle.
Parameter *getParameterByHandle(ParameterHandle the_handle) const
@@ -172,4 +188,4 @@
#endif // _CERTI_INTERACTION.HH
-// $Id: Interaction.hh,v 3.31 2008/10/30 10:11:41 erk Exp $
+// $Id: Interaction.hh,v 3.32 2008/10/31 13:50:25 erk Exp $
Index: XmlParser.cc
===================================================================
RCS file: /sources/certi/certi/libCERTI/XmlParser.cc,v
retrieving revision 3.27
retrieving revision 3.28
diff -u -b -r3.27 -r3.28
--- XmlParser.cc 30 Oct 2008 16:01:38 -0000 3.27
+++ XmlParser.cc 31 Oct 2008 13:50:25 -0000 3.28
@@ -228,40 +228,40 @@
void
XmlParser::parseInteraction(Interaction* parent)
{
- D[pdTrace] << "New Interaction Class" << endl ;
+ D[pdTrace] << "New Interaction Class" << endl;
+ std::string name;
+ TransportType transport;
+ OrderType order;
xmlNodePtr prev = cur ;
- Interaction* current = new Interaction();
// Name
- current->setName(CleanXmlGetProp(cur,ATTRIBUTE_NAME));
-
- // Handle
- current->setHandle(freeInteractionClassHandle++);
+ name = std::string(CleanXmlGetProp(cur,ATTRIBUTE_NAME));
// Transportation
- xmlChar* transport = xmlGetProp(cur, ATTRIBUTE_TRANSPORTATION);
- if (!xmlStrcmp(transport, VALUE_RELIABLE)) {
- current->transport = RELIABLE ;
+ xmlChar* xtransport = xmlGetProp(cur, ATTRIBUTE_TRANSPORTATION);
+ if (!xmlStrcmp(xtransport, VALUE_RELIABLE)) {
+ transport = RELIABLE ;
}
else {
- if (!xmlStrcmp(transport,VALUE_BESTEFFORT)) {
- current->transport = BEST_EFFORT ;
+ if (!xmlStrcmp(xtransport,VALUE_BESTEFFORT)) {
+ transport = BEST_EFFORT ;
}
}
- xmlFree(transport);
+ xmlFree(xtransport);
// Order
- xmlChar* order = xmlGetProp(cur, ATTRIBUTE_ORDER);
- if (!xmlStrcmp(order, VALUE_TSO)) {
- current->order = TIMESTAMP ;
+ xmlChar* xorder = xmlGetProp(cur, ATTRIBUTE_ORDER);
+ if (!xmlStrcmp(xorder, VALUE_TSO)) {
+ order = TIMESTAMP ;
}
else {
- if (!xmlStrcmp(order, VALUE_RO)) {
- current->order = RECEIVE ;
+ if (!xmlStrcmp(xorder, VALUE_RO)) {
+ order = RECEIVE ;
}
}
- xmlFree(order);
+ xmlFree(xorder);
+ Interaction* current = new
Interaction(name,freeInteractionClassHandle++,transport,order);
// Routing space
char *space = (char *) xmlGetProp(cur, ATTRIBUTE_SPACE);
@@ -279,9 +279,7 @@
xmlFree(space);
// Add to interactions list, and build inheritance relation
- root->Interactions->addClass(current);
- if (parent != 0)
- root->Interactions->buildParentRelation(current, parent);
+ root->addInteractionClass(current,parent);
cur = cur->xmlChildrenNode ;
while (cur != NULL) {
Index: ObjectClassSet.cc
===================================================================
RCS file: /sources/certi/certi/libCERTI/ObjectClassSet.cc,v
retrieving revision 3.39
retrieving revision 3.40
diff -u -b -r3.39 -r3.40
--- ObjectClassSet.cc 18 Sep 2008 14:41:29 -0000 3.39
+++ ObjectClassSet.cc 31 Oct 2008 13:50:25 -0000 3.40
@@ -19,7 +19,7 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
// USA
//
-// $Id: ObjectClassSet.cc,v 3.39 2008/09/18 14:41:29 gotthardp Exp $
+// $Id: ObjectClassSet.cc,v 3.40 2008/10/31 13:50:25 erk Exp $
// ----------------------------------------------------------------------------
// Project
@@ -87,7 +87,7 @@
ObjectClass *superclass)
{
subclass->setSuperclass(superclass->getHandle());
- subclass->setLevelId(superclass->getLevelId());
+ subclass->setSecurityLevelId(superclass->getSecurityLevelId());
superclass->addSubclass(subclass);
superclass->addAttributesToChild(subclass);
}
@@ -843,4 +843,4 @@
} // namespace certi
-// $Id: ObjectClassSet.cc,v 3.39 2008/09/18 14:41:29 gotthardp Exp $
+// $Id: ObjectClassSet.cc,v 3.40 2008/10/31 13:50:25 erk Exp $
Index: RootObject.cc
===================================================================
RCS file: /sources/certi/certi/libCERTI/RootObject.cc,v
retrieving revision 3.35
retrieving revision 3.36
diff -u -b -r3.35 -r3.36
--- RootObject.cc 30 Oct 2008 16:01:38 -0000 3.35
+++ RootObject.cc 31 Oct 2008 13:50:25 -0000 3.36
@@ -19,7 +19,7 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
// USA
//
-// $Id: RootObject.cc,v 3.35 2008/10/30 16:01:38 erk Exp $
+// $Id: RootObject.cc,v 3.36 2008/10/31 13:50:25 erk Exp $
// ----------------------------------------------------------------------------
#include "Object.hh"
@@ -87,24 +87,20 @@
}
}
-// ----------------------------------------------------------------------------
-/*! Return the LevelID of the level whose name is 'theLevelName' if the
- security server is defined, else return PublicLevelID(on the RTIA).
-*/
SecurityLevelID
-RootObject::GetSecurityLevelID(const char *theLevelName)
+RootObject::getSecurityLevelID(const std::string& levelName)
{
- return server ? server->getLevelIDWithName(theLevelName) : PublicLevelID ;
+ return server ? server->getLevelIDWithName(levelName.c_str()) :
PublicLevelID;
}
// ----------------------------------------------------------------------------
//! registerFederate.
void
-RootObject::registerFederate(const char *the_federate,
+RootObject::registerFederate(const std::string& the_federate,
SecurityLevelID the_level_id)
{
if (server != NULL)
- server->registerFederate(the_federate, the_level_id);
+ server->registerFederate(the_federate.c_str(), the_level_id);
}
// ----------------------------------------------------------------------------
@@ -357,10 +353,13 @@
} /* end of addObjectClass */
void
-RootObject::addInteractionClass(Interaction* currentIC) {
-
-}
+RootObject::addInteractionClass(Interaction* currentIC, Interaction* parentIC)
{
+ if (NULL!=parentIC) {
+ Interactions->buildParentRelation(currentIC, parentIC);
+ }
+ Interactions->addClass(currentIC);
+} /* end of addInteractionClass */
} // namespace certi
-// $Id: RootObject.cc,v 3.35 2008/10/30 16:01:38 erk Exp $
+// $Id: RootObject.cc,v 3.36 2008/10/31 13:50:25 erk Exp $
Index: ObjectClass.cc
===================================================================
RCS file: /sources/certi/certi/libCERTI/ObjectClass.cc,v
retrieving revision 3.54
retrieving revision 3.55
diff -u -b -r3.54 -r3.55
--- ObjectClass.cc 30 Oct 2008 16:01:38 -0000 3.54
+++ ObjectClass.cc 31 Oct 2008 13:50:25 -0000 3.55
@@ -19,7 +19,7 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
// USA
//
-// $Id: ObjectClass.cc,v 3.54 2008/10/30 16:01:38 erk Exp $
+// $Id: ObjectClass.cc,v 3.55 2008/10/31 13:50:25 erk Exp $
// ----------------------------------------------------------------------------
#include "Object.hh"
@@ -71,7 +71,7 @@
// If the attribute is inherited, it keeps its security level.
// If not, it takes the default security level of the class.
if (!is_inherited)
- theAttribute->level = levelId ;
+ theAttribute->level = securityLevelId ;
attributeSet.push_front(theAttribute);
@@ -275,7 +275,7 @@
if (server == NULL)
return ;
- bool result = server->canFederateAccessData(the_federate, levelId);
+ bool result = server->canFederateAccessData(the_federate, securityLevelId);
// BUG: Should use Audit.
if (!result) {
@@ -287,7 +287,7 @@
// ----------------------------------------------------------------------------
ObjectClass::ObjectClass(std::string name, ObjectClassHandle handle)
- : Named(name), server(NULL), handle(handle), maxSubscriberHandle(0),
levelId(PublicLevelID),
+ : Named(name), server(NULL), handle(handle), maxSubscriberHandle(0),
securityLevelId(PublicLevelID),
superClass(0), subClasses(NULL)
{
subClasses = new ObjectClassSet(NULL);
@@ -456,7 +456,7 @@
// Display inheritance
cout << " Parent Class Handle: " << superClass << endl ;
- cout << " Security Level: " << levelId << endl ;
+ cout << " Security Level: " << securityLevelId << endl ;
cout << " " << subClasses->size() << " Child(s):" << endl ;
cout << " Subclasses handles:" ;
ObjectClassSet::namedOC_const_iterator i ;
@@ -827,15 +827,14 @@
return true ;
}
-// ----------------------------------------------------------------------------
-//! A class' LevelID can only be increased.
+// A class' LevelID can only be increased.
void
-ObjectClass::setLevelId(SecurityLevelID new_levelID)
+ObjectClass::setSecurityLevelId(SecurityLevelID new_levelID) throw
(SecurityError)
{
- if (!server->dominates(new_levelID, levelId))
+ if (!server->dominates(new_levelID, securityLevelId))
throw SecurityError("Attempt to lower object class level.");
- levelId = new_levelID ;
+ securityLevelId = new_levelID ;
}
// ----------------------------------------------------------------------------
@@ -1819,4 +1818,4 @@
} // namespace certi
-// $Id: ObjectClass.cc,v 3.54 2008/10/30 16:01:38 erk Exp $
+// $Id: ObjectClass.cc,v 3.55 2008/10/31 13:50:25 erk Exp $
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [certi-cvs] certi/libCERTI fed.cc RootObject.hh ObjectClass...,
certi-cvs <=