#define Maxlst 64
-static const Standard_Integer acceptvoid = 0;
-
// ---------- Fonctions Utilitaires ----------
//! Convert unsigned character to hexadecimal system,
Standard_CString errmess = "Parameter n0.%d (%s) not a LIST";
Sprintf(txtmes, errmess, nump, mess);
- if (acceptvoid && isvoid)
- ach->AddWarning(txtmes, errmess);
- else
- {
- ach->AddFail(txtmes, errmess);
- return Standard_False;
- }
- return Standard_True;
+ ach->AddFail(txtmes, errmess);
+ return Standard_False;
}
// ... Utilities for LateBinding
{
char txtmes[200];
Standard_CString errmess = nullptr; // Null if no error
- Standard_Boolean warn = Standard_False;
if (nump > 0 && nump <= NbParams(num))
{
const Interface_FileParameter& FP = Param(num, nump);
Standard_Integer nent = FP.EntityNumber();
if (FP.ParamType() == Interface_ParamIdent)
{
- warn = (acceptvoid > 0);
if (nent > 0)
{
Handle(Standard_Transient) entent = BoundEntity(nent);
}
else
{
- if (acceptvoid && FP.ParamType() == Interface_ParamVoid)
- warn = Standard_True;
errmess = "Parameter n0.%d (%s) not an Entity";
}
}
else
{
- warn = (acceptvoid > 0);
errmess = "Parameter n0.%d (%s) absent";
}
return Standard_True;
Sprintf(txtmes, errmess, nump, mess);
- if (warn)
- ach->AddWarning(txtmes, errmess);
- else
- ach->AddFail(txtmes, errmess);
+ ach->AddFail(txtmes, errmess);
return Standard_False;
}
{
char txtmes[200];
Standard_CString errmess = nullptr; // Null if no error
- Standard_Boolean warn = Standard_False;
if (nump > 0 && nump <= NbParams(num))
{
const Interface_FileParameter& FP = Param(num, nump);
Standard_Integer nent = FP.EntityNumber();
if (FP.ParamType() == Interface_ParamIdent)
{
- warn = (acceptvoid > 0);
if (nent > 0)
{
Handle(Standard_Transient) entent = BoundEntity(nent);
}
else if (FP.ParamType() == Interface_ParamVoid)
{
- if (acceptvoid)
- warn = Standard_True;
errmess = "Parameter n0.%d (%s) not an Entity";
}
else
}
else
{
- warn = (acceptvoid > 0);
errmess = "Parameter n0.%d (%s) absent";
}
return Standard_True;
Sprintf(txtmes, errmess, nump, mess);
- if (warn)
- ach->AddWarning(txtmes, errmess);
- else
- ach->AddFail(txtmes, errmess);
+ ach->AddFail(txtmes, errmess);
return Standard_False;
}
{
char txtmes[200];
Standard_CString errmess = nullptr; // Null if no error
- Standard_Boolean warn = Standard_False;
if (nump > 0 && nump <= NbParams(num))
{
const Interface_FileParameter& FP = Param(num, nump);
{
val =
static_cast<Standard_Integer>(std::round(Interface_FileReaderData::Fastof(FP.CValue())));
- if (acceptvoid)
- warn = Standard_True;
errmess = "Parameter n0.%d (%s) was rounded";
}
if (FP.ParamType() != Interface_ParamInteger && FP.ParamType() != Interface_ParamReal)
return Standard_True;
Sprintf(txtmes, errmess, nump, mess);
- if (warn)
- ach->AddWarning(txtmes, errmess);
- else
- ach->AddFail(txtmes, errmess);
+ ach->AddFail(txtmes, errmess);
return Standard_False;
}
{
char txtmes[200];
Standard_CString errmess = nullptr; // Null if no error
- Standard_Boolean warn = Standard_False;
if (nump > 0 && nump <= NbParams(num))
{
const Interface_FileParameter& FP = Param(num, nump);
}
else
{
- if (acceptvoid && FP.ParamType() == Interface_ParamVoid)
- warn = Standard_True;
errmess = "Parameter n0.%d (%s) not a quoted String";
}
}
return Standard_True;
Sprintf(txtmes, errmess, nump, mess);
- if (warn)
- ach->AddWarning(txtmes, errmess);
- else
- ach->AddFail(txtmes, errmess);
+ ach->AddFail(txtmes, errmess);
return Standard_False;
}
{
char txtmes[200];
Standard_CString errmess = nullptr; // Null if no error
- Standard_Boolean warn = Standard_False;
if (nump > 0 && nump <= NbParams(num))
{
const Interface_FileParameter& FP = Param(num, nump);
if (FP.ParamType() == Interface_ParamEnum)
{
text = FP.CValue();
- warn = (acceptvoid > 0);
}
else if (FP.ParamType() == Interface_ParamVoid)
{
errmess = "Parameter n0.%d (%s) : Undefined Enumeration not allowed";
- warn = (acceptvoid > 0);
}
else
errmess = "Parameter n0.%d (%s) not an Enumeration";
return Standard_True;
Sprintf(txtmes, errmess, nump, mess);
- if (warn)
- ach->AddWarning(txtmes, errmess);
- else
- ach->AddFail(txtmes, errmess);
+ ach->AddFail(txtmes, errmess);
return Standard_False;
}
// resume with ReadEnumParam?
char txtmes[200];
Standard_CString errmess = nullptr; // Null if no error
- Standard_Boolean warn = Standard_False;
if (nump > 0 && nump <= NbParams(num))
{
const Interface_FileParameter& FP = Param(num, nump);
return Standard_True;
else
errmess = "Parameter n0.%d (%s) : Incorrect Enumeration Value";
- warn = (acceptvoid > 0);
}
else if (FP.ParamType() == Interface_ParamVoid)
{
val = enumtool.NullValue();
if (val < 0)
errmess = "Parameter n0.%d (%s) : Undefined Enumeration not allowed";
- warn = (acceptvoid > 0);
}
else
errmess = "Parameter n0.%d (%s) not an Enumeration";
return Standard_True;
Sprintf(txtmes, errmess, nump, mess);
- if (warn)
- ach->AddWarning(txtmes, errmess);
- else
- ach->AddFail(txtmes, errmess);
+ ach->AddFail(txtmes, errmess);
return Standard_False;
}
return Standard_True;
else
errmess = "Parameter n0.%d (%s) not Derived";
- if (acceptvoid)
- warn = Standard_True;
}
else
errmess = "Parameter n0.%d (%s) absent";