Commit 491400b0 authored by hrchilds's avatar hrchilds

Update from July 15, 2003

git-svn-id: http://visit.ilight.com/svn/visit/trunk/src@34 18c085ea-50e0-402c-830e-de6fd14e8384
parent 5f4804b8
This diff is collapsed.
......@@ -14,7 +14,7 @@
// Notes: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue Jun 24 13:14:21 PST 2003
// Creation: Tue Jul 15 13:47:28 PST 2003
//
// Modifications:
//
......
......@@ -12,18 +12,22 @@ static const char *ContourMethod_strings[] = {
std::string
ContourOpAttributes::ContourMethod_ToString(ContourOpAttributes::ContourMethod t)
{
return ContourMethod_strings[(int)t];
int index = int(t);
if(index < 0 || index >= 3) index = 0;
return ContourMethod_strings[index];
}
std::string
ContourOpAttributes::ContourMethod_ToString(int t)
{
return ContourMethod_strings[t];
int index = (t < 0 || t >= 3) ? 0 : t;
return ContourMethod_strings[index];
}
bool
ContourOpAttributes::ContourMethod_FromString(const std::string &s, ContourOpAttributes::ContourMethod &val)
{
val = ContourOpAttributes::Level;
for(int i = 0; i < 3; ++i)
{
if(s == ContourMethod_strings[i])
......@@ -45,18 +49,22 @@ static const char *ContourScaling_strings[] = {
std::string
ContourOpAttributes::ContourScaling_ToString(ContourOpAttributes::ContourScaling t)
{
return ContourScaling_strings[(int)t];
int index = int(t);
if(index < 0 || index >= 2) index = 0;
return ContourScaling_strings[index];
}
std::string
ContourOpAttributes::ContourScaling_ToString(int t)
{
return ContourScaling_strings[t];
int index = (t < 0 || t >= 2) ? 0 : t;
return ContourScaling_strings[index];
}
bool
ContourOpAttributes::ContourScaling_FromString(const std::string &s, ContourOpAttributes::ContourScaling &val)
{
val = ContourOpAttributes::Linear;
for(int i = 0; i < 2; ++i)
{
if(s == ContourScaling_strings[i])
......@@ -77,7 +85,7 @@ ContourOpAttributes::ContourScaling_FromString(const std::string &s, ContourOpAt
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......@@ -102,7 +110,7 @@ ContourOpAttributes::ContourOpAttributes() : AttributeSubject("id*d*ibbddis")
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......@@ -133,7 +141,7 @@ ContourOpAttributes::ContourOpAttributes(const ContourOpAttributes &obj) : Attri
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......@@ -153,7 +161,7 @@ ContourOpAttributes::~ContourOpAttributes()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......@@ -185,7 +193,7 @@ ContourOpAttributes::operator = (const ContourOpAttributes &obj)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......@@ -216,7 +224,7 @@ ContourOpAttributes::operator == (const ContourOpAttributes &obj) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......@@ -237,7 +245,7 @@ ContourOpAttributes::operator != (const ContourOpAttributes &obj) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......@@ -258,7 +266,7 @@ ContourOpAttributes::TypeName() const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......@@ -286,7 +294,7 @@ ContourOpAttributes::CopyAttributes(const AttributeGroup *atts)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......@@ -312,7 +320,7 @@ ContourOpAttributes::CreateCompatible(const std::string &tname) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......@@ -346,7 +354,7 @@ ContourOpAttributes::SelectAll()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......@@ -442,7 +450,7 @@ ContourOpAttributes::CreateNode(DataNode *parentNode, bool forceAdd)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......@@ -469,7 +477,11 @@ ContourOpAttributes::SetFromNode(DataNode *parentNode)
{
// Allow enums to be int or string in the config file
if(node->GetNodeType() == INT_NODE)
SetContourMethod(ContourMethod(node->AsInt()));
{
int ival = node->AsInt();
if(ival >= 0 && ival < 3)
SetContourMethod(ContourMethod(ival));
}
else if(node->GetNodeType() == STRING_NODE)
{
ContourMethod value;
......@@ -489,7 +501,11 @@ ContourOpAttributes::SetFromNode(DataNode *parentNode)
{
// Allow enums to be int or string in the config file
if(node->GetNodeType() == INT_NODE)
SetScaling(ContourScaling(node->AsInt()));
{
int ival = node->AsInt();
if(ival >= 0 && ival < 2)
SetScaling(ContourScaling(ival));
}
else if(node->GetNodeType() == STRING_NODE)
{
ContourScaling value;
......@@ -692,7 +708,7 @@ ContourOpAttributes::SelectVariable()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......@@ -726,7 +742,7 @@ ContourOpAttributes::GetFieldName(int index) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......@@ -760,7 +776,7 @@ ContourOpAttributes::GetFieldType(int index) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......@@ -794,7 +810,7 @@ ContourOpAttributes::GetFieldTypeName(int index) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......
......@@ -13,7 +13,7 @@
// Notes: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:47 PST 2003
// Creation: Tue Jul 15 13:47:30 PST 2003
//
// Modifications:
//
......
......@@ -13,18 +13,22 @@ static const char *ExprType_strings[] = {
std::string
Expression::ExprType_ToString(Expression::ExprType t)
{
return ExprType_strings[(int)t];
int index = int(t);
if(index < 0 || index >= 6) index = 0;
return ExprType_strings[index];
}
std::string
Expression::ExprType_ToString(int t)
{
return ExprType_strings[t];
int index = (t < 0 || t >= 6) ? 0 : t;
return ExprType_strings[index];
}
bool
Expression::ExprType_FromString(const std::string &s, Expression::ExprType &val)
{
val = Expression::Unknown;
for(int i = 0; i < 6; ++i)
{
if(s == ExprType_strings[i])
......@@ -45,7 +49,7 @@ Expression::ExprType_FromString(const std::string &s, Expression::ExprType &val)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......@@ -68,7 +72,7 @@ Expression::Expression() : AttributeSubject("ssbi")
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......@@ -93,7 +97,7 @@ Expression::Expression(const Expression &obj) : AttributeSubject("ssbi")
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......@@ -113,7 +117,7 @@ Expression::~Expression()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......@@ -139,7 +143,7 @@ Expression::operator = (const Expression &obj)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......@@ -164,7 +168,7 @@ Expression::operator == (const Expression &obj) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......@@ -185,7 +189,7 @@ Expression::operator != (const Expression &obj) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......@@ -206,7 +210,7 @@ Expression::TypeName() const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......@@ -234,7 +238,7 @@ Expression::CopyAttributes(const AttributeGroup *atts)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......@@ -260,7 +264,7 @@ Expression::CreateCompatible(const std::string &tname) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......@@ -288,7 +292,7 @@ Expression::SelectAll()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......@@ -348,7 +352,7 @@ Expression::CreateNode(DataNode *parentNode, bool forceAdd)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......@@ -375,7 +379,11 @@ Expression::SetFromNode(DataNode *parentNode)
{
// Allow enums to be int or string in the config file
if(node->GetNodeType() == INT_NODE)
SetType(ExprType(node->AsInt()));
{
int ival = node->AsInt();
if(ival >= 0 && ival < 6)
SetType(ExprType(ival));
}
else if(node->GetNodeType() == STRING_NODE)
{
ExprType value;
......@@ -486,7 +494,7 @@ Expression::SelectDefinition()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......@@ -514,7 +522,7 @@ Expression::GetFieldName(int index) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......@@ -542,7 +550,7 @@ Expression::GetFieldType(int index) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......@@ -570,7 +578,7 @@ Expression::GetFieldTypeName(int index) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......
......@@ -13,7 +13,7 @@
// Notes: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:49 PST 2003
// Creation: Tue Jul 15 13:47:32 PST 2003
//
// Modifications:
//
......
......@@ -12,18 +12,22 @@ static const char *LightType_strings[] = {
std::string
LightAttributes::LightType_ToString(LightAttributes::LightType t)
{
return LightType_strings[(int)t];
int index = int(t);
if(index < 0 || index >= 3) index = 0;
return LightType_strings[index];
}
std::string
LightAttributes::LightType_ToString(int t)
{
return LightType_strings[t];
int index = (t < 0 || t >= 3) ? 0 : t;
return LightType_strings[index];
}
bool
LightAttributes::LightType_FromString(const std::string &s, LightAttributes::LightType &val)
{
val = LightAttributes::Ambient;
for(int i = 0; i < 3; ++i)
{
if(s == LightType_strings[i])
......@@ -44,7 +48,7 @@ LightAttributes::LightType_FromString(const std::string &s, LightAttributes::Lig
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......@@ -70,7 +74,7 @@ LightAttributes::LightAttributes() : AttributeSubject("biDad"),
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......@@ -99,7 +103,7 @@ LightAttributes::LightAttributes(const LightAttributes &obj) : AttributeSubject(
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......@@ -119,7 +123,7 @@ LightAttributes::~LightAttributes()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......@@ -149,7 +153,7 @@ LightAttributes::operator = (const LightAttributes &obj)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......@@ -182,7 +186,7 @@ LightAttributes::operator == (const LightAttributes &obj) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......@@ -203,7 +207,7 @@ LightAttributes::operator != (const LightAttributes &obj) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......@@ -224,7 +228,7 @@ LightAttributes::TypeName() const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......@@ -252,7 +256,7 @@ LightAttributes::CopyAttributes(const AttributeGroup *atts)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......@@ -278,7 +282,7 @@ LightAttributes::CreateCompatible(const std::string &tname) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......@@ -307,7 +311,7 @@ LightAttributes::SelectAll()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......@@ -379,7 +383,7 @@ LightAttributes::CreateNode(DataNode *parentNode, bool forceAdd)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......@@ -402,7 +406,11 @@ LightAttributes::SetFromNode(DataNode *parentNode)
{
// Allow enums to be int or string in the config file
if(node->GetNodeType() == INT_NODE)
SetType(LightType(node->AsInt()));
{
int ival = node->AsInt();
if(ival >= 0 && ival < 3)
SetType(LightType(ival));
}
else if(node->GetNodeType() == STRING_NODE)
{
LightType value;
......@@ -534,7 +542,7 @@ LightAttributes::SelectColor()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......@@ -563,7 +571,7 @@ LightAttributes::GetFieldName(int index) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......@@ -592,7 +600,7 @@ LightAttributes::GetFieldType(int index) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......@@ -621,7 +629,7 @@ LightAttributes::GetFieldTypeName(int index) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......
......@@ -14,7 +14,7 @@
// Notes: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:55 PST 2003
// Creation: Tue Jul 15 13:47:35 PST 2003
//
// Modifications:
//
......
......@@ -12,18 +12,22 @@ static const char *Severity_strings[] = {
std::string
MessageAttributes::Severity_ToString(MessageAttributes::Severity t)
{
return Severity_strings[(int)t];
int index = int(t);
if(index < 0 || index >= 3) index = 0;
return Severity_strings[index];
}
std::string
MessageAttributes::Severity_ToString(int t)
{
return Severity_strings[t];
int index = (t < 0 || t >= 3) ? 0 : t;
return Severity_strings[index];
}
bool
MessageAttributes::Severity_FromString(const std::string &s, MessageAttributes::Severity &val)
{
val = MessageAttributes::Error;
for(int i = 0; i < 3; ++i)
{
if(s == Severity_strings[i])
......@@ -44,7 +48,7 @@ MessageAttributes::Severity_FromString(const std::string &s, MessageAttributes::
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:58 PST 2003
// Creation: Tue Jul 15 13:47:37 PST 2003
//
// Modifications:
//
......@@ -65,7 +69,7 @@ MessageAttributes::MessageAttributes() : AttributeSubject("si")
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:58 PST 2003
// Creation: Tue Jul 15 13:47:37 PST 2003
//
// Modifications:
//
......@@ -88,7 +92,7 @@ MessageAttributes::MessageAttributes(const MessageAttributes &obj) : AttributeSu
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:58 PST 2003
// Creation: Tue Jul 15 13:47:37 PST 2003
//
// Modifications:
//
......@@ -108,7 +112,7 @@ MessageAttributes::~MessageAttributes()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:58 PST 2003
// Creation: Tue Jul 15 13:47:37 PST 2003
//
// Modifications:
//
......@@ -132,7 +136,7 @@ MessageAttributes::operator = (const MessageAttributes &obj)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:58 PST 2003
// Creation: Tue Jul 15 13:47:37 PST 2003
//
// Modifications:
//
......@@ -155,7 +159,7 @@ MessageAttributes::operator == (const MessageAttributes &obj) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:58 PST 2003
// Creation: Tue Jul 15 13:47:37 PST 2003
//
// Modifications:
//
......@@ -176,7 +180,7 @@ MessageAttributes::operator != (const MessageAttributes &obj) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:58 PST 2003
// Creation: Tue Jul 15 13:47:37 PST 2003
//
// Modifications:
//
......@@ -197,7 +201,7 @@ MessageAttributes::TypeName() const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:58 PST 2003
// Creation: Tue Jul 15 13:47:37 PST 2003
//
// Modifications:
//
......@@ -225,7 +229,7 @@ MessageAttributes::CopyAttributes(const AttributeGroup *atts)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:58 PST 2003
// Creation: Tue Jul 15 13:47:37 PST 2003
//
// Modifications:
//
......@@ -251,7 +255,7 @@ MessageAttributes::CreateCompatible(const std::string &tname) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:58 PST 2003
// Creation: Tue Jul 15 13:47:37 PST 2003
//
// Modifications:
//
......@@ -277,7 +281,7 @@ MessageAttributes::SelectAll()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:58 PST 2003
// Creation: Tue Jul 15 13:47:37 PST 2003
//
// Modifications:
//
......@@ -325,7 +329,7 @@ MessageAttributes::CreateNode(DataNode *parentNode, bool forceAdd)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Tue May 20 13:39:58 PST 2003
// Creation: Tue Jul 15 13:47:37 PST 2003
//
// Modifications:
//
......@@ -348,7 +352,11 @@ MessageAttributes::SetFromNode(DataNode *parentNode)
{
// Allow enums to be int or string in the config file
if(node->GetNodeType() == INT_NODE)
SetSeverity(Severity(node->AsInt()));
{
int ival = node->AsInt();
if(ival >= 0 && ival < 3)
SetSeverity(Severity(ival));
}
else if(node->GetNodeType() == STRING_NODE)
{
Severity value;
......@@ -421,7 +429,7 @@ MessageAttributes::SelectText()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts