void AdvApp2Var_ApproxAFunc2Var::Dump(Standard_OStream& o) const
{
Standard_Integer iesp=1,NbKU,NbKV,ik;
- o<<std::endl;
- if (!myHasResult) { o<<"No result"<<std::endl; }
+ o<<'\n';
+ if (!myHasResult) { o<<"No result"<<'\n'; }
else {
o<<"There is a result";
if (myDone) {
- o<<" within the requested tolerance "<<my3DTolerances->Value(iesp)<<std::endl;
+ o<<" within the requested tolerance "<<my3DTolerances->Value(iesp)<<'\n';
}
else if (my3DMaxError->Value(iesp)>my3DTolerances->Value(iesp)) {
- o<<" WITHOUT the requested tolerance "<<my3DTolerances->Value(iesp)<<std::endl;
+ o<<" WITHOUT the requested tolerance "<<my3DTolerances->Value(iesp)<<'\n';
}
else {
- o<<" WITHOUT the requested continuities "<<std::endl;
+ o<<" WITHOUT the requested continuities "<<'\n';
}
- o<<std::endl;
- o<<"Result max error :"<<my3DMaxError->Value(iesp)<<std::endl;
- o<<"Result average error :"<<my3DAverageError->Value(iesp)<<std::endl;
- o<<"Result max error on U frontiers :"<<my3DUFrontError->Value(iesp)<<std::endl;
- o<<"Result max error on V frontiers :"<<my3DVFrontError->Value(iesp)<<std::endl;
- o<<std::endl;
+ o<<'\n';
+ o<<"Result max error :"<<my3DMaxError->Value(iesp)<<'\n';
+ o<<"Result average error :"<<my3DAverageError->Value(iesp)<<'\n';
+ o<<"Result max error on U frontiers :"<<my3DUFrontError->Value(iesp)<<'\n';
+ o<<"Result max error on V frontiers :"<<my3DVFrontError->Value(iesp)<<'\n';
+ o<<'\n';
o<<"Degree of Bezier patches in U : "<<myDegreeInU
- <<" in V : "<<myDegreeInV<<std::endl;
- o<<std::endl;
+ <<" in V : "<<myDegreeInV<<'\n';
+ o<<'\n';
Handle(Geom_BSplineSurface) S
= Handle(Geom_BSplineSurface)::DownCast(mySurfaces->Value(iesp));
o<<"Number of poles in U : "<<S->NbUPoles()
- <<" in V : "<<S->NbVPoles()<<std::endl;
- o<<std::endl;
+ <<" in V : "<<S->NbVPoles()<<'\n';
+ o<<'\n';
NbKU = S->NbUKnots();
NbKV = S->NbVKnots();
- o<<"Number of knots in U : "<<NbKU<<std::endl;
+ o<<"Number of knots in U : "<<NbKU<<'\n';
for (ik=1;ik<=NbKU;ik++) {
- o<<" "<<ik<<" : "<<S->UKnot(ik)<<" mult : "<<S->UMultiplicity(ik)<<std::endl;
+ o<<" "<<ik<<" : "<<S->UKnot(ik)<<" mult : "<<S->UMultiplicity(ik)<<'\n';
}
- o<<std::endl;
- o<<"Number of knots in V : "<<NbKV<<std::endl;
+ o<<'\n';
+ o<<"Number of knots in V : "<<NbKV<<'\n';
for (ik=1;ik<=NbKV;ik++) {
- o<<" "<<ik<<" : "<<S->VKnot(ik)<<" mult : "<<S->VMultiplicity(ik)<<std::endl;
+ o<<" "<<ik<<" : "<<S->VKnot(ik)<<" mult : "<<S->VMultiplicity(ik)<<'\n';
}
- o<<std::endl;
+ o<<'\n';
}
}
void AdvApprox_ApproxAFunction::Dump(Standard_OStream& o) const
{
Standard_Integer ii;
- o << "Dump of ApproxAFunction" << std::endl;
+ o << "Dump of ApproxAFunction" << '\n';
if (myNumSubSpaces[0] > 0) {
- o << "Error(s) 1d = " << std::endl;
+ o << "Error(s) 1d = " << '\n';
for (ii=1; ii <= myNumSubSpaces[0]; ii++) {
- o << " " << MaxError(1, ii) << std::endl;
+ o << " " << MaxError(1, ii) << '\n';
}
}
if (myNumSubSpaces[1] > 0) {
- o << "Error(s) 2d = " << std::endl;
+ o << "Error(s) 2d = " << '\n';
for (ii=1; ii <= myNumSubSpaces[1]; ii++) {
- o << " " << MaxError(2, ii) << std::endl;
+ o << " " << MaxError(2, ii) << '\n';
}
}
if (myNumSubSpaces[2] > 0) {
- o << "Error(s) 3d = " << std::endl;
+ o << "Error(s) 3d = " << '\n';
for (ii=1; ii <= myNumSubSpaces[2]; ii++) {
- o << " " << MaxError(3, ii) << std::endl;
+ o << " " << MaxError(3, ii) << '\n';
}
}
}
void AdvApprox_SimpleApprox::Dump(Standard_OStream& o) const
{
Standard_Integer ii;
- o << "Dump of SimpleApprox " << std::endl;
+ o << "Dump of SimpleApprox " << '\n';
for (ii=1; ii <= myTotalNumSS; ii++) {
- o << "Error " << MaxError(ii) << std::endl;
+ o << "Error " << MaxError(ii) << '\n';
}
}
void AppDef_MultiLine::Dump(Standard_OStream& o) const
{
- o << "AppDef_MultiLine dump:" << std::endl;
+ o << "AppDef_MultiLine dump:" << '\n';
// AppDef_MultiPointConstraint MP = tabMult->Value(1);
- o << "It contains " << tabMult->Length() << " MultiPointConstraint"<< std::endl;
+ o << "It contains " << tabMult->Length() << " MultiPointConstraint"<< '\n';
// o << MP->NbPoints() << " 3d and " << MP->NbPoints2d() << std::endl;
}
void AppDef_MultiPointConstraint::Dump(Standard_OStream& o) const
{
- o << "AppDef_MultiPointConstraint dump:" << std::endl;
+ o << "AppDef_MultiPointConstraint dump:" << '\n';
}
//
void AppDef_Variational::Dump(Standard_OStream& o) const
{
- o << " \nVariational Smoothing " << std::endl;
- o << " Number of multipoints " << myNbPoints << std::endl;
- o << " Number of 2d par multipoint " << myNbP2d << std::endl;
- o << " Nombre of 3d par multipoint " << myNbP3d << std::endl;
- o << " Number of PassagePoint " << myNbPassPoints << std::endl;
- o << " Number of TangencyPoints " << myNbTangPoints << std::endl;
- o << " Number of CurvaturePoints " << myNbCurvPoints << std::endl;
+ o << " \nVariational Smoothing " << '\n';
+ o << " Number of multipoints " << myNbPoints << '\n';
+ o << " Number of 2d par multipoint " << myNbP2d << '\n';
+ o << " Nombre of 3d par multipoint " << myNbP3d << '\n';
+ o << " Number of PassagePoint " << myNbPassPoints << '\n';
+ o << " Number of TangencyPoints " << myNbTangPoints << '\n';
+ o << " Number of CurvaturePoints " << myNbCurvPoints << '\n';
o << " \nTolerance " << o.setf(std::ios::scientific) << std::setprecision(3) << std::setw(9) << myTolerance;
- if ( WithMinMax()) { o << " as Max Error." << std::endl;}
- else { o << " as size Error." << std::endl;}
+ if ( WithMinMax()) { o << " as Max Error." << '\n';}
+ else { o << " as size Error." << '\n';}
o << "CriteriumWeights : " << myPercent[0] << " , "
- << myPercent[1] << " , " << myPercent[2] << std::endl;
+ << myPercent[1] << " , " << myPercent[2] << '\n';
if (myIsDone ) {
- o << " MaxError " << std::setprecision(3) << std::setw(9) << myMaxError << std::endl;
- o << " Index of MaxError " << myMaxErrorIndex << std::endl;
- o << " Average Error " << std::setprecision(3) << std::setw(9) << myAverageError << std::endl;
- o << " Quadratic Error " << std::setprecision(3) << std::setw(9) << myCriterium[0] << std::endl;
- o << " Tension Criterium " << std::setprecision(3) << std::setw(9) << myCriterium[1] << std::endl;
- o << " Flexion Criterium " << std::setprecision(3) << std::setw(9) << myCriterium[2] << std::endl;
- o << " Jerk Criterium " << std::setprecision(3) << std::setw(9) << myCriterium[3] << std::endl;
- o << " NbSegments " << myKnots->Length()-1 << std::endl;
+ o << " MaxError " << std::setprecision(3) << std::setw(9) << myMaxError << '\n';
+ o << " Index of MaxError " << myMaxErrorIndex << '\n';
+ o << " Average Error " << std::setprecision(3) << std::setw(9) << myAverageError << '\n';
+ o << " Quadratic Error " << std::setprecision(3) << std::setw(9) << myCriterium[0] << '\n';
+ o << " Tension Criterium " << std::setprecision(3) << std::setw(9) << myCriterium[1] << '\n';
+ o << " Flexion Criterium " << std::setprecision(3) << std::setw(9) << myCriterium[2] << '\n';
+ o << " Jerk Criterium " << std::setprecision(3) << std::setw(9) << myCriterium[3] << '\n';
+ o << " NbSegments " << myKnots->Length()-1 << '\n';
}
else
{
o << (myIsOverConstr
? " The problem is overconstraint"
- : " Error in approximation") << std::endl;
+ : " Error in approximation") << '\n';
}
}
void AppParCurves_MultiBSpCurve::Dump(Standard_OStream& o) const
{
- o << "AppParCurves_MultiBSpCurve dump:" << std::endl;
- o << " It contains " << NbCurves() << " BSpline curves "<< std::endl;
- o << " The poles are: " << std::endl;
+ o << "AppParCurves_MultiBSpCurve dump:" << '\n';
+ o << " It contains " << NbCurves() << " BSpline curves "<< '\n';
+ o << " The poles are: " << '\n';
/* for (Standard_Integer i = 1; i <= NbCurves(); i++) {
o << " Curve No. " << i << std::endl;
if (Dimension(i) == 3) {
void AppParCurves_MultiCurve::Dump(Standard_OStream& o) const
{
- o << "AppParCurves_MultiCurve dump:" << std::endl;
- o << " It contains " << NbCurves() << " Bezier curves of degree " << tabPoint->Length()-1 << std::endl;
- o << " The poles are: " << std::endl;
+ o << "AppParCurves_MultiCurve dump:" << '\n';
+ o << " It contains " << NbCurves() << " Bezier curves of degree " << tabPoint->Length()-1 << '\n';
+ o << " The poles are: " << '\n';
/* for (Standard_Integer i = 1; i <= NbCurves(); i++) {
o << " Curve No. " << i << std::endl;
if (Dimension(i) == 3) {
void AppParCurves_MultiPoint::Dump(Standard_OStream& o) const
{
- o << "AppParCurves_MultiPoint dump:" << std::endl;
+ o << "AppParCurves_MultiPoint dump:" << '\n';
const Standard_Integer aNbPnts3D = NbPoints(),
aNbPnts2D = NbPoints2d();
- o << "It contains " << aNbPnts3D << " 3d points and " << aNbPnts2D <<" 2d points." << std::endl;
+ o << "It contains " << aNbPnts3D << " 3d points and " << aNbPnts2D <<" 2d points." << '\n';
if(aNbPnts3D > 0)
{
for(Standard_Integer i = tabPoint->Lower(); i <= tabPoint->Upper(); i++)
{
- o << "3D-Point #" << i << std::endl;
+ o << "3D-Point #" << i << '\n';
- o << " Pole x = " << (tabPoint->Value(i)/*->Point(j)*/).X() << std::endl;
- o << " Pole y = " << (tabPoint->Value(i)/*->Point(j)*/).Y() << std::endl;
- o << " Pole z = " << (tabPoint->Value(i)/*->Point(j)*/).Z() << std::endl;
+ o << " Pole x = " << (tabPoint->Value(i)/*->Point(j)*/).X() << '\n';
+ o << " Pole y = " << (tabPoint->Value(i)/*->Point(j)*/).Y() << '\n';
+ o << " Pole z = " << (tabPoint->Value(i)/*->Point(j)*/).Z() << '\n';
}
}
{
for(Standard_Integer i = tabPoint2d->Lower(); i <= tabPoint2d->Upper(); i++)
{
- o << "2D-Point #" << i << std::endl;
+ o << "2D-Point #" << i << '\n';
- o << " Pole x = " << (tabPoint2d->Value(i)/*->Point2d(j)*/).X() << std::endl;
- o << " Pole y = " << (tabPoint2d->Value(i)/*->Point2d(j)*/).Y() << std::endl;
+ o << " Pole x = " << (tabPoint2d->Value(i)/*->Point2d(j)*/).X() << '\n';
+ o << " Pole y = " << (tabPoint2d->Value(i)/*->Point2d(j)*/).Y() << '\n';
}
}
}
void Approx_Curve3d::Dump(Standard_OStream& o) const
{
- o << "******* Dump of ApproxCurve *******" << std::endl;
- o << "*******Degree " << Curve()->Degree() << std::endl;
- o << "*******NbSegments " << Curve()->NbKnots() - 1 << std::endl;
- o << "*******Error " << MaxError() << std::endl;
+ o << "******* Dump of ApproxCurve *******" << '\n';
+ o << "*******Degree " << Curve()->Degree() << '\n';
+ o << "*******NbSegments " << Curve()->NbKnots() - 1 << '\n';
+ o << "*******Error " << MaxError() << '\n';
}
void Approx_CurvilinearParameter::Dump(Standard_OStream& o) const
{
- o << "Dump of Approx_CurvilinearParameter" << std::endl;
+ o << "Dump of Approx_CurvilinearParameter" << '\n';
if (myCase==2 || myCase==3)
- o << "myMaxError2d1 = " << myMaxError2d1 << std::endl;
+ o << "myMaxError2d1 = " << myMaxError2d1 << '\n';
if (myCase==3)
- o << "myMaxError2d2 = " << myMaxError2d2 << std::endl;
- o << "myMaxError3d = " << myMaxError3d << std::endl;
+ o << "myMaxError2d2 = " << myMaxError2d2 << '\n';
+ o << "myMaxError3d = " << myMaxError3d << '\n';
}
//=======================================================================
void Approx_SweepApproximation::Dump(Standard_OStream& o) const
{
- o << "Dump of SweepApproximation" << std::endl;
+ o << "Dump of SweepApproximation" << '\n';
if (done) {
- o << "Error 3d = " << MaxErrorOnSurf() << std::endl;
+ o << "Error 3d = " << MaxErrorOnSurf() << '\n';
if (Num2DSS>0) {
o << "Error 2d = ";
for (Standard_Integer ii=1; ii<=Num2DSS; ii++)
{ o << Max2dError(ii);
- if (ii < Num2DSS) o << " , " << std::endl;
+ if (ii < Num2DSS) o << " , " << '\n';
}
- std::cout << std::endl;
+ std::cout << '\n';
}
- o << tabVKnots->Length()-1 <<" Segment(s) of degree " << vdeg << std::endl;
+ o << tabVKnots->Length()-1 <<" Segment(s) of degree " << vdeg << '\n';
}
- else std::cout << " Not Done " << std::endl;
+ else std::cout << " Not Done " << '\n';
}
mapVertices.Add(V2);
}
}
- std::cout << " " << std::endl;
- std::cout << " Information " << std::endl;
- std::cout << " ===========================================================" << std::endl;
- std::cout << " " << std::endl;
- std::cout << " Number of input shapes : " << myOldShapes.Extent() << std::endl;
- std::cout << " Number of actual shapes : " << myNbShapes << std::endl;
- std::cout << " Number of Bounds : " << NbBounds << std::endl;
- std::cout << " Number of Sections : " << NbSections << std::endl;
- std::cout << " Number of Edges : " << mapEdges.Extent() << std::endl;
- std::cout << " Number of Vertices : " << myNbVertices << std::endl;
- std::cout << " Number of Nodes : " << mapVertices.Extent() << std::endl;
- std::cout << " Number of Free Edges : " << myFreeEdges.Extent() << std::endl;
- std::cout << " Number of Contigous Edges : " << myContigousEdges.Extent() << std::endl;
- std::cout << " Number of Multiple Edges : " << myMultipleEdges.Extent() << std::endl;
- std::cout << " Number of Degenerated Edges : " << myDegenerated.Extent() << std::endl;
- std::cout << " ===========================================================" << std::endl;
- std::cout << " " << std::endl;
+ std::cout << " " << '\n';
+ std::cout << " Information " << '\n';
+ std::cout << " ===========================================================" << '\n';
+ std::cout << " " << '\n';
+ std::cout << " Number of input shapes : " << myOldShapes.Extent() << '\n';
+ std::cout << " Number of actual shapes : " << myNbShapes << '\n';
+ std::cout << " Number of Bounds : " << NbBounds << '\n';
+ std::cout << " Number of Sections : " << NbSections << '\n';
+ std::cout << " Number of Edges : " << mapEdges.Extent() << '\n';
+ std::cout << " Number of Vertices : " << myNbVertices << '\n';
+ std::cout << " Number of Nodes : " << mapVertices.Extent() << '\n';
+ std::cout << " Number of Free Edges : " << myFreeEdges.Extent() << '\n';
+ std::cout << " Number of Contigous Edges : " << myContigousEdges.Extent() << '\n';
+ std::cout << " Number of Multiple Edges : " << myMultipleEdges.Extent() << '\n';
+ std::cout << " Number of Degenerated Edges : " << myDegenerated.Extent() << '\n';
+ std::cout << " ===========================================================" << '\n';
+ std::cout << " " << '\n';
}
//=======================================================================
if (!theShape.IsNull()) {
size_t code = TopTools_ShapeMapHasher{}(theShape);
std::cout << TopAbs::ShapeTypeToString (theShape.ShapeType()) << " : " << code
- << " " << TopAbs::ShapeOrientationToString(theShape.Orientation()) << std::endl;
+ << " " << TopAbs::ShapeOrientationToString(theShape.Orientation()) << '\n';
}
}
Standard_Integer i;
Standard_Real r1,r2;
- o<< "the distance value is : " << Value()<<std::endl;
- o<< "the number of solutions is :"<<NbSolution()<<std::endl;
- o<<std::endl;
+ o<< "the distance value is : " << Value()<<'\n';
+ o<< "the number of solutions is :"<<NbSolution()<<'\n';
+ o<<'\n';
for (i=1;i<=NbSolution();i++)
{
- o<<"solution number "<<i<<": "<< std::endl;
- o<<"the type of the solution on the first shape is " <<Standard_Integer( SupportTypeShape1(i)) <<std::endl;
- o<<"the type of the solution on the second shape is "<<Standard_Integer( SupportTypeShape2(i))<< std::endl;
- o<< "the coordinates of the point on the first shape are: "<<std::endl;
- o<<"X=" <<PointOnShape1(i).X()<<" Y=" <<PointOnShape1(i).Y()<<" Z="<<PointOnShape1(i).Z()<<std::endl;
- o<< "the coordinates of the point on the second shape are: "<<std::endl;
- o<<"X="<< PointOnShape2(i).X()<< " Y="<<PointOnShape2(i).Y()<<" Z="<< PointOnShape2(i).Z()<<std::endl;
+ o<<"solution number "<<i<<": "<< '\n';
+ o<<"the type of the solution on the first shape is " <<Standard_Integer( SupportTypeShape1(i)) <<'\n';
+ o<<"the type of the solution on the second shape is "<<Standard_Integer( SupportTypeShape2(i))<< '\n';
+ o<< "the coordinates of the point on the first shape are: "<<'\n';
+ o<<"X=" <<PointOnShape1(i).X()<<" Y=" <<PointOnShape1(i).Y()<<" Z="<<PointOnShape1(i).Z()<<'\n';
+ o<< "the coordinates of the point on the second shape are: "<<'\n';
+ o<<"X="<< PointOnShape2(i).X()<< " Y="<<PointOnShape2(i).Y()<<" Z="<< PointOnShape2(i).Z()<<'\n';
switch (SupportTypeShape1(i))
{
break;
case BRepExtrema_IsOnEdge:
ParOnEdgeS1(i,r1);
- o << "parameter on the first edge : t= " << r1 << std::endl;
+ o << "parameter on the first edge : t= " << r1 << '\n';
break;
case BRepExtrema_IsInFace:
ParOnFaceS1(i,r1,r2);
- o << "parameters on the first face : u= " << r1 << " v=" << r2 << std::endl;
+ o << "parameters on the first face : u= " << r1 << " v=" << r2 << '\n';
break;
}
switch (SupportTypeShape2(i))
break;
case BRepExtrema_IsOnEdge:
ParOnEdgeS2(i,r1);
- o << "parameter on the second edge : t=" << r1 << std::endl;
+ o << "parameter on the second edge : t=" << r1 << '\n';
break;
case BRepExtrema_IsInFace:
ParOnFaceS2(i,r1,r2);
- o << "parameters on the second face : u= " << r1 << " v=" << r2 << std::endl;
+ o << "parameters on the second face : u= " << r1 << " v=" << r2 << '\n';
break;
}
- o<<std::endl;
+ o<<'\n';
}
}
{
theStream << " Map of nodes : \n";
myNodes->Statistics(theStream);
- theStream << "\n Deleted nodes : " << myNodes->GetListOfDelNodes().Extent() << std::endl;
+ theStream << "\n Deleted nodes : " << myNodes->GetListOfDelNodes().Extent() << '\n';
theStream << "\n\n Map of Links : \n";
myLinks.Statistics(theStream);
- theStream << "\n Deleted links : " << myDelLinks.Extent() << std::endl;
+ theStream << "\n Deleted links : " << myDelLinks.Extent() << '\n';
theStream << "\n\n Map of elements : \n";
- theStream << "\n Elements : " << myElements.Size() << std::endl;
+ theStream << "\n Elements : " << myElements.Size() << '\n';
}
//=======================================================================
// Modified by skv - Thu Jan 22 18:19:05 2004 OCC4455 End
LV1.Remove(it1LV1);
LV2.Remove(it1LV2);
- if (AffichPurge) std::cout <<"Doubles removed in EdgeInter."<<std::endl;
+ if (AffichPurge) std::cout <<"Doubles removed in EdgeInter."<<'\n';
Purge = Standard_True;
break;
}
if (P1.IsEqual(P2, Tol)) {
LV1.Remove(it1LV1);
LV2.Remove(it1LV2);
- if (AffichPurge) std::cout <<"Doubles removed in EdgeInter."<<std::endl;
+ if (AffichPurge) std::cout <<"Doubles removed in EdgeInter."<<'\n';
Purge = Standard_True;
break;
}
Interpol.Perform();
if (!Interpol.IsDone())
{
- std::cout<<std::endl<<"Interpolation failed"<<std::endl;
+ std::cout<<'\n'<<"Interpolation failed"<<'\n';
}
Handle(Geom_Curve) InterCurve (Interpol.Curve());
MidEdges(i) = BRepLib_MakeEdge(InterCurve);
{
// Check the command arguments
if (n < 3) {
- std::cout<<"Error: "<<a[0]<<" - invalid number of arguments"<<std::endl;
- std::cout<<"Usage: type help "<<a[0]<<std::endl;
+ std::cout<<"Error: "<<a[0]<<" - invalid number of arguments"<<'\n';
+ std::cout<<"Usage: type help "<<a[0]<<'\n';
return 1; //TCL_ERROR
}
//read shape
const TopoDS_Shape aShape = DBRep::Get(a[2]);
if (aShape.IsNull()) {
- std::cout<<"Error: "<<a[2]<<" is null"<<std::endl;
+ std::cout<<"Error: "<<a[2]<<" is null"<<'\n';
return 1; //TCL_ERROR
}
if (aType != TopAbs_WIRE &&
aType != TopAbs_FACE)
{
- std::cout<<"Error: "<<a[2]<<" is neither wire no face"<<std::endl;
+ std::cout<<"Error: "<<a[2]<<" is neither wire no face"<<'\n';
return 1; //TCL_ERROR
}
Standard_Real aTol = 0.01;
if (n > 3)
aTol = Draw::Atof(a[3]);
- std::cout<<"Info: tolerance is set to "<<aTol<<std::endl;
+ std::cout<<"Info: tolerance is set to "<<aTol<<'\n';
TopoDS_Shape aResult;
BRepBuilderAPI_MakeFace aFaceMaker (TopoDS::Wire(aShape), OnlyPlane);
if (aFaceMaker.Error() != BRepBuilderAPI_FaceDone)
{
- std::cout<<"Error: failed to find a face for the wire "<<a[2]<<std::endl;
+ std::cout<<"Error: failed to find a face for the wire "<<a[2]<<'\n';
return 1; //TCL_ERROR
}
const TopoDS_Face& aFace = aFaceMaker.Face();
}
if (aResult.IsNull()) {
- std::cout<<"Error: could not convert "<<a[2]<<std::endl;
+ std::cout<<"Error: could not convert "<<a[2]<<'\n';
return 1; //TCL_ERROR
}
const Handle(Geom2d_Curve) c = BRep_Tool::CurveOnSurface
(TopoDS::Edge(ex.Current()),TopoDS::Face(S),f,l);
if ( c.IsNull() ) {
- std::cout << "Error: Edge " << i << " does not have pcurve" << std::endl;
+ std::cout << "Error: Edge " << i << " does not have pcurve" << '\n';
continue;
}
col = DBRep_ColorOrientation(ex.Current().Orientation());
}
Standard_Real Accuracy = aPipe.ErrorOnSurf();
- std::cout << "Accuracy of approximation = " << Accuracy << std::endl;
+ std::cout << "Accuracy of approximation = " << Accuracy << '\n';
Handle(Geom_Surface) Sur = aPipe.Surface();
TopoDS_Face F;
std::cout <<"\n\n";
BRepTools::Dump (*(TopoDS_Shape*)theShapePtr, std::cout);
- std::cout << std::endl;
+ std::cout << '\n';
return "Shape dumped to std::cout";
}
TopTools_LocationSet LS;
LS.Add(*(TopLoc_Location*)theLocationPtr);
LS.Dump(std::cout);
- std::cout <<std::endl;
+ std::cout <<'\n';
return "Location dumped to std::cout";
}
if (MKE.IsDone())
E1 = MKE.Edge();
else {
- std::cout << "Edge Not Done" << std::endl;
+ std::cout << "Edge Not Done" << '\n';
E1 = MKE.Edge();
}
if (MKE.IsDone())
E2 = MKE.Edge();
else {
- std::cout << "edge not Done" << std::endl;
+ std::cout << "edge not Done" << '\n';
E2 = MKE.Edge();
}
KPartCurve3d(E2,PC2,GS2);
}
catch(Standard_Failure const& anException) {
Standard_SStream aMsg;
- aMsg << "EXCEPTION in BinTools_Curve2dSet::WriteCurve2d(..)" << std::endl;
- aMsg << anException << std::endl;
+ aMsg << "EXCEPTION in BinTools_Curve2dSet::WriteCurve2d(..)" << '\n';
+ aMsg << anException << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
}
catch(Standard_Failure const& anException) {
C = NULL;
Standard_SStream aMsg;
- aMsg <<"EXCEPTION in BinTools_Curve2dSet::ReadCurve2d(...)" << std::endl;
- aMsg << anException << std::endl;
+ aMsg <<"EXCEPTION in BinTools_Curve2dSet::ReadCurve2d(...)" << '\n';
+ aMsg << anException << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
return IS;
IS >> buffer;
if (IS.fail() || strcmp(buffer,"Curve2ds")) {
Standard_SStream aMsg;
- aMsg << "BinTools_Curve2dSet::Read: Not a Curve2d table"<<std::endl;
+ aMsg << "BinTools_Curve2dSet::Read: Not a Curve2d table"<<'\n';
#ifdef OCCT_DEBUG
std::cout <<"Curve2dSet buffer: " << buffer << std::endl;
#endif
}
catch(Standard_Failure const& anException) {
Standard_SStream aMsg;
- aMsg << "EXCEPTION in BinTools_CurveSet::WriteCurve(..)" << std::endl;
- aMsg << anException << std::endl;
+ aMsg << "EXCEPTION in BinTools_CurveSet::WriteCurve(..)" << '\n';
+ aMsg << anException << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
}
catch(Standard_Failure const& anException) {
C = NULL;
Standard_SStream aMsg;
- aMsg <<"EXCEPTION in BinTools_CurveSet::ReadCurve(..)" << std::endl;
- aMsg << anException << std::endl;
+ aMsg <<"EXCEPTION in BinTools_CurveSet::ReadCurve(..)" << '\n';
+ aMsg << anException << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
return IS;
IS >> buffer;
if (IS.fail() || strcmp(buffer,"Curves")) {
Standard_SStream aMsg;
- aMsg << "BinTools_CurveSet::Read: Not a Curve table"<<std::endl;
+ aMsg << "BinTools_CurveSet::Read: Not a Curve table"<<'\n';
#ifdef OCCT_DEBUG
std::cout <<"CurveSet buffer: " << buffer << std::endl;
#endif
if (aDelta == 0)
{
Standard_SStream aMsg;
- aMsg << "BinTools_IStream::ReadReference: invalid reference " << (char)myLastType << std::endl;
+ aMsg << "BinTools_IStream::ReadReference: invalid reference " << (char)myLastType << '\n';
throw Standard_Failure (aMsg.str().c_str());
}
return aCurrentPos - aDelta - 1; // add a type-byte
}
catch(Standard_Failure const& anException) {
Standard_SStream aMsg;
- aMsg << "EXCEPTION in BinTools_LocatioSet::Write(..)" << std::endl;
- aMsg << anException << std::endl;
+ aMsg << "EXCEPTION in BinTools_LocatioSet::Write(..)" << '\n';
+ aMsg << anException << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
}
IS >> buffer;
if (IS.fail() || (strcmp(buffer,"Locations"))) {
Standard_SStream aMsg;
- aMsg << "BinTools_LocationSet::Read: Not a location table"<<std::endl;
+ aMsg << "BinTools_LocationSet::Read: Not a location table"<<'\n';
throw Standard_Failure(aMsg.str().c_str());
return;
}
}
} else {
Standard_SStream aMsg;
- aMsg << "Unexpected location's type = " << aTypLoc << std::endl;
+ aMsg << "Unexpected location's type = " << aTypLoc << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
if (!L.IsIdentity()) myMap.Add(L);
}
catch(Standard_Failure const& anException) {
Standard_SStream aMsg;
- aMsg << "EXCEPTION in BinTools_LocationSet::Read(..)" << std::endl;
- aMsg << anException << std::endl;
+ aMsg << "EXCEPTION in BinTools_LocationSet::Read(..)" << '\n';
+ aMsg << anException << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
}
default:
{
Standard_SStream aMsg;
- aMsg << "BinTools_ShapeReader::Read: UnExpected BRep_PointRepresentation = " << aPrsType << std::endl;
+ aMsg << "BinTools_ShapeReader::Read: UnExpected BRep_PointRepresentation = " << aPrsType << '\n';
throw Standard_Failure (aMsg.str().c_str());
}
}
default:
{
Standard_SStream aMsg;
- aMsg << "Unexpected Curve Representation =" << aPrsType << std::endl;
+ aMsg << "Unexpected Curve Representation =" << aPrsType << '\n';
throw Standard_Failure (aMsg.str().c_str());
}
default:
{
Standard_SStream aMsg;
- aMsg << "Unexpected topology type = " << aShapeType << std::endl;
+ aMsg << "Unexpected topology type = " << aShapeType << '\n';
throw Standard_Failure (aMsg.str().c_str());
break;
}
catch (Standard_Failure const& anException)
{
Standard_SStream aMsg;
- aMsg << "EXCEPTION in BinTools_ShapeReader::Read" << std::endl;
- aMsg << anException << std::endl;
+ aMsg << "EXCEPTION in BinTools_ShapeReader::Read" << '\n';
+ aMsg << anException << '\n';
throw Standard_Failure (aMsg.str().c_str());
}
// read flags and subs
}
while ( ! IS.fail());
if (IS.fail()) {
- std::cout << "BinTools_ShapeSet::Read: File was not written with this version of the topology" << std::endl;
+ std::cout << "BinTools_ShapeSet::Read: File was not written with this version of the topology" << '\n';
return;
}
IS >> buffer;
if (IS.fail() || strcmp(buffer,"TShapes")) {
Standard_SStream aMsg;
- aMsg << "BinTools_ShapeSet::Read: Not a TShape table"<<std::endl;
+ aMsg << "BinTools_ShapeSet::Read: Not a TShape table"<<'\n';
throw Standard_Failure(aMsg.str().c_str());
return;
}
}
catch(Standard_Failure const& anException) {
Standard_SStream aMsg;
- aMsg << "EXCEPTION in BinTools_ShapeSet::WriteGeometry(S,OS)" << std::endl;
- aMsg << anException << std::endl;
+ aMsg << "EXCEPTION in BinTools_ShapeSet::WriteGeometry(S,OS)" << '\n';
+ aMsg << anException << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
}
default:
{
Standard_SStream aMsg;
- aMsg << "BinTools_SurfaceSet::ReadGeometry: UnExpected BRep_PointRepresentation = " << val << std::endl;
+ aMsg << "BinTools_SurfaceSet::ReadGeometry: UnExpected BRep_PointRepresentation = " << val << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
}
default:
{
Standard_SStream aMsg;
- aMsg << "Unexpected Curve Representation =" << val << std::endl;
+ aMsg << "Unexpected Curve Representation =" << val << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
default:
{
Standard_SStream aMsg;
- aMsg << "Unexpected topology type = " << T << std::endl;
+ aMsg << "Unexpected topology type = " << T << '\n';
throw Standard_Failure(aMsg.str().c_str());
break;
}
}
catch (Standard_Failure const& anException) {
Standard_SStream aMsg;
- aMsg << "EXCEPTION in BinTools_ShapeSet::ReadGeometry(S,OS)" << std::endl;
- aMsg << anException << std::endl;
+ aMsg << "EXCEPTION in BinTools_ShapeSet::ReadGeometry(S,OS)" << '\n';
+ aMsg << anException << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
}
catch (Standard_Failure const& anException)
{
Standard_SStream aMsg;
- aMsg << "EXCEPTION in BinTools_ShapeWriter::WriteShape" << std::endl;
- aMsg << anException << std::endl;
+ aMsg << "EXCEPTION in BinTools_ShapeWriter::WriteShape" << '\n';
+ aMsg << anException << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
theStream.PutBools (aShape.Free(), aShape.Modified(), aShape.Checked(),
}
catch (Standard_Failure const& anException) {
Standard_SStream aMsg;
- aMsg << "EXCEPTION in BinTools_ShapeWriter::WriteLocation" << std::endl;
- aMsg << anException << std::endl;
+ aMsg << "EXCEPTION in BinTools_ShapeWriter::WriteLocation" << '\n';
+ aMsg << anException << '\n';
throw Standard_Failure (aMsg.str().c_str());
}
}
}
catch(Standard_Failure const& anException) {
Standard_SStream aMsg;
- aMsg << "EXCEPTION in BinTools_SurfaceSet::WriteSurface(..)" << std::endl;
- aMsg << anException << std::endl;
+ aMsg << "EXCEPTION in BinTools_SurfaceSet::WriteSurface(..)" << '\n';
+ aMsg << anException << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
}
catch(Standard_Failure const& anException) {
S = NULL;
Standard_SStream aMsg;
- aMsg << "EXCEPTION in BinTools_SurfaceSet::ReadSurface(..)" << std::endl;
- aMsg << anException << std::endl;
+ aMsg << "EXCEPTION in BinTools_SurfaceSet::ReadSurface(..)" << '\n';
+ aMsg << anException << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
return IS;
IS >> buffer;
if (IS.fail() || strcmp(buffer,"Surfaces")) {
Standard_SStream aMsg;
- aMsg << "BinTools_SurfaceSet::Read: Not a surface table"<<std::endl;
+ aMsg << "BinTools_SurfaceSet::Read: Not a surface table"<<'\n';
#ifdef OCCT_DEBUG
std::cout <<"SurfaceSet buffer: " << buffer << std::endl;
#endif
line2 = L2->Lin2d();
}
else {
- std::cout << "Not yet implemented" << std::endl;
+ std::cout << "Not yet implemented" << '\n';
}
}
else if (type1 == STANDARD_TYPE(Geom2d_Line)) {
line2 = L2->Lin2d();
}
else {
- std::cout << "Not yet implemented" << std::endl;
+ std::cout << "Not yet implemented" << '\n';
}
}
else {
- std::cout << "Not yet implemented" << std::endl;
+ std::cout << "Not yet implemented" << '\n';
}
switch(cas) {
line = L1->Lin2d();
}
else {
- std::cout << "Not yet implemented" << std::endl;
+ std::cout << "Not yet implemented" << '\n';
}
switch(cas) {
default:
{
- std::cout << "Not yet implemented" << std::endl;
+ std::cout << "Not yet implemented" << '\n';
break;
}
}
const Standard_Integer Offset) const
{
Indent (Offset);
- std::cout<<"Bisector_BisecAna"<<std::endl;
+ std::cout<<"Bisector_BisecAna"<<'\n';
Indent (Offset);
// thebisector->Dump();
}
const Standard_Integer Offset) const
{
Indent (Offset);
- std::cout <<"Bisector_BisecCC :"<<std::endl;
+ std::cout <<"Bisector_BisecCC :"<<'\n';
Indent (Offset);
// std::cout <<"Curve1 :"<<curve1<<std::endl;
// std::cout <<"Curve2 :"<<curve2<<std::endl;
- std::cout <<"Sign1 :"<<sign1<<std::endl;
- std::cout <<"Sign2 :"<<sign2<<std::endl;
+ std::cout <<"Sign1 :"<<sign1<<'\n';
+ std::cout <<"Sign2 :"<<sign2<<'\n';
- std::cout <<"Number Of Intervals :"<<startIntervals.Length()<<std::endl;
+ std::cout <<"Number Of Intervals :"<<startIntervals.Length()<<'\n';
for (Standard_Integer i = 1; i <= startIntervals.Length(); i++) {
std::cout <<"Interval number :"<<i<<"Start :"<<startIntervals.Value(i)
- <<" end :"<< endIntervals.Value(i)<<std::endl ;
+ <<" end :"<< endIntervals.Value(i)<<'\n' ;
}
- std::cout <<"Index Current Interval :"<<currentInterval<<std::endl;
+ std::cout <<"Index Current Interval :"<<currentInterval<<'\n';
}
//=============================================================================
const Standard_Integer Offset) const
{
Indent (Offset);
- std::cout <<"Bisector_BisecPC :"<<std::endl;
+ std::cout <<"Bisector_BisecPC :"<<'\n';
Indent (Offset);
- std::cout <<"Point :"<<std::endl;
- std::cout <<" X = "<<point.X()<<std::endl;
- std::cout <<" Y = "<<point.Y()<<std::endl;
- std::cout <<"Sign :"<<sign<<std::endl;
- std::cout <<"Number Of Intervals :"<<startIntervals.Length()<<std::endl;
+ std::cout <<"Point :"<<'\n';
+ std::cout <<" X = "<<point.X()<<'\n';
+ std::cout <<" Y = "<<point.Y()<<'\n';
+ std::cout <<"Sign :"<<sign<<'\n';
+ std::cout <<"Number Of Intervals :"<<startIntervals.Length()<<'\n';
for (Standard_Integer i = 1; i <= startIntervals.Length(); i++) {
std::cout <<"Interval number :"<<i<<"Start :"<<startIntervals.Value(i)
- <<" end :"<< endIntervals.Value(i)<<std::endl ;
+ <<" end :"<< endIntervals.Value(i)<<'\n' ;
}
- std::cout <<"Index Current Interval :"<<currentInterval<<std::endl;
+ std::cout <<"Index Current Interval :"<<currentInterval<<'\n';
}
//=============================================================================
void Bisector_PointOnBis::Dump() const
{
- std::cout <<"Param1 :"<<param1<<std::endl;
- std::cout <<"Param2 :"<<param2<<std::endl;
- std::cout <<"Param Bis :"<<paramBis<<std::endl;
- std::cout <<"Distance :"<<distance<<std::endl;
+ std::cout <<"Param1 :"<<param1<<'\n';
+ std::cout <<"Param2 :"<<param2<<'\n';
+ std::cout <<"Param Bis :"<<paramBis<<'\n';
+ std::cout <<"Distance :"<<distance<<'\n';
}
myRetrievableStatus = CanRetrieve(aMetaData, isAppendMode);
switch (myRetrievableStatus) {
case PCDM_RS_UnknownDocument:
- aMsg << "could not find the referenced document: " << aMetaData->Path() << "; not found." <<(char)0 << std::endl;
+ aMsg << "could not find the referenced document: " << aMetaData->Path() << "; not found." <<(char)0 << '\n';
break;
case PCDM_RS_PermissionDenied:
- aMsg << "Could not find the referenced document: " << aMetaData->Path() << "; permission denied. " <<(char)0 << std::endl;
+ aMsg << "Could not find the referenced document: " << aMetaData->Path() << "; permission denied. " <<(char)0 << '\n';
break;
case PCDM_RS_NoDocument:
- aMsg << "Document for appending is not defined." << (char)0 << std::endl;
+ aMsg << "Document for appending is not defined." << (char)0 << '\n';
break;
default:
myRetrievableStatus = PCDM_RS_OK;
myRetrievableStatus = theReader->GetStatus();
if (myRetrievableStatus > PCDM_RS_AlreadyRetrieved) {
Standard_SStream aMsg;
- aMsg << anException << std::endl;
+ aMsg << anException << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
}
myRetrievableStatus = PCDM_RS_FormatFailure;
Standard_SStream aMsg;
- aMsg << anException << std::endl;
+ aMsg << anException << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
if (myRetrievableStatus > PCDM_RS_AlreadyRetrieved)
{
Standard_SStream aMsg;
- aMsg << anException << std::endl;
+ aMsg << anException << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
}
if(myApplication.IsNull()) {
Standard_SStream aMsg;
aMsg << "this document of format "<< StorageFormat()
- << " has not yet been opened by any application. "<< std::endl;
+ << " has not yet been opened by any application. "<< '\n';
throw Standard_Failure(aMsg.str().c_str());
}
return myApplication->Resources();
if(HasVersion()) anOStream << "," << myVersion ;
anOStream << "; Physical situation: ";
anOStream << myFileName;
- anOStream << std::endl;
+ anOStream << '\n';
return anOStream;
}
Standard_OStream& CDM_MetaData::operator << (Standard_OStream& anOStream) {
if (OffsetHGuide.IsNull())
{
- std::cout<<std::endl<<"Construction of offset guide failed!"<<std::endl;
+ std::cout<<'\n'<<"Construction of offset guide failed!"<<'\n';
//exception
}
pFunc.reset(new BRepBlend_ConstThroatWithPenetration(S1,S2,OffsetHGuide));
if (OffsetHGuide.IsNull())
{
- std::cout<<std::endl<<"Construction of offset guide failed!"<<std::endl;
+ std::cout<<'\n'<<"Construction of offset guide failed!"<<'\n';
//exception
}
pFunc.reset(new BRepBlend_ConstThroatWithPenetration(S1,S2,OffsetHGuide));
if (OffsetHGuide.IsNull())
{
- std::cout<<std::endl<<"Construction of offset guide failed!"<<std::endl;
+ std::cout<<'\n'<<"Construction of offset guide failed!"<<'\n';
//exception
}
pFunc.reset(new BRepBlend_ConstThroatWithPenetration(S1,S2,OffsetHGuide));
rsnld.Perform(SFunc,X,infb,supb);
if (!rsnld.IsDone()) {
- std::cout << "Echec recherche internal points" << std::endl;
+ std::cout << "Echec recherche internal points" << '\n';
solution = Standard_True;
ok = Standard_False;
}
}
}
else { // on n est pas sur une solution
- std::cout << "Echec recherche internal points" << std::endl;
+ std::cout << "Echec recherche internal points" << '\n';
solution = Standard_True;
ok = Standard_False;
}
std::cout << "\nrouge FORWARD";
std::cout << "\nbleu REVERSED";
std::cout << "\nrose EXTERNAL";
- std::cout << "\norange INTERNAL"<<std::endl;
+ std::cout << "\norange INTERNAL"<<'\n';
}
Standard_EXPORT Draw_Color DBRep_ColorOrientation (const TopAbs_Orientation Or)
TopAbs::Print (theType, std::cout);
std::cout << " but a ";
TopAbs::Print (aShape.ShapeType(), std::cout);
- std::cout << std::endl;
+ std::cout << '\n';
}
return TopoDS_Shape();
}
BRep_Tool::Range(E->Edge(), aCheckU1, aCheckU2);
if (aCheckU2 < aCheckU1) {
// bad orientation
- std::cout << "DBRep_DrawableShape : Bad parameters on edge."<<std::endl;
+ std::cout << "DBRep_DrawableShape : Bad parameters on edge."<<'\n';
BRepTools::Dump(E->Edge(),std::cout);
ite.Next();
continue;
if (!IsDone (UInd)) {
std::cout << "DBRep_IsoBuilder:: U iso of parameter: " << UPrm ;
switch (Status (UInd)) {
- case HatchGen_NoProblem : std::cout << " No Problem" << std::endl ; break ;
- case HatchGen_TrimFailure : std::cout << " Trim Failure" << std::endl ; break ;
- case HatchGen_TransitionFailure : std::cout << " Transition Failure" << std::endl ; break ;
- case HatchGen_IncoherentParity : std::cout << " Incoherent Parity" << std::endl ; break ;
- case HatchGen_IncompatibleStates : std::cout << " Incompatible States" << std::endl ; break ;
+ case HatchGen_NoProblem : std::cout << " No Problem" << '\n' ; break ;
+ case HatchGen_TrimFailure : std::cout << " Trim Failure" << '\n' ; break ;
+ case HatchGen_TransitionFailure : std::cout << " Transition Failure" << '\n' ; break ;
+ case HatchGen_IncoherentParity : std::cout << " Incoherent Parity" << '\n' ; break ;
+ case HatchGen_IncompatibleStates : std::cout << " Incompatible States" << '\n' ; break ;
}
} else {
Standard_Integer NbDom = Geom2dHatch_Hatcher::NbDomains (UInd) ;
if (!IsDone (VInd)) {
std::cout << "DBRep_IsoBuilder:: V iso of parameter: " << VPrm ;
switch (Status (VInd)) {
- case HatchGen_NoProblem : std::cout << " No Problem" << std::endl ; break ;
- case HatchGen_TrimFailure : std::cout << " Trim Failure" << std::endl ; break ;
- case HatchGen_TransitionFailure : std::cout << " Transition Failure" << std::endl ; break ;
- case HatchGen_IncoherentParity : std::cout << " Incoherent Parity" << std::endl ; break ;
- case HatchGen_IncompatibleStates : std::cout << " Incompatible States" << std::endl ; break ;
+ case HatchGen_NoProblem : std::cout << " No Problem" << '\n' ; break ;
+ case HatchGen_TrimFailure : std::cout << " Trim Failure" << '\n' ; break ;
+ case HatchGen_TransitionFailure : std::cout << " Transition Failure" << '\n' ; break ;
+ case HatchGen_IncoherentParity : std::cout << " Incoherent Parity" << '\n' ; break ;
+ case HatchGen_IncompatibleStates : std::cout << " Incompatible States" << '\n' ; break ;
}
} else {
Standard_Integer NbDom = Geom2dHatch_Hatcher::NbDomains (VInd) ;
{
Label.Nullify();
TDF_Tool::Label(DF,Entry,Label,Standard_False);
- if (Label.IsNull() && Complain) std::cout << "No label for entry " << Entry <<std::endl;
+ if (Label.IsNull() && Complain) std::cout << "No label for entry " << Entry <<'\n';
return !Label.IsNull();
}
DF = DDF->DataFramework();
return Standard_True;
}
- if (Complain) std::cout <<"framework "<<Name<<" not found "<< std::endl;
+ if (Complain) std::cout <<"framework "<<Name<<" not found "<< '\n';
return Standard_False;
}
TDF_Label L;
if (FindLabel(DF,Entry,L,Complain)) {
if (L.FindAttribute(ID,A)) return Standard_True;
- if (Complain) std::cout <<"attribute not found for entry : "<< Entry <<std::endl;
+ if (Complain) std::cout <<"attribute not found for entry : "<< Entry <<'\n';
}
return Standard_False;
}
void DDF_Browser::Dump(Standard_OStream& S) const
{
- S<<"DDF_Browser on a DF:"<<std::endl;
+ S<<"DDF_Browser on a DF:"<<'\n';
S<<myDF;
}
void DDF_Data::DrawOn(Draw_Display& /*dis*/) const
-{ std::cout<<"DDF_Data"<<std::endl; }
+{ std::cout<<"DDF_Data"<<'\n'; }
}
const Handle(TColStd_HPackedMapOfInteger)& aHMap = new TColStd_HPackedMapOfInteger(aMap);
anAtt->ChangeMap(aHMap);
- std::cout << "Map extent = " << anAtt->Extent()<<std::endl;
+ std::cout << "Map extent = " << anAtt->Extent()<<'\n';
return 0;
}
di << "DDataStd_SetIntPackedMap : Error\n";
}
const Handle(TColStd_HPackedMapOfInteger)& aHMap = new TColStd_HPackedMapOfInteger(aMap);
anAtt->ChangeMap(aHMap);
- std::cout << "Map extent = " << anAtt->Extent()<<std::endl;
+ std::cout << "Map extent = " << anAtt->Extent()<<'\n';
return 0;
}
di << "DDataStd_SetIntPHugeMap : Error\n";
return 1;
}
- std::cout << "String = " << anAtt->Get().ToCString() << " is kept in DF" << std::endl;
+ std::cout << "String = " << anAtt->Get().ToCString() << " is kept in DF" << '\n';
return 0;
}
di << "DDataStd_SetAsciiString : Error\n";
return 1;
}
- std::cout <<std::endl;
- std::cout <<"NamedData attribute at Label = " << arg[2] <<std::endl;
+ std::cout <<'\n';
+ std::cout <<"NamedData attribute at Label = " << arg[2] <<'\n';
anAtt->LoadDeferredData();
const TColStd_DataMapOfStringInteger& aMap = anAtt->GetIntegersContainer();
TColStd_DataMapIteratorOfDataMapOfStringInteger itr(aMap);
return 1;
}
- std::cout <<std::endl;
- std::cout <<"NamedData attribute at Label = " << arg[2] <<std::endl;
+ std::cout <<'\n';
+ std::cout <<"NamedData attribute at Label = " << arg[2] <<'\n';
anAtt->LoadDeferredData();
TCollection_ExtendedString aKey(arg[3], Standard_True);
if(!anAtt->HasInteger(aKey)) {
- std::cout << "There is no data specified by Key = "<< arg[3] << std::endl;
+ std::cout << "There is no data specified by Key = "<< arg[3] << '\n';
return 1;
} else {
- std::cout << "Key = " << arg[3] << " Value = " <<anAtt->GetInteger(aKey)<<std::endl;
+ std::cout << "Key = " << arg[3] << " Value = " <<anAtt->GetInteger(aKey)<<'\n';
if(nb == 5)
Draw::Set(arg[4], anAtt->GetInteger(aKey));
return 0;
TDF_Label aLabel;
if(!DDF::FindLabel(DF, arg[2], aLabel)) return 1;
- std::cout <<std::endl;
- std::cout <<"NamedData attribute at Label = " << arg[2] <<std::endl;
+ std::cout <<'\n';
+ std::cout <<"NamedData attribute at Label = " << arg[2] <<'\n';
Handle(TDataStd_NamedData) anAtt;
if(!aLabel.FindAttribute(TDataStd_NamedData::GetID(), anAtt))
{
return 1;
}
- std::cout <<std::endl;
- std::cout <<"NamedData attribute at Label = " << arg[2] <<std::endl;
+ std::cout <<'\n';
+ std::cout <<"NamedData attribute at Label = " << arg[2] <<'\n';
anAtt->LoadDeferredData();
TCollection_ExtendedString aKey(arg[3], Standard_True);
if(!anAtt->HasReal(aKey)) {
Message::SendFail() << "There is no data specified by Key = " << arg[3];
return 1;
} else {
- std::cout << "Key = " << arg[3] << " Value = " <<anAtt->GetReal(aKey)<<std::endl;
+ std::cout << "Key = " << arg[3] << " Value = " <<anAtt->GetReal(aKey)<<'\n';
if(nb == 5)
Draw::Set(arg[4], anAtt->GetReal(aKey));
return 0;
return 1;
}
- std::cout <<std::endl;
- std::cout <<"NamedData attribute at Label = " << arg[2] <<std::endl;
+ std::cout <<'\n';
+ std::cout <<"NamedData attribute at Label = " << arg[2] <<'\n';
anAtt->LoadDeferredData();
const TDataStd_DataMapOfStringString& aMap = anAtt->GetStringsContainer();
di << "NamedData attribute is not found or not set" << "\n";
return 1;}
- std::cout <<std::endl;
- std::cout <<"NamedData attribute at Label = " << arg[2] <<std::endl;
+ std::cout <<'\n';
+ std::cout <<"NamedData attribute at Label = " << arg[2] <<'\n';
anAtt->LoadDeferredData();
TCollection_ExtendedString aKey(arg[3], Standard_True);
if (!anAtt->HasString(aKey))
else
{
TCollection_AsciiString aValue (anAtt->GetString(aKey));
- std::cout << "Key = " << arg[3] << " Value = " << aValue.ToCString() << std::endl;
+ std::cout << "Key = " << arg[3] << " Value = " << aValue.ToCString() << '\n';
if(nb == 5)
Draw::Set(arg[4], aValue.ToCString());
return 0;
return 1;
}
- std::cout <<std::endl;
- std::cout <<"NamedData attribute at Label = " << arg[2] <<std::endl;
+ std::cout <<'\n';
+ std::cout <<"NamedData attribute at Label = " << arg[2] <<'\n';
anAtt->LoadDeferredData();
const TDataStd_DataMapOfStringByte& aMap = anAtt->GetBytesContainer();
TDataStd_DataMapIteratorOfDataMapOfStringByte itr(aMap);
{
const TCollection_ExtendedString& aKey(itr.Key());
Standard_Byte aValue = itr.Value();
- std::cout << "Key = " << aKey << " Value = " <<aValue<<std::endl;
+ std::cout << "Key = " << aKey << " Value = " <<aValue<<'\n';
}
return 0;
}
return 1;
}
- std::cout <<std::endl;
- std::cout <<"NamedData attribute at Label = " << arg[2] <<std::endl;
+ std::cout <<'\n';
+ std::cout <<"NamedData attribute at Label = " << arg[2] <<'\n';
anAtt->LoadDeferredData();
TCollection_ExtendedString aKey(arg[3], Standard_True);
if (!anAtt->HasByte(aKey))
}
else
{
- std::cout << "Key = " << arg[3] << " Value = " <<anAtt->GetByte(aKey)<< std::endl;
+ std::cout << "Key = " << arg[3] << " Value = " <<anAtt->GetByte(aKey)<< '\n';
if(nb == 5)
Draw::Set(arg[4], anAtt->GetByte(aKey));
return 0;
return 1;
}
- std::cout <<std::endl;
- std::cout <<"NamedData attribute at Label = " << arg[2] <<std::endl;
+ std::cout <<'\n';
+ std::cout <<"NamedData attribute at Label = " << arg[2] <<'\n';
anAtt->LoadDeferredData();
const TDataStd_DataMapOfStringHArray1OfInteger& aMap = anAtt->GetArraysOfIntegersContainer();
TDataStd_DataMapIteratorOfDataMapOfStringHArray1OfInteger itr(aMap);
for (; itr.More(); itr.Next()){
const TCollection_ExtendedString& aKey(itr.Key());
- std::cout << "Key = " << aKey<< std::endl;
+ std::cout << "Key = " << aKey<< '\n';
const Handle(TColStd_HArray1OfInteger)& anArrValue = itr.Value();
if(!anArrValue.IsNull()) {
Standard_Integer lower = anArrValue->Lower();
Standard_Integer upper = anArrValue->Upper();
for(Standard_Integer i = lower; i<=upper;i++) {
Standard_Integer aValue = anArrValue->Value(i);
- std::cout << "\tValue("<<i<<") = " <<aValue<<std::endl;
+ std::cout << "\tValue("<<i<<") = " <<aValue<<'\n';
}
} else
- std::cout << "\tthe specified array is Null "<<std::endl;
+ std::cout << "\tthe specified array is Null "<<'\n';
}
return 0;
}
return 1;
}
- std::cout <<std::endl;
- std::cout <<"NamedData attribute at Label = " << arg[2] <<std::endl;
+ std::cout <<'\n';
+ std::cout <<"NamedData attribute at Label = " << arg[2] <<'\n';
anAtt->LoadDeferredData();
TCollection_ExtendedString aKey(arg[3], Standard_True);
if (!anAtt->HasArrayOfIntegers(aKey))
}
else
{
- std::cout << "Key = " << arg[3] <<std::endl;
+ std::cout << "Key = " << arg[3] <<'\n';
Handle(TColStd_HArray1OfInteger) anArrValue = anAtt->GetArrayOfIntegers(aKey);
if(!anArrValue.IsNull()) {
Standard_Integer upper = anArrValue->Upper();
for(Standard_Integer i = lower; i<=upper;i++) {
Standard_Integer aValue = anArrValue->Value(i);
- std::cout << "\tValue("<<i<<") = " <<aValue<<std::endl;
+ std::cout << "\tValue("<<i<<") = " <<aValue<<'\n';
}
} else
- std::cout << "\tthe specified array is Null or not found"<<std::endl;
+ std::cout << "\tthe specified array is Null or not found"<<'\n';
return 0;
}
}
return 1;
}
- std::cout <<std::endl;
- std::cout <<"NamedData attribute at Label = " << arg[2] <<std::endl;
+ std::cout <<'\n';
+ std::cout <<"NamedData attribute at Label = " << arg[2] <<'\n';
anAtt->LoadDeferredData();
const TDataStd_DataMapOfStringHArray1OfReal& aMap = anAtt->GetArraysOfRealsContainer();
TDataStd_DataMapIteratorOfDataMapOfStringHArray1OfReal itr(aMap);
for (; itr.More(); itr.Next()){
const TCollection_ExtendedString& aKey(itr.Key());
- std::cout << "Key = " << aKey << std::endl;
+ std::cout << "Key = " << aKey << '\n';
const Handle(TColStd_HArray1OfReal)& anArrValue = itr.Value();
if(!anArrValue.IsNull()) {
Standard_Integer lower = anArrValue->Lower();
Standard_Integer upper = anArrValue->Upper();
for(Standard_Integer i = lower; i<=upper;i++) {
Standard_Real aValue = anArrValue->Value(i);
- std::cout << "\tValue("<<i<<") = " <<aValue<<std::endl;
+ std::cout << "\tValue("<<i<<") = " <<aValue<<'\n';
}
} else
- std::cout << "\tthe specified array is Null "<<std::endl;
+ std::cout << "\tthe specified array is Null "<<'\n';
}
return 0;
}
di << "NamedData attribute is not found or not set" << "\n";
return 1;}
- std::cout <<std::endl;
- std::cout <<"NamedData attribute at Label = " << arg[2] <<std::endl;
+ std::cout <<'\n';
+ std::cout <<"NamedData attribute at Label = " << arg[2] <<'\n';
anAtt->LoadDeferredData();
TCollection_ExtendedString aKey(arg[3], Standard_True);
if(!anAtt->HasArrayOfReals(aKey)) {
- std::cout << "There is no data specified by Key = "<< arg[3] << std::endl;
+ std::cout << "There is no data specified by Key = "<< arg[3] << '\n';
return 1;
} else {
- std::cout << "Key = " << arg[3] <<std::endl;
+ std::cout << "Key = " << arg[3] <<'\n';
Handle(TColStd_HArray1OfReal) anArrValue = anAtt->GetArrayOfReals(aKey);
if(!anArrValue.IsNull()) {
Standard_Integer upper = anArrValue->Upper();
for(Standard_Integer i = lower; i<=upper;i++) {
Standard_Real aValue = anArrValue->Value(i);
- std::cout << "\tValue("<<i<<") = " <<aValue<<std::endl;
+ std::cout << "\tValue("<<i<<") = " <<aValue<<'\n';
}
} else
- std::cout << "\tthe specified array is Null or not found"<<std::endl;
+ std::cout << "\tthe specified array is Null or not found"<<'\n';
return 0;
}
}
DDataStd_DrawDriver::Set(DD);
}
Handle(Draw_Drawable3D) D3D = DD->Drawable(Label());
- if (D3D.IsNull()) std::cout<< "DDataStd_DrawPresentation::DrawBuild : null drawable" << std::endl;
+ if (D3D.IsNull()) std::cout<< "DDataStd_DrawPresentation::DrawBuild : null drawable" << '\n';
myDrawable = D3D;
}
return;
}
}
- std::cout<< "DDataStd_DrawPresentation::DrawDisplay : null Label" << std::endl;
+ std::cout<< "DDataStd_DrawPresentation::DrawDisplay : null Label" << '\n';
}
//=======================================================================
return;
}
}
- std::cout<< "DDataStd_DrawPresentation::DrawErase : null Label" << std::endl;
+ std::cout<< "DDataStd_DrawPresentation::DrawErase : null Label" << '\n';
}
//=======================================================================
void DDataStd_TreeBrowser::DrawOn(Draw_Display& /*dis*/) const
-{ std::cout<<"DDataStd_TreeBrowser"<<std::endl; }
+{ std::cout<<"DDataStd_TreeBrowser"<<'\n'; }
//=======================================================================
void DDataStd_TreeBrowser::Dump(Standard_OStream& S) const
{
- S<<"DDataStd_TreeBrowser on a label: "<<std::endl;
+ S<<"DDataStd_TreeBrowser on a label: "<<'\n';
S<<myRoot;
}
{
Handle(DDocStd_DrawDocument) DD = Handle(DDocStd_DrawDocument)::DownCast (Draw::GetExisting (Name));
if (DD.IsNull()) {
- if (Complain) std::cout << Name << " is not a Document" << std::endl;
+ if (Complain) std::cout << Name << " is not a Document" << '\n';
return Standard_False;
}
Handle(TDocStd_Document) STDDOC = DD->GetDocument();
DOC = STDDOC;
return Standard_True;
}
- if (Complain) std::cout << Name << " is not a CAF Document" << std::endl;
+ if (Complain) std::cout << Name << " is not a CAF Document" << '\n';
return Standard_False;
}
{
Label.Nullify();
TDF_Tool::Label(D->GetData(),Entry,Label,Standard_False);
- if (Label.IsNull() && Complain) std::cout<<"No label for entry "<<Entry<<std::endl;
+ if (Label.IsNull() && Complain) std::cout<<"No label for entry "<<Entry<<'\n';
return !Label.IsNull();
}
TDF_Label L;
if (Find(D,Entry,L,Complain)) {
if (L.FindAttribute(ID,A)) return Standard_True;
- if (Complain) std::cout <<"attribute not found for entry : "<< Entry <<std::endl;
+ if (Complain) std::cout <<"attribute not found for entry : "<< Entry <<'\n';
}
return Standard_False;
}
DDF_Data::Dump(S);
}
else {
- S << myDocument->DynamicType()->Name() << " is not a CAF document" << std::endl;
+ S << myDocument->DynamicType()->Name() << " is not a CAF document" << '\n';
}
}
else if(name == "Section")
aDrv = new DNaming_BooleanOperationDriver();
else
- std::cout << "the specified driver is not supported" <<std::endl;
+ std::cout << "the specified driver is not supported" <<'\n';
return aDrv;
}
//=======================================================================
Handle(TFunction_Function) aFun;
funLabel.FindAttribute(TFunction_Function::GetID(), aFun);
if(aFun.IsNull()) {
- std::cout << "DNaming_SolveFlatFrom:: Null function is found!" << std::endl;
+ std::cout << "DNaming_SolveFlatFrom:: Null function is found!" << '\n';
continue;
}
else {
std::cout <<"DNaming_SolveFlatFrom : function from label " << entry << " is recomputed" << std::endl;
#endif
} catch (EXCEPTION) {
- std::cout <<"DNaming_SolveFlatFrom : Exception computing function at label " << entry << std::endl;
+ std::cout <<"DNaming_SolveFlatFrom : Exception computing function at label " << entry << '\n';
}
}
}
if (!DDocStd::GetDocument(aDocS, aDoc)) return 1;
Handle(TFunction_Logbook) logbook = TFunction_Logbook::Set(aDoc->Main());
if(logbook->IsEmpty())
- std::cout << "DNaming_CheckLogBook : is empty" <<std::endl;
+ std::cout << "DNaming_CheckLogBook : is empty" <<'\n';
else {
const TDF_LabelMap& aMap = logbook->GetValid();
TDF_MapIteratorOfLabelMap it(aMap);
TCollection_AsciiString entry;
- std::cout << "DNaming_CheckLogBook : LogBook current state:" <<std::endl;
+ std::cout << "DNaming_CheckLogBook : LogBook current state:" <<'\n';
for (;it.More();it.Next()) {
TDF_Tool::Entry(it.Key(), entry);
- std::cout << entry <<std::endl;
+ std::cout << entry <<'\n';
}
}
return 0;
return 1;
}
catch (Standard_Failure const&) {
- std::cout << "EXCEPTION: SELECTION_IMPOSSIBLE" <<std::endl;
+ std::cout << "EXCEPTION: SELECTION_IMPOSSIBLE" <<'\n';
}
if(!aCont.IsNull()) {
Handle(TNaming_NamedShape) aCont = DNaming::GetObjectValue(aContext);
if(aCont.IsNull() || aCont->IsEmpty())
- std::cout <<"Wrong Context ..." <<std::endl;
+ std::cout <<"Wrong Context ..." <<'\n';
else {
TopoDS_Shape aCONTEXT = aCont->Get();
try{
return 1;
}
catch (Standard_Failure const&) {
- std::cout << "EXCEPTION: SELECTION_IMPOSSIBLE" <<std::endl;
+ std::cout << "EXCEPTION: SELECTION_IMPOSSIBLE" <<'\n';
}
TDF_Reference::Set(aFun->Label().FindChild(FUNCTION_ARGUMENTS_LABEL).FindChild(ATTACH_ARG),
if(isDX || isDY || isDZ)
DDF::ReturnLabel(theDI, objLabel);
else
- std::cout <<"DNaming_PntOffset : Nothing changed" << std::endl;
+ std::cout <<"DNaming_PntOffset : Nothing changed" << '\n';
return 0;
}
}
if(!aSelector.Select(Selection, aContext, Geometry, KeepOrientation))
return Standard_False;
}catch (...) {
- std::cout << "EXCEPTION: SELECTION_IMPOSSIBLE" <<std::endl;
+ std::cout << "EXCEPTION: SELECTION_IMPOSSIBLE" <<'\n';
}
if(!aNS.IsNull()) {
if(!aSelector.Select(Selection, aContext, Geometry, KeepOrientation))
return Standard_False;
}catch (...) {
- std::cout << "EXCEPTION: SELECTION_IMPOSSIBLE" <<std::endl;
+ std::cout << "EXCEPTION: SELECTION_IMPOSSIBLE" <<'\n';
}
if(!aNS.IsNull()) {
}
catch (Standard_Failure const& anException) {
std::cout << "%%%INFO:Error: ::TestSingleSelection failed :";
- std::cout << anException.GetMessageString() << std::endl;
+ std::cout << anException.GetMessageString() << '\n';
}
catch(...) {
std::cout << "%%%INFO:Error: ::TestSingleSelection selection failed : unknown exception type";
}
if(aResult.Length()) {
if(aResult.Search("Warning") == -1)
- std::cout << "Failed units: " << aResult << " at " << entry << std::endl;
+ std::cout << "Failed units: " << aResult << " at " << entry << '\n';
else
- std::cout << aResult << " at " << entry << std::endl;
+ std::cout << aResult << " at " << entry << '\n';
TDataStd_Name::Set(auxObj->Label(), aResult);
}
}
B.Generated(it1.Value());
TCollection_AsciiString entry;
TDF_Tool::Entry(aLabel, entry);
- std::cout << "\t" <<entry <<std::endl;
+ std::cout << "\t" <<entry <<'\n';
}
}
if(!FirstAuxObj.IsNull())
}
catch (Standard_Failure const& anException) {
std::cout << "%%%INFO:Error: ::TestSingleSelection failed :";
- std::cout << anException.GetMessageString() << std::endl;
+ std::cout << anException.GetMessageString() << '\n';
}
catch(...) {
std::cout << "%%%INFO:Error: ::TestSingleSelection selection failed : unknown exception type";
aFailedList.Append(aCurShape);
}
if(aResult.Length())
- std::cout << "Failed units: " << aResult << std::endl;
+ std::cout << "Failed units: " << aResult << '\n';
}
if(aFailedList.Extent()) {
Handle(TNaming_Naming) naming;
if (!L.FindAttribute(TNaming_Naming::GetID(),naming)) {
- std::cout <<"DNaming__SolveSelection : not a selection" << std::endl;
+ std::cout <<"DNaming__SolveSelection : not a selection" << '\n';
return 1;
}
TDF_LabelMap aValidMap;
theLog->SetValid(aRLabel);
Handle(TNaming_NamedShape) aNS;
if(!aRLabel.FindAttribute(TNaming_NamedShape::GetID(),aNS)) {
- std::cout <<"%%%WARNING: DNaming_SelectionDriver::NamedShape is not found"<<std::endl;
+ std::cout <<"%%%WARNING: DNaming_SelectionDriver::NamedShape is not found"<<'\n';
}
else {
if(aNS.IsNull()) {
- std::cout << "%%%WARNING: DNaming_SelectionDriver::NamedShape is NULL" <<std::endl;
+ std::cout << "%%%WARNING: DNaming_SelectionDriver::NamedShape is NULL" <<'\n';
} else
if(aNS->IsEmpty()) {
std::cout << "%%%WARNING: DNaming_SelectionDriver::NamedShape is EMPTY on Label = ";
- aNS->Label().EntryDump(std::cout); std::cout << std::endl;
+ aNS->Label().EntryDump(std::cout); std::cout << '\n';
} else {
#ifdef OCCT_DEBUG
}
else {
aFunction->SetFailure(NOTDONE);
- std::cout << "%%%WARNING: DNaming_SelectionDriver::Execute: Selection is Not solved !!!" << std::endl;
+ std::cout << "%%%WARNING: DNaming_SelectionDriver::Execute: Selection is Not solved !!!" << '\n';
return 1;
}
return 0;
#endif
else
{
- std::cout << "DRAW is running in batch mode" << std::endl;
+ std::cout << "DRAW is running in batch mode" << '\n';
theCommands.Init();
Tcl_Init(theCommands.Interp());
}
{
if (!dout.DefineColor (i, ColorNames[i]))
{
- std::cout <<"Could not allocate default color " << ColorNames[i] << std::endl;
+ std::cout <<"Could not allocate default color " << ColorNames[i] << '\n';
}
}
}
#ifdef _WIN32
ReadInitFile ("ddefault");
#else
- std::cout << " the CASROOT variable is mandatory to Run OpenCascade "<< std::endl;
- std::cout << "No default file" << std::endl;
+ std::cout << " the CASROOT variable is mandatory to Run OpenCascade "<< '\n';
+ std::cout << "No default file" << '\n';
#endif
}
}
{
Message_PrinterOStream::SetConsoleTextColor (&std::cout, Message_ConsoleColor_Red, true);
}
- std::cout << theCommands.Result() << std::endl;
+ std::cout << theCommands.Result() << '\n';
if (c > 0 && theCommands.ToColorize())
{
Message_PrinterOStream::SetConsoleTextColor (&std::cout, Message_ConsoleColor_Default, false);
Standard_Integer Draw_Call (char *c)
{
Standard_Integer r = theCommands.Eval(c);
- std::cout << theCommands.Result() << std::endl;
+ std::cout << theCommands.Result() << '\n';
return r;
}
if (!aPluginResource->Find (theKey, aPluginLibrary))
{
Message::SendFail() << "could not find the resource:" << theKey;
- Standard_SStream aMsg; aMsg << "Could not find the resource:" << theKey << std::endl;
+ Standard_SStream aMsg; aMsg << "Could not find the resource:" << theKey << '\n';
throw Draw_Failure (aMsg.str().c_str());
}
#else
static void cpulimitSignalHandler (int)
{
- std::cout << "Process killed by CPU limit (" << CPU_LIMIT << " sec)" << std::endl;
+ std::cout << "Process killed by CPU limit (" << CPU_LIMIT << " sec)" << '\n';
exit(2);
}
static void *CpuFunc(void* /*threadarg*/)
sleep (5);
anElapCurrent = clock_t(aTimer.ElapsedTime());
if (CPU_LIMIT >0 && (anElapCurrent) >= CPU_LIMIT) {
- std::cout << "Process killed by elapsed limit (" << CPU_LIMIT << " sec)" << std::endl;
+ std::cout << "Process killed by elapsed limit (" << CPU_LIMIT << " sec)" << '\n';
exit(2);
}
}
if (result)
di << result;
else
- std::cout << "Error: unsupported locale specification: " << locale << std::endl;
+ std::cout << "Error: unsupported locale specification: " << locale << '\n';
return 0;
}
*aStream << theArgVec[anArgIter];
if (!isNoNewline)
{
- *aStream << std::endl;
+ *aStream << '\n';
}
if (toIntense || aColor != Message_ConsoleColor_Default)
OCC_CATCH_SIGNALS
Draw_Interpretor& aCommands = Draw::GetInterpretor();
aCommands.Eval (theCommandStr);
- std::cout << aCommands.Result() << std::endl;
+ std::cout << aCommands.Result() << '\n';
return aCommands.Result();
}
catch (Standard_Failure const& anException)
{
Standard_Integer id = Draw::Atoi(a);
if ((id < 0) || (id >= MAXVIEW)) {
- std::cout << "Incorrect view-id, must be in 0.."<<MAXVIEW-1<<std::endl;
+ std::cout << "Incorrect view-id, must be in 0.."<<MAXVIEW-1<<'\n';
return -1;
}
if (!dout.HasView(id)) {
- std::cout <<"View "<<id<<" does not exist."<<std::endl;
+ std::cout <<"View "<<id<<" does not exist."<<'\n';
return -1;
}
return id;
{
for (int i=0; i < argc; i++)
os << argv[i] << " ";
- os << std::endl;
+ os << '\n';
}
void flush_standard_streams ()
const char* aResultStr = Tcl_GetStringResult (interp);
if (aResultStr != 0 && aResultStr[0] != '\0' )
{
- std::cout << aResultStr << std::endl;
+ std::cout << aResultStr << '\n';
}
}
Standard_SStream aSStream;
aMessenger->DumpJson (aSStream);
theDI << aSStream;
- std::cout << aSStream.str() << std::endl;
+ std::cout << aSStream.str() << '\n';
return 0;
}
Handle(Draw_Drawable3D) D = Draw::Get(a[i]);
if (D.IsNull()) {
if ((a[i][0] == '.') && (a[i][1] == '\0'))
- std::cout << "Missed !!!" << std::endl;
+ std::cout << "Missed !!!" << '\n';
return 0;
}
}
Handle(Draw_Drawable3D) anOldD(reinterpret_cast<Draw_Drawable3D*>(aCD));
if (!anOldD.IsNull()) {
if (Draw::Drawables().Contains(anOldD) && anOldD->Protected()) {
- std::cout << "variable is protected" << std::endl;
+ std::cout << "variable is protected" << '\n';
return;
}
anOldD.Nullify();
return Handle(Draw_Drawable3D)();
}
- std::cout << "Pick an object" << std::endl;
+ std::cout << "Pick an object" << '\n';
Handle(Draw_Drawable3D) aDrawable;
dout.Select (p_id, p_X, p_Y, p_b);
dout.Pick (p_id, p_X, p_Y, 5, aDrawable, 0);
x = Parse (theName);
if (*theName != ')')
{
- std::cout << "Mismatched parenthesis" << std::endl;
+ std::cout << "Mismatched parenthesis" << '\n';
}
++theName;
break;
}
if (pc > 0)
{
- std::cout << "Unclosed parenthesis"<< std::endl;
+ std::cout << "Unclosed parenthesis"<< '\n';
x = 0;
}
else
}
if (aCommands.Eval (theName) != 0)
{
- std::cout << "Call of function " << theName << " failed" << std::endl;
+ std::cout << "Call of function " << theName << " failed" << '\n';
x = 0;
}
else
}
catch (Standard_Failure const& theFail)
{
- std::cout << "Cannot open display (" << theFail << "). Interpret commands in batch mode." << std::endl;
+ std::cout << "Cannot open display (" << theFail << "). Interpret commands in batch mode." << '\n';
return Standard_False;
}
}
std::streamsize prec = S.precision(15);
#endif
if (is3D)
- S << "Point : " << myPoint.X() << ", " << myPoint.Y() << ", " << myPoint.Z() <<std::endl;
+ S << "Point : " << myPoint.X() << ", " << myPoint.Y() << ", " << myPoint.Z() <<'\n';
else
- S << "Point 2d : " << myPoint.X() << ", " << myPoint.Y() <<std::endl;
+ S << "Point 2d : " << myPoint.X() << ", " << myPoint.Y() <<'\n';
#if !defined(_MSC_VER) && !defined(__sgi) && !defined(IRIX)
S.setf(F);
#else
void yyFlexLexer::LexerError( const char* msg )
{
- std::cerr << msg << std::endl;
+ std::cerr << msg << '\n';
exit( YY_EXIT_FAILURE );
}
void FEmTool_ProfileMatrix::OutM() const
{
Standard_Integer i, j;
- std::cout<<"Matrix A"<<std::endl;
+ std::cout<<"Matrix A"<<'\n';
for(i = 1; i <= RowNumber(); i++) {
for(j = 1; j < i - profile(1, i); j++)
std::cout<<"0 ";
for(j = profile(2, i) - profile(1, i); j <= profile(2, i); j++)
std::cout<<ProfileMatrix->Value(j)<<" ";
- std::cout<<std::endl;
+ std::cout<<'\n';
}
- std::cout<<"NextCoeff"<<std::endl;
+ std::cout<<"NextCoeff"<<'\n';
for(i = 1; i <= profile(2, RowNumber()); i++)
std::cout<<NextCoeff->Value(i)<<" ";
- std::cout<<std::endl;
+ std::cout<<'\n';
}
void FEmTool_ProfileMatrix::OutS() const
{
Standard_Integer i, j;
- std::cout<<"Matrix S"<<std::endl;
+ std::cout<<"Matrix S"<<'\n';
for(i = 1; i <= RowNumber(); i++) {
for(j = 1; j < i - profile(1, i); j++)
std::cout<<"0 ";
for(j = profile(2, i) - profile(1, i); j <= profile(2, i); j++)
std::cout<<SMatrix->Value(j)<<" ";
- std::cout<<std::endl;
+ std::cout<<'\n';
}
}
// ==================================================================
{
-o << " Batten |"; o.width(7); o<< "Old | New" << std::endl;
-o << " P1 X |"; o.width(7); o<< OldP1.X() << " | " << NewP1.X() << std::endl;
-o << " Y |"; o.width(7); o<< OldP1.Y() << " | " << NewP1.Y() << std::endl;
-o << " P2 X |"; o.width(7); o<< OldP2.X() << " | " << NewP2.X() << std::endl;
-o << " Y |"; o.width(7); o<< OldP2.Y() << " | " << NewP2.Y() << std::endl;
-o << " Angle1 |"; o.width(7); o<< OldAngle1 << " | " << NewAngle1 << std::endl;
-o << " Angle2 |"; o.width(7); o<< OldAngle2 << " | " << NewAngle2 << std::endl;
-o << " Height |"; o.width(7); o<< OldHeight << " | " << NewHeight << std::endl;
-o << " Slope |"; o.width(7); o<< OldSlope << " | " << NewSlope << std::endl;
-o << " SlidingFactor |"; o.width(7); o<< OldSlidingFactor << " | " << NewSlidingFactor << std::endl;
-o << " FreeSliding |"; o.width(7); o<< OldFreeSliding << " | " << NewFreeSliding << std::endl;
-o << " ConstrOrder1 |"; o.width(7); o<< OldConstraintOrder1 << " | " << NewConstraintOrder1 << std::endl;
-o << " ConstrOrder2 |" ; o.width(7); o<< OldConstraintOrder2 << " | " << NewConstraintOrder2 << std::endl;
+o << " Batten |"; o.width(7); o<< "Old | New" << '\n';
+o << " P1 X |"; o.width(7); o<< OldP1.X() << " | " << NewP1.X() << '\n';
+o << " Y |"; o.width(7); o<< OldP1.Y() << " | " << NewP1.Y() << '\n';
+o << " P2 X |"; o.width(7); o<< OldP2.X() << " | " << NewP2.X() << '\n';
+o << " Y |"; o.width(7); o<< OldP2.Y() << " | " << NewP2.Y() << '\n';
+o << " Angle1 |"; o.width(7); o<< OldAngle1 << " | " << NewAngle1 << '\n';
+o << " Angle2 |"; o.width(7); o<< OldAngle2 << " | " << NewAngle2 << '\n';
+o << " Height |"; o.width(7); o<< OldHeight << " | " << NewHeight << '\n';
+o << " Slope |"; o.width(7); o<< OldSlope << " | " << NewSlope << '\n';
+o << " SlidingFactor |"; o.width(7); o<< OldSlidingFactor << " | " << NewSlidingFactor << '\n';
+o << " FreeSliding |"; o.width(7); o<< OldFreeSliding << " | " << NewFreeSliding << '\n';
+o << " ConstrOrder1 |"; o.width(7); o<< OldConstraintOrder1 << " | " << NewConstraintOrder1 << '\n';
+o << " ConstrOrder2 |" ; o.width(7); o<< OldConstraintOrder2 << " | " << NewConstraintOrder2 << '\n';
switch (myCode) {
case FairCurve_OK :
- o << "AnalysisCode : Ok" << std::endl;
+ o << "AnalysisCode : Ok" << '\n';
break;
case FairCurve_NotConverged :
- o << "AnalysisCode : NotConverged" << std::endl;
+ o << "AnalysisCode : NotConverged" << '\n';
break;
case FairCurve_InfiniteSliding :
- o << "AnalysisCode : InfiniteSliding" << std::endl;
+ o << "AnalysisCode : InfiniteSliding" << '\n';
break;
case FairCurve_NullHeight :
- o << "AnalysisCode : NullHeight" << std::endl;
+ o << "AnalysisCode : NullHeight" << '\n';
break;
}
}
//======================================================================================
{
-o << " MVCurve |"; o.width(7); o<< "Old | New" << std::endl;
-o << " P1 X |"; o.width(7); o<< OldP1.X() << " | " << NewP1.X() << std::endl;
-o << " Y |"; o.width(7); o<< OldP1.Y() << " | " << NewP1.Y() << std::endl;
-o << " P2 X |"; o.width(7); o<< OldP2.X() << " | " << NewP2.X() << std::endl;
-o << " Y |"; o.width(7); o<< OldP2.Y() << " | " << NewP2.Y() << std::endl;
-o << " Angle1 |"; o.width(7); o<< OldAngle1 << " | " << NewAngle1 << std::endl;
-o << " Angle2 |"; o.width(7); o<< OldAngle2 << " | " << NewAngle2 << std::endl;
-o << " Curvature1 |"; o.width(7); o<< OldCurvature1 << " | " << NewCurvature1 << std::endl;
-o << " Curvature2 |"; o.width(7); o<< OldCurvature2 << " | " << NewCurvature2 << std::endl;
-o << " Height |"; o.width(7); o<< OldHeight << " | " << NewHeight << std::endl;
-o << " Slope |"; o.width(7); o<< OldSlope << " | " << NewSlope << std::endl;
-o << " PhysicalRatio |"; o.width(7); o<< OldPhysicalRatio << " | " << NewPhysicalRatio << std::endl;
-o << " SlidingFactor |"; o.width(7); o<< OldSlidingFactor << " | " << NewSlidingFactor << std::endl;
-o << " FreeSliding |"; o.width(7); o<< OldFreeSliding << " | " << NewFreeSliding << std::endl;
-o << " ConstrOrder1 |"; o.width(7); o<< OldConstraintOrder1 << " | " << NewConstraintOrder1 << std::endl;
-o << " ConstrOrder2 |"; o.width(7); o<< OldConstraintOrder2 << " | " << NewConstraintOrder2 << std::endl;
+o << " MVCurve |"; o.width(7); o<< "Old | New" << '\n';
+o << " P1 X |"; o.width(7); o<< OldP1.X() << " | " << NewP1.X() << '\n';
+o << " Y |"; o.width(7); o<< OldP1.Y() << " | " << NewP1.Y() << '\n';
+o << " P2 X |"; o.width(7); o<< OldP2.X() << " | " << NewP2.X() << '\n';
+o << " Y |"; o.width(7); o<< OldP2.Y() << " | " << NewP2.Y() << '\n';
+o << " Angle1 |"; o.width(7); o<< OldAngle1 << " | " << NewAngle1 << '\n';
+o << " Angle2 |"; o.width(7); o<< OldAngle2 << " | " << NewAngle2 << '\n';
+o << " Curvature1 |"; o.width(7); o<< OldCurvature1 << " | " << NewCurvature1 << '\n';
+o << " Curvature2 |"; o.width(7); o<< OldCurvature2 << " | " << NewCurvature2 << '\n';
+o << " Height |"; o.width(7); o<< OldHeight << " | " << NewHeight << '\n';
+o << " Slope |"; o.width(7); o<< OldSlope << " | " << NewSlope << '\n';
+o << " PhysicalRatio |"; o.width(7); o<< OldPhysicalRatio << " | " << NewPhysicalRatio << '\n';
+o << " SlidingFactor |"; o.width(7); o<< OldSlidingFactor << " | " << NewSlidingFactor << '\n';
+o << " FreeSliding |"; o.width(7); o<< OldFreeSliding << " | " << NewFreeSliding << '\n';
+o << " ConstrOrder1 |"; o.width(7); o<< OldConstraintOrder1 << " | " << NewConstraintOrder1 << '\n';
+o << " ConstrOrder2 |"; o.width(7); o<< OldConstraintOrder2 << " | " << NewConstraintOrder2 << '\n';
switch (myCode) {
case FairCurve_OK :
- o << "AnalysisCode : Ok" << std::endl;
+ o << "AnalysisCode : Ok" << '\n';
break;
case FairCurve_NotConverged :
- o << "AnalysisCode : NotConverged" << std::endl;
+ o << "AnalysisCode : NotConverged" << '\n';
break;
case FairCurve_InfiniteSliding :
- o << "AnalysisCode : InfiniteSliding" << std::endl;
+ o << "AnalysisCode : InfiniteSliding" << '\n';
break;
case FairCurve_NullHeight :
- o << "AnalysisCode : NullHeight" << std::endl;
+ o << "AnalysisCode : NullHeight" << '\n';
break;
}
}
void Geom2dConvert_ApproxCurve::Dump(Standard_OStream& o) const
{
- o << "******* Dump of ApproxCurve *******" << std::endl;
- o << "******* Error " << MaxError() << std::endl;
+ o << "******* Dump of ApproxCurve *******" << '\n';
+ o << "******* Error " << MaxError() << '\n';
}
void Geom2dHatch_Hatcher::Dump () const
{
- std::cout << std::endl ;
- std::cout << "========================================================" << std::endl ;
- std::cout << "=== Dump of the hatcher ================================" << std::endl ;
- std::cout << "========================================================" << std::endl ;
- std::cout << std::endl ;
+ std::cout << '\n' ;
+ std::cout << "========================================================" << '\n' ;
+ std::cout << "=== Dump of the hatcher ================================" << '\n' ;
+ std::cout << "========================================================" << '\n' ;
+ std::cout << '\n' ;
std::cout << "The points are "
<< (myKeepPoints ? " " : "not ")
<< "considered."
- << std::endl ;
+ << '\n' ;
std::cout << "The segments are "
<< (myKeepSegments ? " " : "not ")
<< "considered."
- << std::endl ;
- std::cout << "2D Confusion tolerance : " << myConfusion2d << std::endl ;
- std::cout << "3D Confusion tolerance : " << myConfusion3d << std::endl ;
+ << '\n' ;
+ std::cout << "2D Confusion tolerance : " << myConfusion2d << '\n' ;
+ std::cout << "3D Confusion tolerance : " << myConfusion3d << '\n' ;
std::cout << myNbHatchings
<< " hatching"
<< ((myNbHatchings == 1) ? "" : "s")
- << std::endl ;
+ << '\n' ;
std::cout << myNbElements
<< " element"
<< ((myNbElements == 1) ? "" : "s")
- << std::endl ;
+ << '\n' ;
- std::cout << std::endl ;
- std::cout << "========================================================" << std::endl ;
- std::cout << "=== Hatchings ==========================================" << std::endl ;
- std::cout << "========================================================" << std::endl ;
- std::cout << std::endl ;
+ std::cout << '\n' ;
+ std::cout << "========================================================" << '\n' ;
+ std::cout << "=== Hatchings ==========================================" << '\n' ;
+ std::cout << "========================================================" << '\n' ;
+ std::cout << '\n' ;
for (Standard_Integer IndH = 1 ; IndH <= myNbHatchings ; IndH++) {
std::cout << "Hatching # " << IndH ;
if (!myHatchings.IsBound (IndH)) {
- std::cout << " is not bound" << std::endl ;
+ std::cout << " is not bound" << '\n' ;
} else {
const Geom2dHatch_Hatching& Hatching = myHatchings.Find (IndH) ;
Standard_Integer NbPnt = Hatching.NbPoints() ;
- std::cout << " contains " << NbPnt << " restriction points :" << std::endl ;
+ std::cout << " contains " << NbPnt << " restriction points :" << '\n' ;
for (Standard_Integer IPnt = 1 ; IPnt <= NbPnt ; IPnt++) {
const HatchGen_PointOnHatching& PntH = Hatching.Point (IPnt) ;
PntH.Dump (IPnt) ;
}
- std::cout << "----------------------------------------------" << std::endl ;
+ std::cout << "----------------------------------------------" << '\n' ;
}
}
- std::cout << std::endl ;
- std::cout << "========================================================" << std::endl ;
- std::cout << "=== Elements ===========================================" << std::endl ;
- std::cout << "========================================================" << std::endl ;
- std::cout << std::endl ;
+ std::cout << '\n' ;
+ std::cout << "========================================================" << '\n' ;
+ std::cout << "=== Elements ===========================================" << '\n' ;
+ std::cout << "========================================================" << '\n' ;
+ std::cout << '\n' ;
for (Standard_Integer IndE = 1 ; IndE <= myNbElements ; IndE++) {
std::cout << "Element # " << IndE ;
if (!myElements.IsBound (IndE)) {
- std::cout << " is not bound" << std::endl ;
+ std::cout << " is not bound" << '\n' ;
} else {
const Geom2dHatch_Element& Element = myElements.Find (IndE) ;
switch (Element.Orientation()) {
- case TopAbs_FORWARD : std::cout << " is FORWARD" << std::endl ; break ;
- case TopAbs_REVERSED : std::cout << " is REVERSED" << std::endl ; break ;
- case TopAbs_INTERNAL : std::cout << " is INTERNAL" << std::endl ; break ;
- case TopAbs_EXTERNAL : std::cout << " is EXTERNAL" << std::endl ; break ;
+ case TopAbs_FORWARD : std::cout << " is FORWARD" << '\n' ; break ;
+ case TopAbs_REVERSED : std::cout << " is REVERSED" << '\n' ; break ;
+ case TopAbs_INTERNAL : std::cout << " is INTERNAL" << '\n' ; break ;
+ case TopAbs_EXTERNAL : std::cout << " is EXTERNAL" << '\n' ; break ;
}
}
}
- std::cout << std::endl ;
+ std::cout << '\n' ;
}
void GeomConvert_ApproxCurve::Dump(Standard_OStream& o) const
{
- o << "******* Dump of ApproxCurve *******" << std::endl;
- o << "*******Error " << MaxError() << std::endl;
+ o << "******* Dump of ApproxCurve *******" << '\n';
+ o << "*******Error " << MaxError() << '\n';
}
void GeomConvert_ApproxSurface::Dump(Standard_OStream& o) const
{
- o<<std::endl;
- if (!myHasResult) { o<<"No result"<<std::endl; }
+ o<<'\n';
+ if (!myHasResult) { o<<"No result"<<'\n'; }
else {
- o<<"Result max error :"<< myMaxError <<std::endl;
+ o<<"Result max error :"<< myMaxError <<'\n';
}
- o<<std::endl;
+ o<<'\n';
}
if(Abs(alpha) > maxang) maxang = Abs(alpha);
}
}
- std::cout<<"KAlgo angle max sur bord "<<I<<" : "<<maxang<<std::endl;
- if(caplisse) std::cout<<"sur bord "<<I<<" le champ tangent change de cote!"<<std::endl;
+ std::cout<<"KAlgo angle max sur bord "<<I<<" : "<<maxang<<'\n';
+ if(caplisse) std::cout<<"sur bord "<<I<<" le champ tangent change de cote!"<<'\n';
}
}
if(papp.Distance(pbound) > maxdist) maxdist = papp.Distance(pbound);
}
- std::cout<<"Controle approx/contrainte sur bord "<<I<<" : "<<std::endl;
- std::cout<<"Distance max : "<<maxdist<<std::endl;
+ std::cout<<"Controle approx/contrainte sur bord "<<I<<" : "<<'\n';
+ std::cout<<"Distance max : "<<maxdist<<'\n';
if (donor) {
maxang = maxang*180./M_PI;
- std::cout<<"Angle max : "<<maxang<<" deg"<<std::endl;
+ std::cout<<"Angle max : "<<maxang<<" deg"<<'\n';
}
}
vv += dvv;
ww += dww;
}
- std::cout<<"Controle resultat/contrainte sur bord "<<I<<" : "<<std::endl;
- std::cout<<"Distance max : "<<maxdist<<std::endl;
+ std::cout<<"Controle resultat/contrainte sur bord "<<I<<" : "<<'\n';
+ std::cout<<"Distance max : "<<maxdist<<'\n';
if (donor) {
Standard_Real angdeg = maxang*180./M_PI;
- std::cout<<"Angle max : "<<angdeg<<" deg"<<std::endl;
+ std::cout<<"Angle max : "<<angdeg<<" deg"<<'\n';
}
#ifdef DRAW
Standard_Boolean scale = maxang>1.e-10;
gp_XYZ& Q = Pc.ChangeCoord(), DQ(0, 0, 0); //Q
if (!isconst) {
- std::cout << "Not implemented" << std::endl;
+ std::cout << "Not implemented" << '\n';
}
char buffer[255];
IS >> buffer;
if (strcmp(buffer,"Curve2ds")) {
- std::cout << "Not a Curve2d table"<<std::endl;
+ std::cout << "Not a Curve2d table"<<'\n';
return;
}
char buffer[255];
IS >> buffer;
if (strcmp(buffer,"Curves")) {
- std::cout << "Not a Curve table"<<std::endl;
+ std::cout << "Not a Curve table"<<'\n';
return;
}
if (!GS.IsNull()) {
std::cout << "\n\n";
GeomTools_SurfaceSet::PrintSurface (GS,std::cout);
- std::cout << std::endl;
+ std::cout << '\n';
return "Found Geom_Surface, see dump in std::cout";
}
if (!GC.IsNull()) {
std::cout << "\n\n";
GeomTools_CurveSet::PrintCurve(GC,std::cout);
- std::cout << std::endl;
+ std::cout << '\n';
return "Found Geom_Curve, see dump in std::cout";
}
if (!GC2d.IsNull()) {
std::cout << "\n\n";
GeomTools_Curve2dSet::PrintCurve2d(GC2d,std::cout);
- std::cout << std::endl;
+ std::cout << '\n';
return "Found Geom2d_Curve, see dump in std::cout";
}
char buffer[255];
IS >> buffer;
if (strcmp(buffer,"Surfaces")) {
- std::cout << "Not a surface table"<<std::endl;
+ std::cout << "Not a surface table"<<'\n';
return;
}
if (!compact)
OS << "****** UNKNOWN CURVE TYPE ******\n";
else
- std::cout << "****** UNKNOWN CURVE TYPE ******" << std::endl;
+ std::cout << "****** UNKNOWN CURVE TYPE ******" << '\n';
}
//=======================================================================
if (!compact)
OS << "****** UNKNOWN CURVE2d TYPE ******\n";
else
- std::cout << "****** UNKNOWN CURVE2d TYPE ******" << std::endl;
+ std::cout << "****** UNKNOWN CURVE2d TYPE ******" << '\n';
}
//=======================================================================
if (!compact)
OS << "****** UNKNOWN SURFACE TYPE ******\n";
else
- std::cout << "****** UNKNOWN SURFACE TYPE ******" << std::endl;
+ std::cout << "****** UNKNOWN SURFACE TYPE ******" << '\n';
}
Standard_IStream& GeomTools_UndefinedTypeHandler::ReadSurface(const Standard_Integer /*ctype*/,
if(proj.NbPoints() == 0)
{
- std::cout << "No project point was found." << std::endl;
+ std::cout << "No project point was found." << '\n';
return 0;
}
Standard_Integer Compt = 1;
if(nblines >= 1)
- std::cout << " Lines: " << std::endl;
+ std::cout << " Lines: " << '\n';
for (i = 1; i <= nblines; i++, Compt++)
{
}
if(nbpoints >= 1)
- std::cout << " Points: " << std::endl;
+ std::cout << " Points: " << '\n';
const Standard_Integer imax = nblines+nbpoints;
{
if (n < 5)
{
- std::cout<<" Use xdistcc c1 c2 t1 t2 nbp"<<std::endl;
+ std::cout<<" Use xdistcc c1 c2 t1 t2 nbp"<<'\n';
return 0;
}
aC1=DrawTrSurf::GetCurve(a[1]);
if (aC1.IsNull())
{
- std::cout<<a[1]<<" is null curve"<<std::endl;
+ std::cout<<a[1]<<" is null curve"<<'\n';
return 0;
}
aC2=DrawTrSurf::GetCurve(a[2]);
if (aC2.IsNull())
{
- std::cout<<a[2]<<" is null curve"<<std::endl;
+ std::cout<<a[2]<<" is null curve"<<'\n';
return 0;
}
dout << aMr;
}
- std::cout << "Max distance = " << aMaxDist << std::endl;
- std::cout << "Param = " << aMaxParam << std::endl;
+ std::cout << "Max distance = " << aMaxDist << '\n';
+ std::cout << "Param = " << aMaxParam << '\n';
return 0;
}
{
if (n < 7)
{
- std::cout<<" Use xdistc2dc2dss c2d_1 c2d_2 s1 s2 t1 t2 nbp"<<std::endl;
+ std::cout<<" Use xdistc2dc2dss c2d_1 c2d_2 s1 s2 t1 t2 nbp"<<'\n';
return 0;
}
aC2d1=DrawTrSurf::GetCurve2d(a[1]);
if (aC2d1.IsNull())
{
- std::cout<<a[1]<<" is null 2dcurve"<<std::endl;
+ std::cout<<a[1]<<" is null 2dcurve"<<'\n';
return 0;
}
aC2d2=DrawTrSurf::GetCurve2d(a[2]);
if (aC2d2.IsNull())
{
- std::cout<<a[2]<<" is null 2dcurve"<<std::endl;
+ std::cout<<a[2]<<" is null 2dcurve"<<'\n';
return 0;
}
aS1=DrawTrSurf::GetSurface(a[3]);
if (aS1.IsNull())
{
- std::cout<<a[3]<<" is null surface"<<std::endl;
+ std::cout<<a[3]<<" is null surface"<<'\n';
return 0;
}
aS2=DrawTrSurf::GetSurface(a[4]);
if (aS2.IsNull())
{
- std::cout<<a[4]<<" is null surface"<<std::endl;
+ std::cout<<a[4]<<" is null surface"<<'\n';
return 0;
}
dout << aMr;
}
- std::cout << "Max distance = " << aMaxDist << std::endl;
- std::cout << "Param = " << aMaxParam << std::endl;
+ std::cout << "Max distance = " << aMaxDist << '\n';
+ std::cout << "Param = " << aMaxParam << '\n';
return 0;
}
{
if (n < 6)
{
- std::cout<<" Use xdistcc2ds c c2d s t1 t2 nbp"<<std::endl;
+ std::cout<<" Use xdistcc2ds c c2d s t1 t2 nbp"<<'\n';
return 0;
}
aC=DrawTrSurf::GetCurve(a[1]);
if (aC.IsNull())
{
- std::cout<<a[1]<<" is null curve"<<std::endl;
+ std::cout<<a[1]<<" is null curve"<<'\n';
return 0;
}
aC2d=DrawTrSurf::GetCurve2d(a[2]);
if (aC2d.IsNull())
{
- std::cout<<a[2]<<" is null 2dcurve"<<std::endl;
+ std::cout<<a[2]<<" is null 2dcurve"<<'\n';
return 0;
}
aS=DrawTrSurf::GetSurface(a[3]);
if (aS.IsNull())
{
- std::cout<<a[3]<<" is null surface"<<std::endl;
+ std::cout<<a[3]<<" is null surface"<<'\n';
return 0;
}
dout << aMr;
}
- std::cout << "Max distance = " << aMaxDist << std::endl;
- std::cout << "Param = " << aMaxParam << std::endl;
+ std::cout << "Max distance = " << aMaxDist << '\n';
+ std::cout << "Param = " << aMaxParam << '\n';
return 0;
}
static Standard_Integer xdistcs(Draw_Interpretor& di, Standard_Integer n, const char** a)
{
if (n < 6) {
- std::cout << "Use: xdistcs curve surface t1 t2 nbpoints [tol [warn_tol]]" << std::endl;
- std::cout << "Measures distances from curve to surface by nbpoints probing points on a curve" << std::endl;
- std::cout << "Error will be reported for points where distance is greater than tol" << std::endl;
- std::cout << "Warning will be reported for points where distance is greater than warn_tol" << std::endl;
+ std::cout << "Use: xdistcs curve surface t1 t2 nbpoints [tol [warn_tol]]" << '\n';
+ std::cout << "Measures distances from curve to surface by nbpoints probing points on a curve" << '\n';
+ std::cout << "Error will be reported for points where distance is greater than tol" << '\n';
+ std::cout << "Warning will be reported for points where distance is greater than warn_tol" << '\n';
return 0;
}
//
if(aDist > Precision::SquareConfusion())
{
Standard_Real aD = sqrt(aDist);
- std::cout<<"Surfaces differ for U,V,Dist: "<<aU<<" "<<aV<<" "<<aD<<std::endl;
+ std::cout<<"Surfaces differ for U,V,Dist: "<<aU<<" "<<aV<<" "<<aD<<'\n';
}
}
}
if (!aDir.Exists()
|| !aProgramFile.Exists())
{
- std::cerr << "Standard GLSL programs are not found in: " << THE_SHADERS_FOLDER.ToCString() << std::endl;
+ std::cerr << "Standard GLSL programs are not found in: " << THE_SHADERS_FOLDER.ToCString() << '\n';
throw Standard_Failure("CSF_ShadersDirectory or CASROOT is set incorrectly");
}
}
std::cout << std::setw(20)<< Nod1RValues.Point.X();
std::cout << std::setw(20)<< Nod1RValues.Point.Y();
std::cout << std::setw(20)<< Nod1RValues.Point.Z();
- std::cout << std::endl;
+ std::cout << '\n';
}
for (i = 1; i <= myNbPISeg; i++) {
std::cout << std::setw(6) << aSegIndices->NxtSg2;
std::cout << std::setw(6) << aSegIndices->Conex1;
std::cout << std::setw(6) << aSegIndices->Conex2;
- std::cout << std::endl;
+ std::cout << '\n';
}
for (i = 1; i <= myNbTData; i++) {
std::cout << std::setw(6) << aTriangle.Node1;
std::cout << std::setw(6) << aTriangle.Node2;
std::cout << std::setw(6) << aTriangle.Node3;
- std::cout << std::endl;
+ std::cout << '\n';
}
}
if (myDebug)
{
std::cout << "An exception was caught when preparing the Shape " << i;
- std::cout << " and computing its OutLines " << std::endl;
- std::cout << anException << std::endl;
+ std::cout << " and computing its OutLines " << '\n';
+ std::cout << anException << '\n';
}
DS[i-1] = new HLRBRep_Data(0,0,0);
dv = 0;
Standard_Integer i,n = myShapes.Length();
if (myDebug)
- std::cout << " Partial hiding" << std::endl << std::endl;
+ std::cout << " Partial hiding" << '\n' << '\n';
for (i = 1; i <= n; i++)
Hide(i);
Standard_Integer i,j,n = myShapes.Length();
if (myDebug)
- std::cout << " Total hiding" << std::endl;
+ std::cout << " Total hiding" << '\n';
for (i = 1; i <= n; i++)
Hide(i);
"HLRBRep_InternalAlgo::Hide : unknown Shape");
if (myDebug)
- std::cout << " hiding the shape " << I << " by itself" << std::endl;
+ std::cout << " hiding the shape " << I << " by itself" << '\n';
Select(I);
InitEdgeStatus();
((MinMaxShBJ->Max[7] - MinMaxShBI->Min[7]) & 0x80008000) == 0) {
if (myDebug) {
std::cout << " hiding the shape " << I;
- std::cout << " by the shape : " << J << std::endl;
+ std::cout << " by the shape : " << J << '\n';
}
SelectEdge(I);
SelectFace(J);
if (myDebug)
{
- std::cout << std::endl;
- std::cout << "Vertices : " << std::setw(5) << myDS->NbVertices() << std::endl;
+ std::cout << '\n';
+ std::cout << "Vertices : " << std::setw(5) << myDS->NbVertices() << '\n';
std::cout << "Edges : " << std::setw(5) << myDS->NbEdges() << " , ";
std::cout << "Selected : " << std::setw(5) << nbSelEdges << " , ";
- std::cout << "Visible : " << std::setw(5) << nbVisEdges << std::endl;
+ std::cout << "Visible : " << std::setw(5) << nbVisEdges << '\n';
std::cout << "Faces : " << std::setw(5) << myDS->NbFaces() << " , ";
std::cout << "Selected : " << std::setw(5) << nbSelFaces << " , ";
- std::cout << "Simple : " << std::setw(5) << nbFSimp << std::endl;
+ std::cout << "Simple : " << std::setw(5) << nbFSimp << '\n';
if (SideFace)
std::cout << "Side : " << std::setw(5) << nbFSide << " , ";
- std::cout << "Cachantes : " << std::setw(5) << nbCache << std::endl << std::endl;
+ std::cout << "Cachantes : " << std::setw(5) << nbCache << '\n' << '\n';
}
}
else {
if (myDebug && HLRBRep_InternalAlgo_TRACE) {
j++;
- std::cout << " OwnHiding " << j << " of face : " << f << std::endl;
+ std::cout << " OwnHiding " << j << " of face : " << f << '\n';
}
}
Cache.OwnHiding(f);
void HLRTest_OutLiner::Dump (Standard_OStream& S) const
{
- S << "This is an outliner" << std::endl;
+ S << "This is an outliner" << '\n';
}
//=======================================================================
}
S << "\n";
}
- S << std::endl;
+ S << '\n';
}
//=======================================================================
} else {
std::cout << "======" ;
}
- std::cout << "=============================" << std::endl ;
+ std::cout << "=============================" << '\n' ;
if (myHasFirstPoint) {
myFirstPoint.Dump (1) ;
} else {
- std::cout << " Has not a first point" << std::endl ;
+ std::cout << " Has not a first point" << '\n' ;
}
if (myHasSecondPoint) {
mySecondPoint.Dump (2) ;
} else {
- std::cout << " Has not a second point" << std::endl ;
+ std::cout << " Has not a second point" << '\n' ;
}
- std::cout << "==============================================" << std::endl ;
+ std::cout << "==============================================" << '\n' ;
}
} else {
std::cout << "------" ;
}
- std::cout << "---------------" << std::endl ;
+ std::cout << "---------------" << '\n' ;
- std::cout << " Index of the element = " << myIndex << std::endl ;
- std::cout << " Parameter on element = " << myParam << std::endl ;
+ std::cout << " Index of the element = " << myIndex << '\n' ;
+ std::cout << " Parameter on element = " << myParam << '\n' ;
std::cout << " Position on element = " ;
switch (myPosit) {
case TopAbs_FORWARD : std::cout << "FORWARD (i.e. BEGIN )" ; break ;
case TopAbs_REVERSED : std::cout << "REVERSED (i.e. END )" ; break ;
case TopAbs_EXTERNAL : std::cout << "EXTERNAL (i.e. UNKNOWN)" ; break ;
}
- std::cout << std::endl ;
+ std::cout << '\n' ;
std::cout << " Intersection Type = " ;
switch (myType) {
case HatchGen_TRUE : std::cout << "TRUE" ; break ;
case HatchGen_TANGENT : std::cout << "TANGENT" ; break ;
case HatchGen_UNDETERMINED : std::cout << "UNDETERMINED" ; break ;
}
- std::cout << std::endl ;
+ std::cout << '\n' ;
std::cout << " State Before = " ;
switch (myBefore) {
case TopAbs_IN : std::cout << "IN" ; break ;
case TopAbs_ON : std::cout << "ON" ; break ;
case TopAbs_UNKNOWN : std::cout << "UNKNOWN" ; break ;
}
- std::cout << std::endl ;
+ std::cout << '\n' ;
std::cout << " State After = " ;
switch (myAfter) {
case TopAbs_IN : std::cout << "IN" ; break ;
case TopAbs_ON : std::cout << "ON" ; break ;
case TopAbs_UNKNOWN : std::cout << "UNKNOWN" ; break ;
}
- std::cout << std::endl ;
- std::cout << " Beginning of segment = " << (mySegBeg ? "TRUE" : "FALSE") << std::endl ;
- std::cout << " End of segment = " << (mySegEnd ? "TRUE" : "FALSE") << std::endl ;
+ std::cout << '\n' ;
+ std::cout << " Beginning of segment = " << (mySegBeg ? "TRUE" : "FALSE") << '\n' ;
+ std::cout << " End of segment = " << (mySegEnd ? "TRUE" : "FALSE") << '\n' ;
- std::cout << " ------------------------------------------" << std::endl ;
+ std::cout << " ------------------------------------------" << '\n' ;
}
} else {
std::cout << "------" ;
}
- std::cout << "------------------" << std::endl ;
+ std::cout << "------------------" << '\n' ;
- std::cout << " Index of the hatching = " << myIndex << std::endl ;
- std::cout << " Parameter on hatching = " << myParam << std::endl ;
+ std::cout << " Index of the hatching = " << myIndex << '\n' ;
+ std::cout << " Parameter on hatching = " << myParam << '\n' ;
std::cout << " Position on hatching = " ;
switch (myPosit) {
case TopAbs_FORWARD : std::cout << "FORWARD (i.e. BEGIN )" ; break ;
case TopAbs_REVERSED : std::cout << "REVERSED (i.e. END )" ; break ;
case TopAbs_EXTERNAL : std::cout << "EXTERNAL (i.e. UNKNOWN)" ; break ;
}
- std::cout << std::endl ;
+ std::cout << '\n' ;
std::cout << " State Before = " ;
switch (myBefore) {
case TopAbs_IN : std::cout << "IN" ; break ;
case TopAbs_ON : std::cout << "ON" ; break ;
case TopAbs_UNKNOWN : std::cout << "UNKNOWN" ; break ;
}
- std::cout << std::endl ;
+ std::cout << '\n' ;
std::cout << " State After = " ;
switch (myAfter) {
case TopAbs_IN : std::cout << "IN" ; break ;
case TopAbs_ON : std::cout << "ON" ; break ;
case TopAbs_UNKNOWN : std::cout << "UNKNOWN" ; break ;
}
- std::cout << std::endl ;
- std::cout << " Beginning of segment = " << (mySegBeg ? "TRUE" : "FALSE") << std::endl ;
- std::cout << " End of segment = " << (mySegEnd ? "TRUE" : "FALSE") << std::endl ;
+ std::cout << '\n' ;
+ std::cout << " Beginning of segment = " << (mySegBeg ? "TRUE" : "FALSE") << '\n' ;
+ std::cout << " End of segment = " << (mySegEnd ? "TRUE" : "FALSE") << '\n' ;
Standard_Integer NbPnt = myPoints.Length () ;
if (NbPnt == 0) {
- std::cout << " No points on element" << std::endl ;
+ std::cout << " No points on element" << '\n' ;
} else {
- std::cout << " Contains " << NbPnt << " points on element" << std::endl ;
+ std::cout << " Contains " << NbPnt << " points on element" << '\n' ;
for (Standard_Integer IPnt = 1 ; IPnt <= NbPnt ; IPnt++) {
const HatchGen_PointOnElement& Point = myPoints.Value (IPnt) ;
Point.Dump (IPnt) ;
}
}
- std::cout << "----------------------------------------------" << std::endl ;
+ std::cout << "----------------------------------------------" << '\n' ;
}
if (modif.IsNull()) return;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- sout << "--- Run Modifier:" << std::endl;
+ sout << "--- Run Modifier:" << '\n';
Handle(IFSelect_Selection) sel = modif->Selection();
if (!sel.IsNull()) sout<<" Selection:"<<sel->Label();
else sout<<" (no Selection)";
for (Standard_Integer i = 1; i <= nb; i ++) {
if (thelist.Value(i) != ' ') ne ++;
}
- if (nb == ne) sout<<" All Model ("<<nb<<" Entities)"<<std::endl;
- else sout<<" Entities,Total:"<<nb<<" Concerned:"<<ne<<std::endl;
+ if (nb == ne) sout<<" All Model ("<<nb<<" Entities)"<<'\n';
+ else sout<<" Entities,Total:"<<nb<<" Concerned:"<<ne<<'\n';
}
if (thecurr <= 0) return;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (ValueOriginal() == ValueResult())
- sout<<"-- ContextModif. Entity n0 "<<thecurr<<std::endl;
+ sout<<"-- ContextModif. Entity n0 "<<thecurr<<'\n';
else
sout<<"-- ContextModif. Entity in Original, n0 "<<thecurr<<" in Result, n0 "
- <<thecurt<<std::endl;
- if (mess[0] != '\0') sout<<"-- Message:"<<mess<<std::endl;
+ <<thecurt<<'\n';
+ if (mess[0] != '\0') sout<<"-- Message:"<<mess<<'\n';
}
void IFSelect_EditForm::PrintDefs (Standard_OStream& S) const
{
Standard_Integer iv, nbv = NbValues(Standard_True);
- S<<"***** EditForm, Label : "<<Label()<<std::endl;
- if (IsComplete()) S<<"Complete, "<<nbv<<" Values"<<std::endl;
+ S<<"***** EditForm, Label : "<<Label()<<'\n';
+ if (IsComplete()) S<<"Complete, "<<nbv<<" Values"<<'\n';
else {
- S<<"Extraction on "<<nbv<<" Values : (extracted<-editor)"<<std::endl;
+ S<<"Extraction on "<<nbv<<" Values : (extracted<-editor)"<<'\n';
for (iv = 1; iv <= nbv; iv ++) S<<" "<<iv<<"<-"<<NumberFromRank(iv);
- S<<std::endl;
+ S<<'\n';
}
- S<<"*****"<<std::endl;
+ S<<"*****"<<'\n';
}
(const Handle(TColStd_HSequenceOfHAsciiString)& list,
Standard_OStream& S, const Standard_Boolean alsolist)
{
- if (list.IsNull()) { S<<"(NULL LIST)"<<std::endl; return; }
+ if (list.IsNull()) { S<<"(NULL LIST)"<<'\n'; return; }
Standard_Integer i,nb = list->Length();
- S<<"(List : "<<nb<<" Items)"<<std::endl;
+ S<<"(List : "<<nb<<" Items)"<<'\n';
if (!alsolist) return;
for (i = 1; i <= nb; i ++) {
Handle(TCollection_HAsciiString) str = list->Value(i);
- S<<" ["<<i<<"] "<< (str.IsNull() ? "(NULL)" : str->ToCString())<<std::endl;
+ S<<" ["<<i<<"] "<< (str.IsNull() ? "(NULL)" : str->ToCString())<<'\n';
}
}
const Standard_Boolean names, const Standard_Boolean alsolist) const
{
Standard_Integer iv, nbv = NbValues(Standard_True);
- S<< "****************************************************"<<std::endl;
- S<<"***** "<<Label()<<Interface_MSG::Blanks(Label(),40)<<"*****"<<std::endl;
- S<<"***** *****"<<std::endl;
+ S<< "****************************************************"<<'\n';
+ S<<"***** "<<Label()<<Interface_MSG::Blanks(Label(),40)<<"*****"<<'\n';
+ S<<"***** *****"<<'\n';
if (!theloaded)
- S<<"***** Values are NOT loaded *****"<<std::endl;
+ S<<"***** Values are NOT loaded *****"<<'\n';
else {
// Donnees sur lesquelles on a travaille
else { S<<"***** Loaded entity : "; themodel->PrintLabel (theent, S); }
}
}
- S<<std::endl<<"****************************************************"<<std::endl<<std::endl;
+ S<<'\n'<<"****************************************************"<<'\n'<<'\n';
// Affichage des valeurs
Standard_Boolean nams = names;
Standard_Integer maxnam = theeditor->MaxNameLength (names ? 0 : -1);
if (maxnam == 0) { maxnam = theeditor->MaxNameLength (0); nams = Standard_True; }
Standard_Integer nbmod = 0;
- if (what != 0) S<<"Mod N0 Name Value"<<std::endl;
- else S<<" N0 Name Value"<<std::endl;
+ if (what != 0) S<<"Mod N0 Name Value"<<'\n';
+ else S<<" N0 Name Value"<<'\n';
for (iv = 1; iv <= nbv; iv ++) {
Standard_Integer jv = NumberFromRank(iv);
if (what < 0) str = OriginalValue (jv);
if (what > 0) str = EditedValue (jv);
- S<< (str.IsNull() ? "(NULL)" : str->ToCString()) <<std::endl;
+ S<< (str.IsNull() ? "(NULL)" : str->ToCString()) <<'\n';
// Modified only
} else {
Handle(TCollection_HAsciiString) str = OriginalValue (jv);
S<<Interface_MSG::Blanks(iv,3)<<iv<<" "
<<name<<Interface_MSG::Blanks(name,maxnam)<<" ORIG:"
- << (str.IsNull() ? "(NULL)" : str->ToCString()) <<std::endl;
+ << (str.IsNull() ? "(NULL)" : str->ToCString()) <<'\n';
str = EditedValue (jv);
- S<<Interface_MSG::Blanks("",maxnam+4)<<" MOD :"<< (str.IsNull() ? "(NULL)" : str->ToCString()) <<std::endl;
+ S<<Interface_MSG::Blanks("",maxnam+4)<<" MOD :"<< (str.IsNull() ? "(NULL)" : str->ToCString()) <<'\n';
}
}
- if (what == 0) S<<"On "<<nbv<<" Values, "<<nbmod<<" Modified"<<std::endl;
+ if (what == 0) S<<"On "<<nbv<<" Values, "<<nbmod<<" Modified"<<'\n';
}
void IFSelect_Editor::PrintNames (Standard_OStream& S) const
{
Standard_Integer i, nb = NbValues();
- S<<"**** Editor : "<<Label()<<std::endl;
- S<<"**** Nb Values = "<<nb<<" **** Names / Labels"<<std::endl;
+ S<<"**** Editor : "<<Label()<<'\n';
+ S<<"**** Nb Values = "<<nb<<" **** Names / Labels"<<'\n';
S<<" Num ";
if (themaxsh > 0) S<<"Short"<<Interface_MSG::Blanks("Short",themaxsh)<<" ";
- S<<"Complete"<<Interface_MSG::Blanks("Complete",themaxco)<<" Label"<<std::endl;
+ S<<"Complete"<<Interface_MSG::Blanks("Complete",themaxco)<<" Label"<<'\n';
for (i = 1; i <= nb; i ++) {
Handle(Interface_TypedValue) tv = TypedValue(i);
const TCollection_AsciiString& sho = theshorts(i);
S<<sho<<Interface_MSG::Blanks(sho.ToCString(),themaxsh)<<" ";
}
- S<<tv->Name()<<Interface_MSG::Blanks(tv->Name(),themaxco)<<" "<<tv->Label()<<std::endl;
+ S<<tv->Name()<<Interface_MSG::Blanks(tv->Name(),themaxco)<<" "<<tv->Label()<<'\n';
}
}
(Standard_OStream& S, const Standard_Boolean labels) const
{
Standard_Integer i, nb = NbValues();
- S<<"**** Editor : "<<Label()<<std::endl;
- S<<"**** Nb Values = "<<nb<<" **** "<<(labels ? "Labels" : "Names")<<" / Definitions"<<std::endl;
+ S<<"**** Editor : "<<Label()<<'\n';
+ S<<"**** Nb Values = "<<nb<<" **** "<<(labels ? "Labels" : "Names")<<" / Definitions"<<'\n';
S<<" Num ";
if (labels) S<<"Label"<<Interface_MSG::Blanks("Label",themaxla);
else {
if (themaxsh > 0) S<<"Short"<<Interface_MSG::Blanks("Short",themaxsh+1);
S<<"Complete"<<Interface_MSG::Blanks("Complete",themaxco);
}
- S<<" Edit Mode & Definition"<<std::endl;
+ S<<" Edit Mode & Definition"<<'\n';
for (i = 1; i <= nb; i ++) {
Handle(Interface_TypedValue) tv = TypedValue(i);
default : S<<"?????????"; break;
}
- S<<" "<<tv->Definition()<<std::endl;
+ S<<" "<<tv->Definition()<<'\n';
}
}
// **** Version & cie ****
//#58 rln
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- sout<<"Processor Version : "<<XSTEP_PROCESSOR_VERSION<<std::endl;
- sout<<"OL Version : "<<XSTEP_SYSTEM_VERSION<<std::endl;
- sout<<"Configuration : "<<XSTEP_Config<<std::endl;
- sout<<"UL Names : "<<XSTEP_ULNames<<std::endl;
+ sout<<"Processor Version : "<<XSTEP_PROCESSOR_VERSION<<'\n';
+ sout<<"OL Version : "<<XSTEP_SYSTEM_VERSION<<'\n';
+ sout<<"Configuration : "<<XSTEP_Config<<'\n';
+ sout<<"UL Names : "<<XSTEP_ULNames<<'\n';
return IFSelect_RetVoid;
}
// **** ToggleHandler ****
Standard_Boolean hand = !WS->ErrorHandle();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (hand) sout << " -- Mode Catch Error now Active" <<std::endl;
- else sout << " -- Mode Catch Error now Inactive" <<std::endl;
+ if (hand) sout << " -- Mode Catch Error now Active" <<'\n';
+ else sout << " -- Mode Catch Error now Inactive" <<'\n';
WS->SetErrorHandle(hand);
return IFSelect_RetDone;
}
const Standard_CString arg1 = pilot->Arg(1);
// **** XRead / Load ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Read/Load : give file name !"<<std::endl; return IFSelect_RetError; }
- if (WS->Protocol().IsNull()) { sout<<"Protocol not defined"<<std::endl; return IFSelect_RetError; }
- if (WS->WorkLibrary().IsNull()) { sout<<"WorkLibrary not defined"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Read/Load : give file name !"<<'\n'; return IFSelect_RetError; }
+ if (WS->Protocol().IsNull()) { sout<<"Protocol not defined"<<'\n'; return IFSelect_RetError; }
+ if (WS->WorkLibrary().IsNull()) { sout<<"WorkLibrary not defined"<<'\n'; return IFSelect_RetError; }
IFSelect_ReturnStatus status = WS->ReadFile (arg1);
// status : 0 OK, 1 erreur lecture, 2 Fail(try/catch),
// -1 fichier non trouve, -2 lecture faite mais resultat vide
switch (status) {
- case IFSelect_RetVoid : sout<<"file:"<<arg1<<" gives empty result"<<std::endl; break;
- case IFSelect_RetError : sout<<"file:"<<arg1<<" could not be opened"<<std::endl; break;
- case IFSelect_RetDone : sout<<"file:"<<arg1<<" read"<<std::endl; break;
- case IFSelect_RetFail : sout<<"file:"<<arg1<<" : error while reading"<<std::endl; break;
- case IFSelect_RetStop : sout<<"file:"<<arg1<<" : EXCEPTION while reading"<<std::endl; break;
- default : sout<<"file:"<<arg1<<" could not be read"<<std::endl; break;
+ case IFSelect_RetVoid : sout<<"file:"<<arg1<<" gives empty result"<<'\n'; break;
+ case IFSelect_RetError : sout<<"file:"<<arg1<<" could not be opened"<<'\n'; break;
+ case IFSelect_RetDone : sout<<"file:"<<arg1<<" read"<<'\n'; break;
+ case IFSelect_RetFail : sout<<"file:"<<arg1<<" : error while reading"<<'\n'; break;
+ case IFSelect_RetStop : sout<<"file:"<<arg1<<" : EXCEPTION while reading"<<'\n'; break;
+ default : sout<<"file:"<<arg1<<" could not be read"<<'\n'; break;
}
if (status != IFSelect_RetDone) return status;
// sout<<" - clearing list of already written files"<<std::endl;
const Standard_CString arg1 = pilot->Arg(1);
// **** Write All ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Write All : give file name !"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Write All : give file name !"<<'\n'; return IFSelect_RetError; }
return WS->SendAll (arg1);
}
// const Standard_CString arg2 = pilot->Arg(2);
// **** Write Selected ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 3) { sout<<"Write Selected : give file name + givelist !"<<std::endl; return IFSelect_RetError; }
+ if (argc < 3) { sout<<"Write Selected : give file name + givelist !"<<'\n'; return IFSelect_RetError; }
Handle(TColStd_HSequenceOfTransient) result =
IFSelect_Functions::GiveList (WS,pilot->CommandPart( 2));
- if (result.IsNull()) { sout<<"No entity selected"<<std::endl; return IFSelect_RetError; }
- else sout<<"Nb Entities selected : "<<result->Length()<<std::endl;
+ if (result.IsNull()) { sout<<"No entity selected"<<'\n'; return IFSelect_RetError; }
+ else sout<<"Nb Entities selected : "<<result->Length()<<'\n';
Handle(IFSelect_SelectPointed) sp = new IFSelect_SelectPointed;
sp->SetList (result);
return WS->SendSelected (arg1,sp);
const Standard_CString arg1 = pilot->Arg(1);
// **** Write Entite(s) ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 3) { sout<<"Write Entitie(s) : give file name + n0s entitie(s)!"<<std::endl; return IFSelect_RetError; }
+ if (argc < 3) { sout<<"Write Entitie(s) : give file name + n0s entitie(s)!"<<'\n'; return IFSelect_RetError; }
int ko = 0;
Handle(IFSelect_SelectPointed) sp = new IFSelect_SelectPointed;
for (Standard_Integer ia = 2; ia < argc ; ia ++) {
Standard_Integer id = pilot->Number(pilot->Arg(ia));
if (id > 0) {
Handle(Standard_Transient) item = WS->StartingEntity(id);
- if (sp->Add(item)) sout<<"Added:no."<<id<<std::endl;
- else { sout<<" Fail Add n0."<<id<<std::endl; ko ++; }
+ if (sp->Add(item)) sout<<"Added:no."<<id<<'\n';
+ else { sout<<" Fail Add n0."<<id<<'\n'; ko ++; }
}
- else { sout<<"Not an entity number:"<<pilot->Arg(ia)<<std::endl; ko ++; }
+ else { sout<<"Not an entity number:"<<pilot->Arg(ia)<<'\n'; ko ++; }
}
- if (ko > 0) { sout<<ko<<" bad arguments, abandon"<<std::endl; return IFSelect_RetError; }
+ if (ko > 0) { sout<<ko<<" bad arguments, abandon"<<'\n'; return IFSelect_RetError; }
return WS->SendSelected (arg1,sp);
}
const Standard_CString arg1 = pilot->Arg(1);
// **** Entity Label ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Give entity number"<<std::endl; return IFSelect_RetError; }
- if (!WS->HasModel()) { sout<<"No loaded model, abandon"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Give entity number"<<'\n'; return IFSelect_RetError; }
+ if (!WS->HasModel()) { sout<<"No loaded model, abandon"<<'\n'; return IFSelect_RetError; }
Standard_Integer nument = WS->NumberFromLabel (arg1);
if (nument <= 0 || nument > WS->NbStartingEntities())
- { sout<<"Not a suitable number: "<<arg1<<std::endl; return IFSelect_RetError; }
+ { sout<<"Not a suitable number: "<<arg1<<'\n'; return IFSelect_RetError; }
sout<<"N0."<<nument<<" ->Label in Model : ";
WS->Model()->PrintLabel(WS->StartingEntity(nument), sout);
- sout<<std::endl;
+ sout<<'\n';
return IFSelect_RetVoid;
}
const Standard_CString arg1 = pilot->Arg(1);
// **** Entity Number ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Give label to search"<<std::endl; return IFSelect_RetError; }
- if (!WS->HasModel()) { sout<<"No loaded model, abandon"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Give label to search"<<'\n'; return IFSelect_RetError; }
+ if (!WS->HasModel()) { sout<<"No loaded model, abandon"<<'\n'; return IFSelect_RetError; }
const Handle(Interface_InterfaceModel) &model = WS->Model();
Standard_Integer i, cnt = 0;
Standard_Boolean exact = Standard_False;
- sout<<" ** Search Entity Number for Label : "<<arg1<<std::endl;
+ sout<<" ** Search Entity Number for Label : "<<arg1<<'\n';
for (i = model->NextNumberForLabel (arg1, 0, exact) ; i != 0;
i = model->NextNumberForLabel (arg1, i, exact)) {
cnt ++;
sout<<" ** Found n0/id:";
model->Print (model->Value(i), sout);
- sout<<std::endl;
+ sout<<'\n';
}
- if (cnt == 0) sout<<" ** No Match"<<std::endl;
- else if (cnt == 1) sout<<" ** 1 Match"<<std::endl;
- else sout<<cnt<<" Matches"<<std::endl;
+ if (cnt == 0) sout<<" ** No Match"<<'\n';
+ else if (cnt == 1) sout<<" ** 1 Match"<<'\n';
+ else sout<<cnt<<" Matches"<<'\n';
return IFSelect_RetVoid;
}
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc < 2) {
- sout<<"Designer signature ou compteur, + facultatif selection + facultatif entite"<<std::endl;
- sout<<" signature/compteur seul -> tout le modele"<<std::endl
- << " sign/compteur + selection -> cette selection, evaluation normale"<<std::endl
- <<" sign/compteur + sel + num -> cette selection evaluee sur entite n0 num"<<std::endl;
+ sout<<"Designer signature ou compteur, + facultatif selection + facultatif entite"<<'\n';
+ sout<<" signature/compteur seul -> tout le modele"<<'\n'
+ << " sign/compteur + selection -> cette selection, evaluation normale"<<'\n'
+ <<" sign/compteur + sel + num -> cette selection evaluee sur entite n0 num"<<'\n';
return IFSelect_RetError;
}
DeclareAndCast(IFSelect_SignCounter,counter,WS->NamedItem(arg1));
for (i = 1; i < onflag; i ++) {
sel = WS->GiveSelection(pilot->Arg(i));
if (!suite->AddInput(sel)) {
- sout<<"Incorrect definition for applied selection"<<std::endl;
+ sout<<"Incorrect definition for applied selection"<<'\n';
return IFSelect_RetError;
}
}
}
if (counter.IsNull()) {
- sout<<"Neither Counter nor Signature : "<<arg1<<std::endl;
+ sout<<"Neither Counter nor Signature : "<<arg1<<'\n';
return IFSelect_RetError;
}
// **** Sign Type ****
Handle(IFSelect_Signature) signtype = WS->SignType();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (signtype.IsNull()) sout<<"signtype actually undefined"<<std::endl;
+ if (signtype.IsNull()) sout<<"signtype actually undefined"<<'\n';
else {
Handle(TCollection_HAsciiString) str = WS->Name (signtype);
Standard_Integer id = WS->ItemIdent (signtype);
- sout<<signtype->Label()<<std::endl;
+ sout<<signtype->Label()<<'\n';
if (str.IsNull()) {
- if (id > 0) sout<<"signtype : item n0 "<<id<<std::endl;
+ if (id > 0) sout<<"signtype : item n0 "<<id<<'\n';
} else {
- sout<<"signtype : also named as "<<str->ToCString()<<std::endl;
+ sout<<"signtype : also named as "<<str->ToCString()<<'\n';
}
}
- if (argc < 2) sout<<"signtype newitem to change, signtype . to clear"<<std::endl;
+ if (argc < 2) sout<<"signtype newitem to change, signtype . to clear"<<'\n';
else {
if (arg1[0] == '.' && arg1[1] == '\0') {
signtype.Nullify();
- sout<<"signtype now cleared"<<std::endl;
+ sout<<"signtype now cleared"<<'\n';
} else {
signtype = GetCasted(IFSelect_Signature,WS->NamedItem(arg1));
- if (signtype.IsNull()) { sout<<"Not a Signature : "<<arg1<<std::endl; return IFSelect_RetError; }
- else sout<<"signtype now set to "<<arg1<<std::endl;
+ if (signtype.IsNull()) { sout<<"Not a Signature : "<<arg1<<'\n'; return IFSelect_RetError; }
+ else sout<<"signtype now set to "<<arg1<<'\n';
}
WS->SetSignType(signtype);
return IFSelect_RetDone;
// **** Sign Case ****
Handle(IFSelect_Signature) signcase = GetCasted(IFSelect_Signature,WS->NamedItem(arg1));
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (signcase.IsNull()) sout<<"Not a Signature : "<<arg1<<std::endl;
+ if (signcase.IsNull()) sout<<"Not a Signature : "<<arg1<<'\n';
else {
Standard_Boolean hasmin,hasmax; Standard_Integer valmin,valmax;
if (signcase->IsIntCase(hasmin,valmin,hasmax,valmax)) {
sout<<"Signature "<<arg1<<" : Integer Case";
if (hasmin) sout<<" - Mini:"<<valmin;
if (hasmax) sout<<" - Maxi:"<<valmax;
- sout<<std::endl;
+ sout<<'\n';
}
Handle(TColStd_HSequenceOfAsciiString) caselist = signcase->CaseList();
- if (caselist.IsNull()) sout<<"Signature "<<arg1<<" : no predefined case, see command count "<<arg1<<std::endl;
+ if (caselist.IsNull()) sout<<"Signature "<<arg1<<" : no predefined case, see command count "<<arg1<<'\n';
else {
Standard_Integer i, nb = caselist->Length();
- sout<<"Signature "<<arg1<<" : "<<nb<<" basic cases :"<<std::endl;
+ sout<<"Signature "<<arg1<<" : "<<nb<<" basic cases :"<<'\n';
for (i = 1; i <= nb; i ++) sout<<" "<<caselist->Value(i);
- sout<<std::endl;
+ sout<<'\n';
}
}
return IFSelect_RetVoid;
sout<<" Categories defined :"<<nb<<" i.e. :\n";
for (i = 0; i <= nb; i ++)
sout<<"Cat."<<i<<" : "<<Interface_Category::Name(i)<<"\n";
- sout<<" On a given entity : give its number"<<std::endl;
+ sout<<" On a given entity : give its number"<<'\n';
return IFSelect_RetVoid;
}
Standard_Integer num = pilot->Number(arg1);
if (num <= 0 || num > WS->NbStartingEntities())
- { sout<<"Not a suitable entity number : "<<arg1<<std::endl; return IFSelect_RetError; }
+ { sout<<"Not a suitable entity number : "<<arg1<<'\n'; return IFSelect_RetError; }
Handle(Standard_Transient) ent = WS->StartingEntity(num);
WS->PrintEntityStatus (ent, sout);
return IFSelect_RetVoid;
<<" check CheckList (complete) per message (counting)\n"
<<" totalcheck CheckList (complete) per message (listing n0 ents)\n"
<<" FAILS CheckList (fails) per message (listing complete)\n"
- <<" TOTALCHECK CheckList (complete) per message (listing complete)"<<std::endl;
+ <<" TOTALCHECK CheckList (complete) per message (listing complete)"<<'\n';
return IFSelect_RetVoid;
case 'g' : niv = 0; break;
case 'r' : niv = 1; break;
case 'T' : niv = 7; break;
case 'f' : niv = 8; break;
case 'F' : niv =10; break;
- default : sout<<"Unknown Mode . data tout court pour help"<<std::endl; return IFSelect_RetError;
+ default : sout<<"Unknown Mode . data tout court pour help"<<'\n'; return IFSelect_RetError;
}
WS->TraceDumpModel(niv);
return IFSelect_RetVoid;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc < 2 || (argc == 2 && levmax < 0)) {
sout<<"Give n0 or id of entity";
- if (levmax < 0) sout<<" and dump level"<<std::endl;
- else sout<<" + optional, dump level in [0 - "<<levmax<<"] , default = "<<levdef<<std::endl;
+ if (levmax < 0) sout<<" and dump level"<<'\n';
+ else sout<<" + optional, dump level in [0 - "<<levmax<<"] , default = "<<levdef<<'\n';
for (level = 0; level <= levmax; level ++) {
Standard_CString help = WL->DumpHelp (level);
- if (help[0] != '\0') sout<<level<<" : "<<help<<std::endl;
+ if (help[0] != '\0') sout<<level<<" : "<<help<<'\n';
}
return IFSelect_RetError;
}
if (argc > 2) level = atoi(arg2);
Handle(Standard_Transient) ent = WS->StartingEntity(num);
if ( ent.IsNull() ) {
- sout << "No entity with given id " << arg1 << " (" << num << ") is found in the current model" << std::endl;
+ sout << "No entity with given id " << arg1 << " (" << num << ") is found in the current model" << '\n';
}
else {
- sout << " -- DUMP Entity n0 " << num << " level " << level << std::endl;
+ sout << " -- DUMP Entity n0 " << num << " level " << level << '\n';
WL->DumpEntity (WS->Model(),WS->Protocol(),ent,sout,level);
Interface_CheckIterator chl = WS->CheckOne (ent);
const Standard_CString arg1 = pilot->Arg(1);
const Standard_CString arg2 = pilot->Arg(2);
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 3) { sout<<" Give signature name + n0 or id of entity"<<std::endl; return IFSelect_RetError; }
+ if (argc < 3) { sout<<" Give signature name + n0 or id of entity"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_Signature,sign,WS->NamedItem(arg1));
- if (sign.IsNull()) { sout<<"Not a signature : "<<arg1<<std::endl; return IFSelect_RetError; }
+ if (sign.IsNull()) { sout<<"Not a signature : "<<arg1<<'\n'; return IFSelect_RetError; }
Standard_Integer num = pilot->Number(arg2);
Handle(Standard_Transient) ent = WS->StartingEntity (num);
if (num == 0) return IFSelect_RetError;
- sout<<"Entity n0 "<<num<<" : "<<WS->SignValue(sign,ent)<<std::endl;
+ sout<<"Entity n0 "<<num<<" : "<<WS->SignValue(sign,ent)<<'\n';
return IFSelect_RetVoid;
}
const Standard_CString arg1 = pilot->Arg(1);
const Standard_CString arg2 = pilot->Arg(2);
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 3) { sout<<" Give 2 numeros or labels : dad son"<<std::endl; return IFSelect_RetError; }
+ if (argc < 3) { sout<<" Give 2 numeros or labels : dad son"<<'\n'; return IFSelect_RetError; }
Standard_Integer n1 = WS->NumberFromLabel(arg1);
Standard_Integer n2 = WS->NumberFromLabel(arg2);
- sout<<"QueryParent for dad:"<<arg1<<":"<<n1<<" and son:"<<arg2<<":"<<n2<<std::endl;
+ sout<<"QueryParent for dad:"<<arg1<<":"<<n1<<" and son:"<<arg2<<":"<<n2<<'\n';
Standard_Integer qp = WS->QueryParent(WS->StartingEntity(n1),WS->StartingEntity(n2));
- if (qp < 0) sout<<arg1<<" is not super-entity of "<<arg2<<std::endl;
- else if (qp == 0) sout<<arg1<<" is same as "<<arg2<<std::endl;
- else sout<<arg1<<" is super-entity of "<<arg2<<" , max level found="<<qp<<std::endl;
+ if (qp < 0) sout<<arg1<<" is not super-entity of "<<arg2<<'\n';
+ else if (qp == 0) sout<<arg1<<" is same as "<<arg2<<'\n';
+ else sout<<arg1<<" is super-entity of "<<arg2<<" , max level found="<<qp<<'\n';
// sout<<" Trouve "<<qp<<std::endl;
return IFSelect_RetVoid;
}
const Standard_CString arg1 = pilot->Arg(1);
// **** NewInt ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 1) { sout<<"Donner la valeur entiere pour IntParam"<<std::endl; return IFSelect_RetError; }
+ if (argc < 1) { sout<<"Donner la valeur entiere pour IntParam"<<'\n'; return IFSelect_RetError; }
Handle(IFSelect_IntParam) intpar = new IFSelect_IntParam;
if (argc >= 1) intpar->SetValue(atoi(arg1));
return pilot->RecordItem (intpar);
// **** SetInt ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc < 3)
- { sout<<"Donner 2 arguments : nom Parametre et Valeur"<<std::endl; return IFSelect_RetError; }
+ { sout<<"Donner 2 arguments : nom Parametre et Valeur"<<'\n'; return IFSelect_RetError; }
Standard_Integer val = atoi(arg2);
DeclareAndCast(IFSelect_IntParam,par,WS->NamedItem(arg1));
if (!WS->SetIntValue(par,val)) return IFSelect_RetFail;
const Standard_CString arg1 = pilot->Arg(1);
// **** NewText ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 1) { sout<<"Donner la valeur texte pour TextParam"<<std::endl; return IFSelect_RetError; }
+ if (argc < 1) { sout<<"Donner la valeur texte pour TextParam"<<'\n'; return IFSelect_RetError; }
Handle(TCollection_HAsciiString) textpar = new TCollection_HAsciiString();
if (argc >= 1) textpar->AssignCat(arg1);
return pilot->RecordItem (textpar);
// **** SetText ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc < 3)
- { sout<<"Donner 2 arguments : nom Parametre et Valeur"<<std::endl; return IFSelect_RetError; }
+ { sout<<"Donner 2 arguments : nom Parametre et Valeur"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(TCollection_HAsciiString,par,WS->NamedItem(arg1));
if (!WS->SetTextValue(par,arg2)) return IFSelect_RetFail;
return IFSelect_RetDone;
const Standard_CString arg1 = pilot->Arg(1);
// **** DumpSel ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Give 1 argument : Selection Name"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Give 1 argument : Selection Name"<<'\n'; return IFSelect_RetError; }
WS->DumpSelection (GetCasted(IFSelect_Selection,WS->NamedItem(arg1)));
return IFSelect_RetVoid;
}
char mode = pilot->Arg(0)[0]; // givelist/makelist
if (mode == 'g') mode = pilot->Arg(0)[4]; // l list s short p pointed
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Give Entity ID, or Selection Name [+ optional other selection or entity]"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Give Entity ID, or Selection Name [+ optional other selection or entity]"<<'\n'; return IFSelect_RetError; }
// MakeList : sur Pointed existante ou a creer
Handle(IFSelect_SelectPointed) pnt;
Handle(Standard_Transient) item = WS->NamedItem (arg1);
pnt = GetCasted(IFSelect_SelectPointed,item);
if (!pnt.IsNull()) {
- sout<<arg1<<":Already existing Selection for List, cleared then filled"<<std::endl;
+ sout<<arg1<<":Already existing Selection for List, cleared then filled"<<'\n';
pnt->Clear();
} else if (!item.IsNull()) {
- sout<<arg1<<":Already existing Item not for a List, command ignored"<<std::endl;
+ sout<<arg1<<":Already existing Item not for a List, command ignored"<<'\n';
return IFSelect_RetFail;
} else {
pnt = new IFSelect_SelectPointed;
sout<<iter.NbEntities()<<" Entities : ";
for (iter.Start(); iter.More(); iter.Next())
sout<<" +"<<WS->StartingNumber (iter.Value());
- sout<<std::endl;
+ sout<<'\n';
}
if (!pnt.IsNull()) {
pnt->SetList (result);
- sout<<"List set to a SelectPointed : "<<pilot->Arg(1)<<std::endl;
- sout<<"Later editable by command setlist"<<std::endl;
+ sout<<"List set to a SelectPointed : "<<pilot->Arg(1)<<'\n';
+ sout<<"Later editable by command setlist"<<'\n';
}
return IFSelect_RetVoid;
Standard_Integer argc = pilot->NbWords();
// **** GiveCount ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Give Entity ID, or Selection Name [+ optional other selection or entity]"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Give Entity ID, or Selection Name [+ optional other selection or entity]"<<'\n'; return IFSelect_RetError; }
// WS->EvaluateSelection(GetCasted(IFSelect_Selection,WS->NamedItem(arg1)));
Handle(TColStd_HSequenceOfTransient) result =
IFSelect_Functions::GiveList (WS,pilot->CommandPart(1));
if (result.IsNull()) return IFSelect_RetError;
- sout<<pilot->CommandPart(1)<<" : List of "<<result->Length()<<" Entities"<<std::endl;
+ sout<<pilot->CommandPart(1)<<" : List of "<<result->Length()<<" Entities"<<'\n';
return IFSelect_RetVoid;
}
Standard_Integer argc = pilot->NbWords();
// **** SelSuite ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Give Entity ID, or Selection Name [+ optional other selection or entity]"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Give Entity ID, or Selection Name [+ optional other selection or entity]"<<'\n'; return IFSelect_RetError; }
// WS->EvaluateSelection(GetCasted(IFSelect_Selection,WS->NamedItem(arg1)));
Handle(IFSelect_SelectSuite) selsuite = new IFSelect_SelectSuite;
for (Standard_Integer i = 1; i < argc; i ++) {
Handle(IFSelect_Selection) sel = WS->GiveSelection(pilot->Arg(i));
if (!selsuite->AddInput(sel)) {
- sout<<pilot->Arg(i-1)<<" : not a SelectDeduct, no more can be added. Abandon"<<std::endl;
+ sout<<pilot->Arg(i-1)<<" : not a SelectDeduct, no more can be added. Abandon"<<'\n';
return IFSelect_RetError;
}
}
if (mode <= 0) {
if (mode < 0) sout<<"Give a suitable mode";
sout<<" Available Modes :\n"
- <<" a : all data g : graph+check c : check p : selectpointed"<<std::endl;
+ <<" a : all data g : graph+check c : check p : selectpointed"<<'\n';
return (mode < 0 ? IFSelect_RetError : IFSelect_RetVoid);
}
WS->ClearData (mode);
// **** Item Label ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
TCollection_AsciiString label;
- if (argc < 2) { sout<<" Give label to search"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<" Give label to search"<<'\n'; return IFSelect_RetError; }
for (int i = 1; i < argc; i ++) {
label.AssignCat(pilot->Arg(i));
if (i < argc-1) label.AssignCat(" ");
for (int mode = 0; mode <= 2; mode ++) {
int nbitems = 0; int id;
sout<<"Searching label : "<<label<<". in mode ";
- if (mode == 0) sout <<" exact" << std::endl;
- if (mode == 1) sout <<" same head" << std::endl;
- if (mode == 2) sout <<" search if present" << std::endl;
+ if (mode == 0) sout <<" exact" << '\n';
+ if (mode == 1) sout <<" same head" << '\n';
+ if (mode == 2) sout <<" search if present" << '\n';
for (id = WS->NextIdentForLabel(label.ToCString(), 0,mode) ; id != 0;
id = WS->NextIdentForLabel(label.ToCString(),id,mode)) {
sout<<" "<<id; nbitems ++;
}
- sout<<" -- giving " << nbitems << " found" << std::endl;
+ sout<<" -- giving " << nbitems << " found" << '\n';
}
return IFSelect_RetVoid;
}
const Standard_CString arg1 = pilot->Arg(1);
// **** Save (Dump) ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Donner nom du Fichier"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner nom du Fichier"<<'\n'; return IFSelect_RetError; }
IFSelect_SessionFile dumper(WS,arg1);
if (!dumper.IsDone()) return IFSelect_RetFail;
return IFSelect_RetDone;
const Standard_CString arg1 = pilot->Arg(1);
// **** Restore (Dump) ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Donner nom du Fichier"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner nom du Fichier"<<'\n'; return IFSelect_RetError; }
IFSelect_SessionFile dumper(WS);
Standard_Integer readstat = dumper.Read(arg1);
if (readstat == 0) return IFSelect_RetDone;
- else if (readstat > 0) sout << "-- Erreur Lecture Fichier "<<arg1<<std::endl;
- else sout << "-- Pas pu ouvrir Fichier "<<arg1<<std::endl;
+ else if (readstat > 0) sout << "-- Erreur Lecture Fichier "<<arg1<<'\n';
+ else sout << "-- Pas pu ouvrir Fichier "<<arg1<<'\n';
return IFSelect_RetDone;
}
{
aPatternNb = nb;
}
- sout << " List of parameters : " << aPatternNb << " items : " << std::endl;
+ sout << " List of parameters : " << aPatternNb << " items : " << '\n';
for (i = 1; i <= nb; i ++) {
if (argc == 3 && strncmp(li->Value(i)->String().ToCString(), arg2, aPatternLen) != 0)
{
continue;
}
sout<<li->Value(i)->String();
- sout<<" : "<<Interface_Static::CVal(li->Value(i)->ToCString())<<std::endl;
+ sout<<" : "<<Interface_Static::CVal(li->Value(i)->ToCString())<<'\n';
}
return IFSelect_RetVoid;
} else if (atoi(arg1) > 0) {
Standard_Integer use = atoi (arg1);
WS->TraceStatics (use);
} else {
- if (argc > 2) sout<<" FORMER STATUS of Static Parameter "<<arg1<<std::endl;
- else sout<<" ACTUAL STATUS of Static Parameter "<<arg1<<std::endl;
- if (!Interface_Static::IsPresent(arg1)) { sout<<" Parameter "<<arg1<<" undefined"<<std::endl; return IFSelect_RetError; }
- if (!Interface_Static::IsSet(arg1)) sout<<" Parameter "<<arg1<<" not valued"<<std::endl;
+ if (argc > 2) sout<<" FORMER STATUS of Static Parameter "<<arg1<<'\n';
+ else sout<<" ACTUAL STATUS of Static Parameter "<<arg1<<'\n';
+ if (!Interface_Static::IsPresent(arg1)) { sout<<" Parameter "<<arg1<<" undefined"<<'\n'; return IFSelect_RetError; }
+ if (!Interface_Static::IsSet(arg1)) sout<<" Parameter "<<arg1<<" not valued"<<'\n';
else if (argc == 2) Interface_Static::Static (arg1) -> Print (sout);
- else sout<<" Value : "<<Interface_Static::CVal(arg1)<<std::endl;
+ else sout<<" Value : "<<Interface_Static::CVal(arg1)<<'\n';
- if (argc == 2) sout<<"To modify, param name_param new_val"<<std::endl;
+ if (argc == 2) sout<<"To modify, param name_param new_val"<<'\n';
else {
if (strlen(arg2) != 0)
{
sout<<" New demanded value : not valued";
}
if (Interface_Static::SetCVal (arg1,arg2))
- { sout<<" OK"<<std::endl; return IFSelect_RetDone; }
- else { sout <<" , refused"<<std::endl; return IFSelect_RetError; }
+ { sout<<" OK"<<'\n'; return IFSelect_RetDone; }
+ else { sout <<" , refused"<<'\n'; return IFSelect_RetError; }
}
}
return IFSelect_RetVoid;
Handle(TColStd_HSequenceOfHAsciiString) list = WS->SentFiles();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (list.IsNull())
- { sout<<"List of Sent Files not enabled"<<std::endl; return IFSelect_RetVoid; }
+ { sout<<"List of Sent Files not enabled"<<'\n'; return IFSelect_RetVoid; }
Standard_Integer i, nb = list->Length();
- sout<<" Sent Files : "<<nb<<" : "<<std::endl;
+ sout<<" Sent Files : "<<nb<<" : "<<'\n';
for (i = 1; i <= nb; i ++)
- sout<<list->Value(i)->ToCString()<<std::endl;
+ sout<<list->Value(i)->ToCString()<<'\n';
return IFSelect_RetVoid;
}
// **** FilePrefix ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc < 2) {
- if (WS->FilePrefix().IsNull()) sout<<"Pas de prefixe defini"<<std::endl;
- else sout<<"Prefixe : "<<WS->FilePrefix()->ToCString()<<std::endl;
- sout<<"Pour changer : filepref newprefix"<<std::endl;
+ if (WS->FilePrefix().IsNull()) sout<<"Pas de prefixe defini"<<'\n';
+ else sout<<"Prefixe : "<<WS->FilePrefix()->ToCString()<<'\n';
+ sout<<"Pour changer : filepref newprefix"<<'\n';
return IFSelect_RetVoid;
}
WS->SetFilePrefix(arg1);
// **** FileExtension ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc < 2) {
- if (WS->FileExtension().IsNull()) sout<<"Pas d extension definie"<<std::endl;
- else sout<<"Extension : "<<WS->FileExtension()->ToCString()<<std::endl;
- sout<<"Pour changer : fileext newext"<<std::endl;
+ if (WS->FileExtension().IsNull()) sout<<"Pas d extension definie"<<'\n';
+ else sout<<"Extension : "<<WS->FileExtension()->ToCString()<<'\n';
+ sout<<"Pour changer : fileext newext"<<'\n';
return IFSelect_RetVoid;
}
WS->SetFileExtension(arg1);
const Standard_CString arg2 = pilot->Arg(2);
// **** FileRoot ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Donner Dispatch et nom de Root"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner Dispatch et nom de Root"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_Dispatch,disp,WS->NamedItem(arg1));
if (argc < 3) {
- if (WS->FileRoot(disp).IsNull()) sout<<"Pas de racine definie pour "<<arg1<<std::endl;
- else sout<<"Racine pour "<<arg1<<" : "<<WS->FileRoot(disp)->ToCString()<<std::endl;
- sout<<"Pour changer : fileroot nomdisp newroot"<<std::endl;
+ if (WS->FileRoot(disp).IsNull()) sout<<"Pas de racine definie pour "<<arg1<<'\n';
+ else sout<<"Racine pour "<<arg1<<" : "<<WS->FileRoot(disp)->ToCString()<<'\n';
+ sout<<"Pour changer : fileroot nomdisp newroot"<<'\n';
return IFSelect_RetVoid;
}
if (!WS->SetFileRoot(disp,arg2)) return IFSelect_RetFail;
// **** Default File Root ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc < 2) {
- if (WS->DefaultFileRoot().IsNull()) sout<<"Pas de racine par defaut definie"<<std::endl;
- else sout<<"Racine par defaut : "<<WS->DefaultFileRoot()->ToCString()<<std::endl;
- sout<<"Pour changer : filedef newdef"<<std::endl;
+ if (WS->DefaultFileRoot().IsNull()) sout<<"Pas de racine par defaut definie"<<'\n';
+ else sout<<"Racine par defaut : "<<WS->DefaultFileRoot()->ToCString()<<'\n';
+ sout<<"Pour changer : filedef newdef"<<'\n';
return IFSelect_RetVoid;
}
WS->SetDefaultFileRoot(arg1);
// **** EvalFile ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (!WS->HasModel())
- { sout<<"Pas de Modele charge, abandon"<<std::endl; return IFSelect_RetFail; }
+ { sout<<"Pas de Modele charge, abandon"<<'\n'; return IFSelect_RetFail; }
- sout<<"Evaluation avec Memorisation des resultats"<<std::endl;
+ sout<<"Evaluation avec Memorisation des resultats"<<'\n';
WS->EvaluateFile();
Standard_Integer nbf = WS->NbFiles();
for (Standard_Integer i = 1; i <= nbf; i ++) {
Handle(Interface_InterfaceModel) mod = WS->FileModel(i);
if (mod.IsNull())
- { sout<<"Modele "<<i<<" Model non genere ..."<<std::endl; continue; }
+ { sout<<"Modele "<<i<<" Model non genere ..."<<'\n'; continue; }
TCollection_AsciiString name = WS->FileName(i);
sout<<"Fichier n0 "<<i<<" Nb Entites : "<<mod->NbEntities()<<" Nom: ";
- sout<<name<<std::endl;
+ sout<<name<<'\n';
}
return IFSelect_RetDone;
}
// **** Split ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
IFSelect_ReturnStatus stat = IFSelect_RetVoid;
- if (argc < 2) sout<<"Split : derniere liste de dispatches definie"<<std::endl;
+ if (argc < 2) sout<<"Split : derniere liste de dispatches definie"<<'\n';
else {
WS->ClearShareOut(Standard_True);
for (Standard_Integer i = 1; i < argc; i ++) {
DeclareAndCast(IFSelect_Dispatch,disp,WS->NamedItem(pilot->Arg(i)));
if (disp.IsNull()) {
- sout<<"Pas un dispatch:"<<pilot->Arg(i)<<", Splitt abandonne"<<std::endl;
+ sout<<"Pas un dispatch:"<<pilot->Arg(i)<<", Splitt abandonne"<<'\n';
stat = IFSelect_RetError;
}
else WS->SetActive(disp,Standard_True);
else {
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc<2) sout<<"Donner un Mode - ";
- sout<<"Modes possibles : l list, c compute, u undo, f forget"<<std::endl;
+ sout<<"Modes possibles : l list, c compute, u undo, f forget"<<'\n';
if (mode == '?') return IFSelect_RetDone; else return IFSelect_RetError;
}
if (!WS->SetRemaining(numod)) return IFSelect_RetVoid;
const Standard_CString arg2 = pilot->Arg(2);
// **** SetModelContent ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 3) { sout<<"Donner nom selection et mode (k=keep,r=remove)"<<std::endl; return IFSelect_RetError; }
+ if (argc < 3) { sout<<"Donner nom selection et mode (k=keep,r=remove)"<<'\n'; return IFSelect_RetError; }
Standard_Boolean keepmode;
DeclareAndCast(IFSelect_Selection,sel,WS->NamedItem(arg1));
if (sel.IsNull())
- { sout<<"Pas de Selection de Nom : "<<arg1<<std::endl; return IFSelect_RetError; }
+ { sout<<"Pas de Selection de Nom : "<<arg1<<'\n'; return IFSelect_RetError; }
if (arg2[0] == 'k') { sout<<" -- SetContent keep ..."; keepmode = Standard_True; }
else if (arg2[0] == 'r') { sout<<" -- SetContent remove ..."; keepmode = Standard_False; }
- else { sout<<"Donner nom selection et mode (k=keep,r=remove)"<<std::endl; return IFSelect_RetError; }
+ else { sout<<"Donner nom selection et mode (k=keep,r=remove)"<<'\n'; return IFSelect_RetError; }
- if (WS->SetModelContent(sel,keepmode)) sout<<" Done"<<std::endl;
- else sout<<" Result empty, ignored"<<std::endl;
+ if (WS->SetModelContent(sel,keepmode)) sout<<" Done"<<'\n';
+ else sout<<" Result empty, ignored"<<'\n';
return IFSelect_RetDone;
}
const Standard_CString arg1 = pilot->Arg(1);
// **** Modifier ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Donner Nom du Modifier"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner Nom du Modifier"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_GeneralModifier,modif,WS->NamedItem(arg1));
if (modif.IsNull())
- { sout<<"Pas de Modifier de Nom : "<<arg1<<std::endl; return IFSelect_RetVoid; }
+ { sout<<"Pas de Modifier de Nom : "<<arg1<<'\n'; return IFSelect_RetVoid; }
Handle(IFSelect_IntParam) low,up;
Handle(IFSelect_Dispatch) disp = modif->Dispatch();
- sout<<"Modifier : "<<arg1<<" Label : "<<modif->Label()<<std::endl;
+ sout<<"Modifier : "<<arg1<<" Label : "<<modif->Label()<<'\n';
Standard_Integer rank = WS->ModifierRank(modif);
if (modif->IsKind(STANDARD_TYPE(IFSelect_Modifier)))
sout<< "Model Modifier n0." << rank;
else sout<< "File Modifier n0." << rank;
- if (disp.IsNull()) sout<<" Applique a tous les Dispatchs" << std::endl;
+ if (disp.IsNull()) sout<<" Applique a tous les Dispatchs" << '\n';
else {
sout << " Dispatch : "<<disp->Label();
if (WS->HasName(disp)) sout << " - Nom:"<<WS->Name(disp)->ToCString();
- sout<<std::endl;
+ sout<<'\n';
}
Handle(IFSelect_Selection) sel = modif->Selection();
if (!sel.IsNull()) sout<<" Selection : "<< sel->Label();
if (WS->HasName(sel)) sout<<" - Nom:"<< WS->Name(sel)->ToCString();
- sout<<std::endl;
+ sout<<'\n';
return IFSelect_RetVoid;
}
// **** ModifSel ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc < 2) { sout<<"Donner Nom Modifier; + Nom Selection optionnel\n"
- <<"Selection pour Mettre une Selection, sinon Annule"<<std::endl; return IFSelect_RetError; }
+ <<"Selection pour Mettre une Selection, sinon Annule"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_GeneralModifier,modif,WS->NamedItem(arg1));
if (modif.IsNull())
- { sout<<"Pas un nom de Modifier : "<<arg1<<std::endl; return IFSelect_RetError; }
+ { sout<<"Pas un nom de Modifier : "<<arg1<<'\n'; return IFSelect_RetError; }
Handle(IFSelect_Selection) sel;
if (arg2[0] != '\0') {
sel = GetCasted(IFSelect_Selection,WS->NamedItem(arg2));
if (sel.IsNull())
- { sout<<"Pas un nom de Selection : "<<arg2<<std::endl; return IFSelect_RetError; }
+ { sout<<"Pas un nom de Selection : "<<arg2<<'\n'; return IFSelect_RetError; }
}
if (!WS->SetItemSelection(modif,sel)) return IFSelect_RetFail;
return IFSelect_RetDone;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc < 2) { sout<<"Donner Nom Modifier; + Nom Dispatch ou Transformer optionnel :\n"
<<" - rien : tous Dispatches\n - Dispatch : ce Dispatch seul\n"
- <<" - Transformer : pas un Dispatch mais un Transformer"<<std::endl;
+ <<" - Transformer : pas un Dispatch mais un Transformer"<<'\n';
return IFSelect_RetError; }
DeclareAndCast(IFSelect_GeneralModifier,modif,WS->NamedItem(arg1));
if (modif.IsNull())
- { sout<<"Pas un nom de Modifier : "<<arg1<<std::endl; return IFSelect_RetError; }
+ { sout<<"Pas un nom de Modifier : "<<arg1<<'\n'; return IFSelect_RetError; }
Handle(Standard_Transient) item;
if (arg2[0] != '\0') {
item = WS->NamedItem(arg2);
if (item.IsNull())
- { sout<<"Pas un nom connu : "<<arg2<<std::endl; return IFSelect_RetError; }
+ { sout<<"Pas un nom connu : "<<arg2<<'\n'; return IFSelect_RetError; }
}
else item = WS->ShareOut();
if (!WS->SetAppliedModifier(modif,item)) return IFSelect_RetFail;
const Standard_CString arg1 = pilot->Arg(1);
// **** ResetApplied (modifier) ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Designer un modifier"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Designer un modifier"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_GeneralModifier,modif,WS->NamedItem(arg1));
if (modif.IsNull())
- { sout<<"Pas un nom de Modifier : "<<arg1<<std::endl; return IFSelect_RetError; }
+ { sout<<"Pas un nom de Modifier : "<<arg1<<'\n'; return IFSelect_RetError; }
if (!WS->ResetAppliedModifier(modif)) return IFSelect_RetFail;
return IFSelect_RetDone;
}
const Standard_CString arg3 = pilot->Arg(3);
// **** ModifMove ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 4) { sout<<"modifmove MF rang1 rang2, M pour Model F pour File"<<std::endl; return IFSelect_RetError; }
+ if (argc < 4) { sout<<"modifmove MF rang1 rang2, M pour Model F pour File"<<'\n'; return IFSelect_RetError; }
Standard_Boolean formodel;
if (arg1[0] == 'm' || arg1[0] == 'M') formodel = Standard_True;
else if (arg1[0] == 'f' || arg1[0] == 'F') formodel = Standard_False;
- else { sout<<"preciser M pour Model, F pour File"<<std::endl; return IFSelect_RetError; }
+ else { sout<<"preciser M pour Model, F pour File"<<'\n'; return IFSelect_RetError; }
Standard_Integer before = atoi(arg2);
Standard_Integer after = atoi(arg3);
- if (before == 0 || after == 0) { sout<<"Donner 2 Entiers Positifs"<<std::endl; return IFSelect_RetError; }
+ if (before == 0 || after == 0) { sout<<"Donner 2 Entiers Positifs"<<'\n'; return IFSelect_RetError; }
if (!WS->ChangeModifierRank(formodel,before,after)) return IFSelect_RetFail;
return IFSelect_RetDone;
}
const Standard_CString arg2 = pilot->Arg(2);
// **** DispSel ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 3) { sout<<"Donner Noms Dispatch et Selection Finale"<<std::endl; return IFSelect_RetError; }
+ if (argc < 3) { sout<<"Donner Noms Dispatch et Selection Finale"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_Dispatch,disp,WS->NamedItem(arg1));
if (disp.IsNull())
- { sout<<"Pas un nom de Dispatch : "<<arg1<<std::endl; return IFSelect_RetError; }
+ { sout<<"Pas un nom de Dispatch : "<<arg1<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_Selection,sel,WS->NamedItem(arg2));
if (sel.IsNull())
- { sout<<"Pas un nom de Selection : "<<arg2<<std::endl; return IFSelect_RetError; }
+ { sout<<"Pas un nom de Selection : "<<arg2<<'\n'; return IFSelect_RetError; }
if (!WS->SetItemSelection(disp,sel)) return IFSelect_RetFail;
return IFSelect_RetDone;
}
const Standard_CString arg1 = pilot->Arg(1);
// **** DispCount ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Donner Nom IntParam pour Count"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner Nom IntParam pour Count"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_IntParam,par,WS->NamedItem(arg1));
if (par.IsNull())
- { sout<<"Pas un nom de IntParam : "<<arg1<<std::endl; return IFSelect_RetError; }
+ { sout<<"Pas un nom de IntParam : "<<arg1<<'\n'; return IFSelect_RetError; }
Handle(IFSelect_DispPerCount) disp = new IFSelect_DispPerCount;
disp->SetCount (par);
return pilot->RecordItem(disp);
const Standard_CString arg1 = pilot->Arg(1);
// **** DispFiles ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Donner Nom IntParam pour NbFiles"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner Nom IntParam pour NbFiles"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_IntParam,par,WS->NamedItem(arg1));
if (par.IsNull())
- { sout<<"Pas un nom de IntParam : "<<arg1<<std::endl; return IFSelect_RetError; }
+ { sout<<"Pas un nom de IntParam : "<<arg1<<'\n'; return IFSelect_RetError; }
Handle(IFSelect_DispPerFiles) disp = new IFSelect_DispPerFiles;
disp->SetCount (par);
return pilot->RecordItem(disp);
const Standard_CString arg1 = pilot->Arg(1);
// **** DispFiles ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Donner Nom Signature"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner Nom Signature"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_Signature,sig,WS->NamedItem(arg1));
if (sig.IsNull())
- { sout<<"Pas un nom de Signature : "<<arg1<<std::endl; return IFSelect_RetError; }
+ { sout<<"Pas un nom de Signature : "<<arg1<<'\n'; return IFSelect_RetError; }
Handle(IFSelect_DispPerSignature) disp = new IFSelect_DispPerSignature;
disp->SetSignCounter (new IFSelect_SignCounter(sig));
return pilot->RecordItem(disp);
const Standard_CString arg1 = pilot->Arg(1);
// **** Dispatch ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Donner Nom du Dispatch"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner Nom du Dispatch"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_Dispatch,disp,WS->NamedItem(arg1));
- if (disp.IsNull()) { sout<<"Pas un dispatch : "<<arg1<<std::endl; return IFSelect_RetError; }
+ if (disp.IsNull()) { sout<<"Pas un dispatch : "<<arg1<<'\n'; return IFSelect_RetError; }
Standard_Integer num = WS->DispatchRank(disp);
sout<<"Dispatch de Nom : "<<arg1<<" , en ShareOut, Numero "<<num<<" : ";
Handle(IFSelect_Selection) sel = WS->ItemSelection(disp);
Handle(TCollection_HAsciiString) selname = WS->Name(sel);
- if (sel.IsNull()) sout<<"Pas de Selection Finale"<<std::endl;
- else if (selname.IsNull()) sout<<"Selection Finale : #"<<WS->ItemIdent(sel)<<std::endl;
- else sout<<"Selection Finale : "<<selname->ToCString()<<std::endl;
+ if (sel.IsNull()) sout<<"Pas de Selection Finale"<<'\n';
+ else if (selname.IsNull()) sout<<"Selection Finale : #"<<WS->ItemIdent(sel)<<'\n';
+ else sout<<"Selection Finale : "<<selname->ToCString()<<'\n';
if (disp->HasRootName()) sout<<"-- Racine nom de fichier : "
- <<disp->RootName()->ToCString()<<std::endl;
+ <<disp->RootName()->ToCString()<<'\n';
return IFSelect_RetVoid;
}
const Standard_CString arg1 = pilot->Arg(1);
// **** Remove ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Give Name to Remove !"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Give Name to Remove !"<<'\n'; return IFSelect_RetError; }
if (!WS->RemoveNamedItem(arg1)) return IFSelect_RetFail;
return IFSelect_RetDone;
}
// **** EvalDisp ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc < 3) { sout<<"evaldisp mode disp [disp ...] : Mode + Name(s) of Dispatch(es). Mode:\n"
- <<" 0 brief 1 +forgotten ents 2 +duplicata 3 1+2"<<std::endl
- <<"See also : evaladisp writedisp xsplit"<<std::endl;
+ <<" 0 brief 1 +forgotten ents 2 +duplicata 3 1+2"<<'\n'
+ <<"See also : evaladisp writedisp xsplit"<<'\n';
return IFSelect_RetVoid; }
Standard_Boolean OK = Standard_True;
Standard_Integer i , mode = atoi(arg1); sout<<" Mode "<<mode<<"\n";
for (i = 2; i < argc; i ++) {
DeclareAndCast(IFSelect_Dispatch,disp,WS->NamedItem(pilot->Arg(i)));
if (disp.IsNull())
- { sout<<"Not a dispatch:"<<pilot->Arg(i)<<std::endl; OK = Standard_False; }
+ { sout<<"Not a dispatch:"<<pilot->Arg(i)<<'\n'; OK = Standard_False; }
}
if (!OK) {
- sout<<"Some of the parameters are not correct"<<std::endl;
+ sout<<"Some of the parameters are not correct"<<'\n';
return IFSelect_RetError;
}
// **** EvalADisp [GiveList] ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc < 3) { sout<<"evaladisp mode(=0-1-2-3) disp [givelist] : Mode + Dispatch [+ GiveList]\n If GiveList not given, computed from Selection of the Dispatch. Mode:\n"
- <<" 0 brief 1 +forgotten ents 2 +duplicata 3 1+2"<<std::endl
- <<"See also : writedisp"<<std::endl;
+ <<" 0 brief 1 +forgotten ents 2 +duplicata 3 1+2"<<'\n'
+ <<"See also : writedisp"<<'\n';
return IFSelect_RetVoid; }
- if (arg1[1] != '\0') { sout<<"first parameter : mode, must be a number between 0 and 3"<<std::endl; return IFSelect_RetError; }
+ if (arg1[1] != '\0') { sout<<"first parameter : mode, must be a number between 0 and 3"<<'\n'; return IFSelect_RetError; }
Standard_Integer mode = atoi(arg1); sout<<" Mode "<<mode<<"\n";
// DeclareAndCast(IFSelect_Dispatch,disp,WS->NamedItem(pilot->Arg(2)));
Handle(IFSelect_Dispatch) disp = IFSelect_Functions::GiveDispatch (WS,pilot->Arg(2),Standard_True);
if (disp.IsNull())
- { sout<<"Not a dispatch:"<<pilot->Arg(2)<<std::endl; return IFSelect_RetError; }
+ { sout<<"Not a dispatch:"<<pilot->Arg(2)<<'\n'; return IFSelect_RetError; }
Handle(IFSelect_Selection) selsav = disp->FinalSelection();
Handle(IFSelect_Selection) sel;
if (argc > 3) {
}
if (sel.IsNull() && selsav.IsNull())
- { sout<<"No Selection nor GiveList defined"<<std::endl; return IFSelect_RetError; }
+ { sout<<"No Selection nor GiveList defined"<<'\n'; return IFSelect_RetError; }
if (sel.IsNull() && !selsav.IsNull()) {
- if (argc > 3) sout<<"GiveList is empty, hence computed from the Selection of the Dispatch"<<std::endl;
+ if (argc > 3) sout<<"GiveList is empty, hence computed from the Selection of the Dispatch"<<'\n';
sel = selsav;
}
disp->SetFinalSelection(sel);
if (argc < 3) { sout<<"writedisp filename disp [givelist] : FileName + Dispatch [+ GiveList]\n If GiveList not given, computed from Selection of the Dispatch.\n"
<<"FileName : rootname.ext will gives rootname_1.ext etc...\n"
<<" path/rootname.ext gives path/rootname_1.ext etc...\n"
- <<"See also : evaladisp"<<std::endl;
+ <<"See also : evaladisp"<<'\n';
return IFSelect_RetVoid; }
TCollection_AsciiString prefix,rootname,suffix;
SplitFileName (arg1,prefix,rootname,suffix);
if (rootname.Length() == 0 || suffix.Length() == 0) {
- sout<<"Empty Root Name or Extension"<<std::endl;
+ sout<<"Empty Root Name or Extension"<<'\n';
return IFSelect_RetError;
}
// DeclareAndCast(IFSelect_Dispatch,disp,WS->NamedItem(pilot->Arg(2)));
Handle(IFSelect_Dispatch) disp = IFSelect_Functions::GiveDispatch (WS,pilot->Arg(2),Standard_True);
if (disp.IsNull())
- { sout<<"Not a dispatch:"<<pilot->Arg(2)<<std::endl; return IFSelect_RetError; }
+ { sout<<"Not a dispatch:"<<pilot->Arg(2)<<'\n'; return IFSelect_RetError; }
Handle(IFSelect_Selection) selsav = disp->FinalSelection();
Handle(IFSelect_Selection) sel;
if (argc > 3) {
}
if (sel.IsNull() && selsav.IsNull())
- { sout<<"No Selection nor GiveList defined"<<std::endl; return IFSelect_RetError; }
+ { sout<<"No Selection nor GiveList defined"<<'\n'; return IFSelect_RetError; }
if (sel.IsNull() && !selsav.IsNull()) {
- if (argc > 3) sout<<"GiveList is empty, hence computed from the Selection of the Dispatch"<<std::endl;
+ if (argc > 3) sout<<"GiveList is empty, hence computed from the Selection of the Dispatch"<<'\n';
sel = selsav;
}
Standard_Integer mode = 0;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc < 2) sout << " -- mode par defaut 0\n";
- else { mode = atoi(arg1); sout << " -- mode : " << mode << std::endl; }
+ else { mode = atoi(arg1); sout << " -- mode : " << mode << '\n'; }
WS->EvaluateComplete(mode); return IFSelect_RetVoid;
}
const Standard_CString arg1 = pilot->Arg(1);
// **** RunTransformer ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Donner Nom de Transformer"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner Nom de Transformer"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_Transformer,tsf,WS->NamedItem(arg1));
Standard_Integer effect = WS->RunTransformer(tsf);
switch (effect) {
- case -4 : sout<<"Edition sur place, nouveau Protocole, erreur recalcul graphe"<<std::endl; break;
- case -3 : sout<<"Erreur, Transformation ignoree"<<std::endl; break;
- case -2 : sout<<"Erreur sur edition sur place, risque de corruption (verifier)"<<std::endl; break;
- case -1 : sout<<"Erreur sur edition locale, risque de corruption (verifier)"<<std::endl; break;
+ case -4 : sout<<"Edition sur place, nouveau Protocole, erreur recalcul graphe"<<'\n'; break;
+ case -3 : sout<<"Erreur, Transformation ignoree"<<'\n'; break;
+ case -2 : sout<<"Erreur sur edition sur place, risque de corruption (verifier)"<<'\n'; break;
+ case -1 : sout<<"Erreur sur edition locale, risque de corruption (verifier)"<<'\n'; break;
case 0 :
- if (tsf.IsNull()) sout<<"Erreur, pas un Transformer: "<<arg1<<std::endl;
- else sout<<"Execution non faite"<<std::endl;
+ if (tsf.IsNull()) sout<<"Erreur, pas un Transformer: "<<arg1<<'\n';
+ else sout<<"Execution non faite"<<'\n';
break;
- case 1 : sout<<"Transformation locale (graphe non touche)"<<std::endl; break;
- case 2 : sout<<"Edition sur place (graphe recalcule)"<<std::endl; break;
- case 3 : sout<<"Modele reconstruit"<<std::endl; break;
- case 4 : sout<<"Edition sur place, nouveau Protocole"<<std::endl; break;
- case 5 : sout<<"Nouveau Modele avec nouveau Protocole"<<std::endl; break;
+ case 1 : sout<<"Transformation locale (graphe non touche)"<<'\n'; break;
+ case 2 : sout<<"Edition sur place (graphe recalcule)"<<'\n'; break;
+ case 3 : sout<<"Modele reconstruit"<<'\n'; break;
+ case 4 : sout<<"Edition sur place, nouveau Protocole"<<'\n'; break;
+ case 5 : sout<<"Nouveau Modele avec nouveau Protocole"<<'\n'; break;
default : break;
}
return ((effect > 0) ? IFSelect_RetDone : IFSelect_RetFail);
}
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (modif.IsNull())
- { sout<<"Pas un nom de Modifier : "<<arg1<<std::endl; return IFSelect_RetError; }
+ { sout<<"Pas un nom de Modifier : "<<arg1<<'\n'; return IFSelect_RetError; }
Handle(TColStd_HSequenceOfTransient) list;
Handle(IFSelect_SelectPointed) sp;
effect = WS->RunModifierSelected (modif,sp,runcopy);
// sout<<"Modifier applique sur TransformStandard #"<<WS->ItemIdent(tsf)<<std::endl;
switch (effect) {
- case -4 : sout<<"Edition sur place, nouveau Protocole, erreur recalcul graphe"<<std::endl; break;
- case -3 : sout<<"Erreur, Transformation ignoree"<<std::endl; break;
- case -2 : sout<<"Erreur sur edition sur place, risque de corruption (verifier)"<<std::endl; break;
- case -1 : sout<<"Erreur sur edition locale, risque de corruption (verifier)"<<std::endl; break;
+ case -4 : sout<<"Edition sur place, nouveau Protocole, erreur recalcul graphe"<<'\n'; break;
+ case -3 : sout<<"Erreur, Transformation ignoree"<<'\n'; break;
+ case -2 : sout<<"Erreur sur edition sur place, risque de corruption (verifier)"<<'\n'; break;
+ case -1 : sout<<"Erreur sur edition locale, risque de corruption (verifier)"<<'\n'; break;
case 0 :
- if (modif.IsNull()) sout<<"Erreur, pas un Modifier: "<<arg1<<std::endl;
- else sout<<"Execution non faite"<<std::endl;
+ if (modif.IsNull()) sout<<"Erreur, pas un Modifier: "<<arg1<<'\n';
+ else sout<<"Execution non faite"<<'\n';
break;
- case 1 : sout<<"Transformation locale (graphe non touche)"<<std::endl; break;
- case 2 : sout<<"Edition sur place (graphe recalcule)"<<std::endl; break;
- case 3 : sout<<"Modele reconstruit"<<std::endl; break;
- case 4 : sout<<"Edition sur place, nouveau Protocole"<<std::endl; break;
- case 5 : sout<<"Nouveau Modele avec nouveau Protocole"<<std::endl; break;
+ case 1 : sout<<"Transformation locale (graphe non touche)"<<'\n'; break;
+ case 2 : sout<<"Edition sur place (graphe recalcule)"<<'\n'; break;
+ case 3 : sout<<"Modele reconstruit"<<'\n'; break;
+ case 4 : sout<<"Edition sur place, nouveau Protocole"<<'\n'; break;
+ case 5 : sout<<"Nouveau Modele avec nouveau Protocole"<<'\n'; break;
default : break;
}
return ((effect > 0) ? IFSelect_RetDone : IFSelect_RetFail);
if (argc >= 2) opt = pilot->Word(1).Value(1);
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (opt != 'f' && opt != 'l')
- { sout<<"Donner option : f -> root-first l -> root-last"<<std::endl; return IFSelect_RetError; }
+ { sout<<"Donner option : f -> root-first l -> root-last"<<'\n'; return IFSelect_RetError; }
return pilot->RecordItem(new IFSelect_ModifReorder(opt == 'l'));
}
const Standard_CString arg1 = pilot->Arg(1);
// **** SelToggle ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Donner Nom de Selection"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner Nom de Selection"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_Selection,sel,WS->NamedItem(arg1));
if (!WS->ToggleSelectExtract(sel))
- { sout<<"Pas une SelectExtract : "<<arg1<<std::endl; return IFSelect_RetFail; }
- if (WS->IsReversedSelectExtract(sel)) sout<<arg1<<" a present Reversed"<<std::endl;
- else sout<<arg1<<" a present Directe"<<std::endl;
+ { sout<<"Pas une SelectExtract : "<<arg1<<'\n'; return IFSelect_RetFail; }
+ if (WS->IsReversedSelectExtract(sel)) sout<<arg1<<" a present Reversed"<<'\n';
+ else sout<<arg1<<" a present Directe"<<'\n';
return IFSelect_RetDone;
}
const Standard_CString arg2 = pilot->Arg(2);
// **** SelInput ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 3) { sout<<"Donner Noms Selections cible et input"<<std::endl; return IFSelect_RetError; }
+ if (argc < 3) { sout<<"Donner Noms Selections cible et input"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_Selection,sel,WS->NamedItem(arg1));
DeclareAndCast(IFSelect_Selection,sou,WS->NamedItem(arg2));
if (sel.IsNull() || sou.IsNull())
- { sout<<"Incorrect : "<<arg1<<","<<arg2<<std::endl; return IFSelect_RetError; }
+ { sout<<"Incorrect : "<<arg1<<","<<arg2<<'\n'; return IFSelect_RetError; }
if (!WS->SetInputSelection(sel,sou)) {
- sout<<"Nom incorrect ou Selection "<<arg1<<" ni Extract ni Deduct"<<std::endl;
+ sout<<"Nom incorrect ou Selection "<<arg1<<" ni Extract ni Deduct"<<'\n';
return IFSelect_RetFail;
}
return IFSelect_RetDone;
sout<<"Donner la description du SelectRange"
<<" Formes admises :\n <n1> <n2> : Range de <n1> a <n2>\n"
<<" <n1> tout seul : Range n0 <n1>\n from <n1> : Range From <n1>\n"
- <<" until <n2> : Range Until <n2>"<<std::endl;
+ <<" until <n2> : Range Until <n2>"<<'\n';
return IFSelect_RetVoid;
}
Handle(IFSelect_SelectRange) sel;
// Range From
if (pilot->Word(1).IsEqual("from")) {
- if (argc < 3) { sout<<"Forme admise : from <i>"<<std::endl; return IFSelect_RetError; }
+ if (argc < 3) { sout<<"Forme admise : from <i>"<<'\n'; return IFSelect_RetError; }
low = GetCasted(IFSelect_IntParam,WS->NamedItem(arg2));
sel = new IFSelect_SelectRange;
sel->SetFrom (low);
// Range Until
} else if (pilot->Word(1).IsEqual("until")) {
- if (argc < 3) { sout<<"Forme admise : until <i>"<<std::endl; return IFSelect_RetError; }
+ if (argc < 3) { sout<<"Forme admise : until <i>"<<'\n'; return IFSelect_RetError; }
up = GetCasted(IFSelect_IntParam,WS->NamedItem(arg2));
sel = new IFSelect_SelectRange;
sel->SetUntil (up);
Handle(IFSelect_Selection) sel = new IFSelect_SelectDiff;
if (sel.IsNull()) return IFSelect_RetFail;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 3) sout<<"Diff sans input : ne pas oublier de les definir (ctlmain, ctlsec)!"<<std::endl;
+ if (argc < 3) sout<<"Diff sans input : ne pas oublier de les definir (ctlmain, ctlsec)!"<<'\n';
DeclareAndCast(IFSelect_Selection,selmain,WS->NamedItem(arg1));
DeclareAndCast(IFSelect_Selection,selsec ,WS->NamedItem(arg2));
if (argc >= 2)
if (!WS->SetControl(sel,selmain,Standard_True))
- sout<<"Echec ControlMain:"<<arg1<<" , a refaire (ctlmain)"<<std::endl;
+ sout<<"Echec ControlMain:"<<arg1<<" , a refaire (ctlmain)"<<'\n';
if (argc >= 3)
if (!WS->SetControl(sel,selsec,Standard_False))
- sout<<"Echec ControlSecond:"<<arg2<<" , a refaire (ctlsec)"<<std::endl;
+ sout<<"Echec ControlSecond:"<<arg2<<" , a refaire (ctlsec)"<<'\n';
return pilot->RecordItem (sel);
}
const Standard_CString arg2 = pilot->Arg(2);
// **** SelControlMain ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 3) { sout<<"Donner Noms de Control et MainInput"<<std::endl; return IFSelect_RetError; }
+ if (argc < 3) { sout<<"Donner Noms de Control et MainInput"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_Selection,sel,WS->NamedItem(arg1));
DeclareAndCast(IFSelect_Selection,selmain,WS->NamedItem(arg2));
if (WS->SetControl(sel,selmain,Standard_True)) return IFSelect_RetDone;
- sout<<"Nom incorrect ou Selection "<<arg1<<" pas de type Control"<<std::endl;
+ sout<<"Nom incorrect ou Selection "<<arg1<<" pas de type Control"<<'\n';
return IFSelect_RetFail;
}
const Standard_CString arg2 = pilot->Arg(2);
// **** SelControlSecond ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 3) { sout<<"Donner Noms de Control et SecondInput"<<std::endl; return IFSelect_RetError; }
+ if (argc < 3) { sout<<"Donner Noms de Control et SecondInput"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_Selection,sel,WS->NamedItem(arg1));
DeclareAndCast(IFSelect_Selection,seldif,WS->NamedItem(arg2));
if (WS->SetControl(sel,seldif,Standard_False)) return IFSelect_RetDone;
- sout<<"Nom incorrect ou Selection "<<arg1<<" pas de type Control"<<std::endl;
+ sout<<"Nom incorrect ou Selection "<<arg1<<" pas de type Control"<<'\n';
return IFSelect_RetFail;
}
const Standard_CString arg2 = pilot->Arg(2);
// **** SelCombAdd ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 3) { sout<<"Donner n0 Combine et une Input"<<std::endl; return IFSelect_RetError; }
+ if (argc < 3) { sout<<"Donner n0 Combine et une Input"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_Selection,sel,WS->NamedItem(arg1));
DeclareAndCast(IFSelect_Selection,seladd,WS->NamedItem(arg2));
if (WS->CombineAdd(sel,seladd)) return IFSelect_RetDone;
- sout<<"Nom incorrect ou Selection "<<arg1<<" pas Combine"<<std::endl;
+ sout<<"Nom incorrect ou Selection "<<arg1<<" pas Combine"<<'\n';
return IFSelect_RetFail;
}
const Standard_CString arg2 = pilot->Arg(2);
// **** SelCombRem ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 3) { sout<<"Donner n0 Combine et RANG a supprimer"<<std::endl; return IFSelect_RetError; }
+ if (argc < 3) { sout<<"Donner n0 Combine et RANG a supprimer"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_Selection,sel,WS->NamedItem(arg1));
DeclareAndCast(IFSelect_Selection,inp,WS->NamedItem(arg2));
if (WS->CombineRemove(sel,inp)) return IFSelect_RetDone;
- sout<<"Nom incorrect ou Selection "<<arg1<<" ni Union ni Intersection"<<std::endl;
+ sout<<"Nom incorrect ou Selection "<<arg1<<" ni Union ni Intersection"<<'\n';
return IFSelect_RetFail;
}
const Standard_CString arg1 = pilot->Arg(1);
// **** SelEntNumber ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Donner Nom IntParam pour n0 Entite"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner Nom IntParam pour n0 Entite"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_IntParam,par,WS->NamedItem(arg1));
Handle(IFSelect_SelectEntityNumber) sel = new IFSelect_SelectEntityNumber;
sel->SetNumber(par);
const Standard_CString arg1 = pilot->Arg(1);
// **** SelTextType Exact ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Donner le TYPE a selectionner"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner le TYPE a selectionner"<<'\n'; return IFSelect_RetError; }
return pilot->RecordItem (new IFSelect_SelectSignature
(new IFSelect_SignType,arg1,Standard_True));
}
const Standard_CString arg1 = pilot->Arg(1);
// **** SelTextType Contain **
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Donner le TYPE a selectionner"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner le TYPE a selectionner"<<'\n'; return IFSelect_RetError; }
return pilot->RecordItem (new IFSelect_SelectSignature
(new IFSelect_SignType,arg1,Standard_False));
}
(pilot->Session(),pilot->CommandPart(1));
if (list.IsNull()) return IFSelect_RetFail;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- sout<<"SelectPointed : "<<list->Length()<<" entities"<<std::endl;
+ sout<<"SelectPointed : "<<list->Length()<<" entities"<<'\n';
sp->AddList (list);
}
return pilot->RecordItem (sp);
if (argc < 2) {
sout<<"Donner NOM SelectPointed + Option(s) :\n"
<<" aucune : liste des entites pointees\n"
- <<" 0: Clear +nn ajout entite nn -nn enleve nn /nn toggle nn"<<std::endl;
+ <<" 0: Clear +nn ajout entite nn -nn enleve nn /nn toggle nn"<<'\n';
return IFSelect_RetError;
}
DeclareAndCast(IFSelect_SelectPointed,sp,WS->NamedItem(arg1));
- if (sp.IsNull()) { sout<<"Pas une SelectPointed:"<<arg1<<std::endl; return IFSelect_RetError; }
+ if (sp.IsNull()) { sout<<"Pas une SelectPointed:"<<arg1<<'\n'; return IFSelect_RetError; }
const Handle(Interface_InterfaceModel) &model = WS->Model(); // pour Print
if (argc == 2) { // listage simple
Standard_Integer nb = sp->NbItems();
- sout<<" SelectPointed : "<<arg1<<" : "<<nb<<" Items :"<<std::endl;
+ sout<<" SelectPointed : "<<arg1<<" : "<<nb<<" Items :"<<'\n';
for (Standard_Integer i = 1; i <= nb; i ++) {
Handle(Standard_Transient) pointed = sp->Item(i);
Standard_Integer id = WS->StartingNumber(pointed);
if (id == 0) sout <<" (inconnu)";
else { sout <<" "; model->Print (pointed, sout); }
}
- if (nb > 0) sout<<std::endl;
+ if (nb > 0) sout<<'\n';
return IFSelect_RetDone;
}
const TCollection_AsciiString argi = pilot->Word(ia);
Standard_Integer id = pilot->Number(&(argi.ToCString())[1]);
if (id == 0) {
- if (!argi.IsEqual("0")) sout<<"Incorrect,ignore:"<<argi<<std::endl;
- else { sout<<"Clear SelectPointed"<<std::endl; sp->Clear(); }
+ if (!argi.IsEqual("0")) sout<<"Incorrect,ignore:"<<argi<<'\n';
+ else { sout<<"Clear SelectPointed"<<'\n'; sp->Clear(); }
} else if (argi.Value(1) == '-') {
Handle(Standard_Transient) item = WS->StartingEntity(id);
if (sp->Remove(item)) sout<<"Removed:no."<<id;
else sout<<" Echec Remove "<<id;
- sout<<": " << std::endl;
+ sout<<": " << '\n';
model->Print (item, sout);
} else if (argi.Value(1) == '/') {
Handle(Standard_Transient) item = WS->StartingEntity(id);
if (sp->Remove(item)) sout<<"Toggled:n0."<<id;
else sout<<" Echec Toggle "<<id;
- sout<<": " << std::endl;
+ sout<<": " << '\n';
model->Print (item, sout);
} else if (argi.Value(1) == '+') {
Handle(Standard_Transient) item = WS->StartingEntity(id);
if (sp->Add(item)) sout<<"Added:no."<<id;
else sout<<" Echec Add "<<id;
- sout<<": " << std::endl;
+ sout<<": " << '\n';
model->Print (item, sout);
} else {
- sout<<"Ignore:"<<argi<<" , donner n0 PRECEDE de + ou - ou /"<<std::endl;
+ sout<<"Ignore:"<<argi<<" , donner n0 PRECEDE de + ou - ou /"<<'\n';
}
}
return IFSelect_RetDone;
Handle(IFSelect_WorkSession) WS = pilot->Session();
// **** SelSignature ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 3) { sout<<"Give name of Signature or Counter, text + option exact(D) else contains"<<std::endl; return IFSelect_RetError; }
+ if (argc < 3) { sout<<"Give name of Signature or Counter, text + option exact(D) else contains"<<'\n'; return IFSelect_RetError; }
Standard_Boolean exact = Standard_True;
if (argc > 3) { if (pilot->Arg(3)[0] == 'c') exact = Standard_False; }
if (!sign.IsNull()) sel = new IFSelect_SelectSignature (sign,arg2,exact);
else if (!cnt.IsNull()) sel = new IFSelect_SelectSignature (cnt,arg2,exact);
- else { sout<<arg1<<":neither Signature nor Counter"<<std::endl; return IFSelect_RetError; }
+ else { sout<<arg1<<":neither Signature nor Counter"<<'\n'; return IFSelect_RetError; }
return pilot->RecordItem(sel);
}
Handle(IFSelect_WorkSession) WS = pilot->Session();
// **** SignCounter ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Donner nom signature"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner nom signature"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_Signature,sign,WS->NamedItem(arg1));
- if (sign.IsNull()) { sout<<arg1<<":pas une signature"<<std::endl; return IFSelect_RetError; }
+ if (sign.IsNull()) { sout<<arg1<<":pas une signature"<<'\n'; return IFSelect_RetError; }
Handle(IFSelect_SignCounter) cnt = new IFSelect_SignCounter (sign,Standard_True,Standard_True);
return pilot->RecordItem(cnt);
}
Handle(IFSelect_WorkSession) WS = pilot->Session();
// **** NbSelected = GraphCounter ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Donner nom selection (deduction) a appliquer"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner nom selection (deduction) a appliquer"<<'\n'; return IFSelect_RetError; }
DeclareAndCast(IFSelect_SelectDeduct,applied,WS->GiveSelection(arg1));
- if (applied.IsNull()) { sout<<arg1<<":pas une SelectDeduct"<<std::endl; return IFSelect_RetError; }
+ if (applied.IsNull()) { sout<<arg1<<":pas une SelectDeduct"<<'\n'; return IFSelect_RetError; }
Handle(IFSelect_GraphCounter) cnt = new IFSelect_GraphCounter (Standard_True,Standard_True);
cnt->SetApplied (applied);
return pilot->RecordItem(cnt);
{
Standard_Integer argc = pilot->NbWords();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Give the name of an EditForm or an Editor"<<std::endl;
+ if (argc < 2) { sout<<"Give the name of an EditForm or an Editor"<<'\n';
return IFSelect_RetError; }
const Standard_CString arg1 = pilot->Arg(1);
const Standard_CString arg2 = pilot->Arg(2);
DeclareAndCast(IFSelect_EditForm,edf,WS->NamedItem(arg1));
Handle(IFSelect_Editor) edt;
if (!edf.IsNull()) {
- sout<<"Print EditForm "<<arg1<<std::endl;
+ sout<<"Print EditForm "<<arg1<<'\n';
edt = edf->Editor();
if (argc < 3) {
if (edt.IsNull()) edt = GetCasted(IFSelect_Editor,WS->NamedItem(arg1));
if (edt.IsNull()) return IFSelect_RetVoid;
- sout<<"Editor, Label : "<<edt->Label()<<std::endl;
- sout<<std::endl<<" -- Names (short - complete) + Labels of Values"<<std::endl;
+ sout<<"Editor, Label : "<<edt->Label()<<'\n';
+ sout<<'\n'<<" -- Names (short - complete) + Labels of Values"<<'\n';
edt->PrintNames(sout);
- sout<<std::endl<<" -- Definitions --"<<std::endl;
+ sout<<'\n'<<" -- Definitions --"<<'\n';
edt->PrintDefs (sout);
if (!edf.IsNull()) {
edf->PrintDefs(sout);
- sout<<std::endl<<"To display values, add an option : o original f final m modified"<<std::endl;
+ sout<<'\n'<<"To display values, add an option : o original f final m modified"<<'\n';
}
return IFSelect_RetVoid;
{
Standard_Integer argc = pilot->NbWords();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 3) { sout<<"Give the name of an EditForm + name of Value [+ newvalue or . to nullify]"<<std::endl;
+ if (argc < 3) { sout<<"Give the name of an EditForm + name of Value [+ newvalue or . to nullify]"<<'\n';
return IFSelect_RetError; }
const Standard_CString arg1 = pilot->Arg(1);
const Standard_CString arg2 = pilot->Arg(2);
Handle(IFSelect_WorkSession) WS = pilot->Session();
DeclareAndCast(IFSelect_EditForm,edf,WS->NamedItem(arg1));
if (edf.IsNull())
- { sout<<"Not an EditForm : "<<arg1<<std::endl; return IFSelect_RetError; }
+ { sout<<"Not an EditForm : "<<arg1<<'\n'; return IFSelect_RetError; }
Standard_Integer num = edf->NameNumber (arg2);
- if (num == 0) sout<<"Unknown Value Name : "<<arg2<<std::endl;
- if (num < 0) sout<<"Not Extracted Value Name : "<<arg2<<std::endl;
+ if (num == 0) sout<<"Unknown Value Name : "<<arg2<<'\n';
+ if (num < 0) sout<<"Not Extracted Value Name : "<<arg2<<'\n';
if (num <= 0) return IFSelect_RetError;
Standard_Boolean islist = edf->Editor()->IsList(num);
if (islist) {
listr = edf->EditedList(num);
- if (listr.IsNull()) sout<<"(NULL LIST)"<<std::endl;
+ if (listr.IsNull()) sout<<"(NULL LIST)"<<'\n';
else {
Standard_Integer ilist,nblist = listr->Length();
- sout<<"(List : "<<nblist<<" Items)"<<std::endl;
+ sout<<"(List : "<<nblist<<" Items)"<<'\n';
for (ilist = 1; ilist <= nblist; ilist ++) {
str = listr->Value(ilist);
- sout<<" ["<<ilist<<"] "<< (str.IsNull() ? "(NULL)" : str->ToCString())<<std::endl;
+ sout<<" ["<<ilist<<"] "<< (str.IsNull() ? "(NULL)" : str->ToCString())<<'\n';
}
}
- if (argc < 4) sout<<"To Edit, options by editval edit-form value-name ?"<<std::endl;
+ if (argc < 4) sout<<"To Edit, options by editval edit-form value-name ?"<<'\n';
} else {
str = edf->EditedValue (num);
- sout<<(str.IsNull() ? "(NULL)" : str->ToCString())<<std::endl;
+ sout<<(str.IsNull() ? "(NULL)" : str->ToCString())<<'\n';
}
if (argc < 4) return IFSelect_RetVoid;
const Standard_CString argval = pilot->Arg(numarg);
if (islist) {
if (argval[0] == '?') {
- sout<<"To Edit, options"<<std::endl<<" + val : add value at end (blanks allowed)"
- <<std::endl<<" +nn text : insert val before item nn"<<std::endl
- <<" nn text : replace item nn with a new value"<<std::endl
- <<" -nn : remove item nn"<<std::endl<<" . : clear the list"<<std::endl;
+ sout<<"To Edit, options"<<'\n'<<" + val : add value at end (blanks allowed)"
+ <<'\n'<<" +nn text : insert val before item nn"<<'\n'
+ <<" nn text : replace item nn with a new value"<<'\n'
+ <<" -nn : remove item nn"<<'\n'<<" . : clear the list"<<'\n';
return IFSelect_RetVoid;
}
Standard_Boolean stated = Standard_False;
(new TCollection_HAsciiString(pilot->CommandPart(numarg+1)),numset);
}
if (stated) stated = edf->ModifyList (num,listed,Standard_True);
- if (stated) sout<<"List Edition done"<<std::endl;
- else sout<<"List Edition not done, option"<<argval<<std::endl;
+ if (stated) sout<<"List Edition done"<<'\n';
+ else sout<<"List Edition not done, option"<<argval<<'\n';
} else {
if (argval[0] == '.' && argval[1] == '\0') str.Nullify();
else str = new TCollection_HAsciiString (pilot->CommandPart(numarg));
if (edf->Modify (num,str,Standard_True)) {
- sout<<"Now set to "<<(str.IsNull() ? "(NULL)" : str->ToCString())<<std::endl;
+ sout<<"Now set to "<<(str.IsNull() ? "(NULL)" : str->ToCString())<<'\n';
} else {
- sout<<"Modify not done"<<std::endl; return IFSelect_RetFail;
+ sout<<"Modify not done"<<'\n'; return IFSelect_RetFail;
}
}
return IFSelect_RetDone;
{
Standard_Integer argc = pilot->NbWords();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Give the name of an EditForm [+ name of Value else all]"<<std::endl;
+ if (argc < 2) { sout<<"Give the name of an EditForm [+ name of Value else all]"<<'\n';
return IFSelect_RetError; }
const Standard_CString arg1 = pilot->Arg(1);
const Standard_CString arg2 = pilot->Arg(2);
Handle(IFSelect_WorkSession) WS = pilot->Session();
DeclareAndCast(IFSelect_EditForm,edf,WS->NamedItem(arg1));
if (edf.IsNull())
- { sout<<"Not an EditForm : "<<arg1<<std::endl; return IFSelect_RetError; }
- if (argc < 3) { edf->ClearEdit(); sout<<"All Modifications Cleared"<<std::endl; }
+ { sout<<"Not an EditForm : "<<arg1<<'\n'; return IFSelect_RetError; }
+ if (argc < 3) { edf->ClearEdit(); sout<<"All Modifications Cleared"<<'\n'; }
else {
Standard_Integer num = edf->NameNumber (arg2);
- if (num == 0) sout<<"Unknown Value Name : "<<arg2<<std::endl;
- if (num < 0) sout<<"Not Extracted Value Name : "<<arg2<<std::endl;
+ if (num == 0) sout<<"Unknown Value Name : "<<arg2<<'\n';
+ if (num < 0) sout<<"Not Extracted Value Name : "<<arg2<<'\n';
if (num <= 0) return IFSelect_RetError;
if (!edf->IsModified(num))
- { sout<<"Value "<<arg2<<" was not modified"<<std::endl; return IFSelect_RetVoid; }
+ { sout<<"Value "<<arg2<<" was not modified"<<'\n'; return IFSelect_RetVoid; }
edf->ClearEdit (num);
- sout<<"Modification on Value "<<arg2<<" Cleared"<<std::endl;
+ sout<<"Modification on Value "<<arg2<<" Cleared"<<'\n';
}
return IFSelect_RetDone;
}
{
Standard_Integer argc = pilot->NbWords();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Give the name of an EditForm [+ option keep to re-apply edited values]"<<std::endl;
+ if (argc < 2) { sout<<"Give the name of an EditForm [+ option keep to re-apply edited values]"<<'\n';
return IFSelect_RetError; }
const Standard_CString arg1 = pilot->Arg(1);
const Standard_CString arg2 = pilot->Arg(2);
Handle(IFSelect_WorkSession) WS = pilot->Session();
DeclareAndCast(IFSelect_EditForm,edf,WS->NamedItem(arg1));
if (edf.IsNull())
- { sout<<"Not an EditForm : "<<arg1<<std::endl; return IFSelect_RetError; }
+ { sout<<"Not an EditForm : "<<arg1<<'\n'; return IFSelect_RetError; }
Handle(Standard_Transient) ent = edf->Entity();
Handle(Interface_InterfaceModel) model = edf->Model();
if (!model.IsNull()) {
- if (ent.IsNull()) sout<<"Applying modifications on loaded model"<<std::endl;
+ if (ent.IsNull()) sout<<"Applying modifications on loaded model"<<'\n';
else {
sout<<"Applying modifications on loaded entity : ";
model->PrintLabel (ent, sout);
}
}
- else sout<<"Applying modifications"<<std::endl;
+ else sout<<"Applying modifications"<<'\n';
if (!edf->ApplyData (edf->Entity(),edf->Model())) {
- sout<<"Modifications could not be applied"<<std::endl;
+ sout<<"Modifications could not be applied"<<'\n';
return IFSelect_RetFail;
}
- sout<<"Modifications have been applied"<<std::endl;
+ sout<<"Modifications have been applied"<<'\n';
Standard_Boolean stat = Standard_True;
if (argc > 2 && arg2[0] == 'k') stat = Standard_False;
if (stat) {
edf->ClearEdit();
- sout<<"Edited values are cleared"<<std::endl;
+ sout<<"Edited values are cleared"<<'\n';
}
- else sout<<"Edited values are kept for another loading/applying"<<std::endl;
+ else sout<<"Edited values are kept for another loading/applying"<<'\n';
return IFSelect_RetDone;
}
{
Standard_Integer argc = pilot->NbWords();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Give the name of an EditForm [+ Entity-Ident]"<<std::endl;
+ if (argc < 2) { sout<<"Give the name of an EditForm [+ Entity-Ident]"<<'\n';
return IFSelect_RetError; }
const Standard_CString arg1 = pilot->Arg(1);
const Standard_CString arg2 = pilot->Arg(2);
Handle(IFSelect_WorkSession) WS = pilot->Session();
DeclareAndCast(IFSelect_EditForm,edf,WS->NamedItem(arg1));
if (edf.IsNull())
- { sout<<"Not an EditForm : "<<arg1<<std::endl; return IFSelect_RetError; }
+ { sout<<"Not an EditForm : "<<arg1<<'\n'; return IFSelect_RetError; }
Standard_Integer num = (argc < 3 ? 0 : pilot->Number (arg2));
Standard_Boolean stat = Standard_False;
if (argc < 3) {
- sout<<"EditForm "<<arg1<<" : Loading Model"<<std::endl;
+ sout<<"EditForm "<<arg1<<" : Loading Model"<<'\n';
stat = edf->LoadModel(WS->Model());
} else if (num <= 0) {
- sout<<"Not an entity ident : "<<arg2<<std::endl;
+ sout<<"Not an entity ident : "<<arg2<<'\n';
return IFSelect_RetError;
} else {
- sout<<"EditForm "<<arg1<<" : Loading Entity "<<arg2<<std::endl;
+ sout<<"EditForm "<<arg1<<" : Loading Entity "<<arg2<<'\n';
stat = edf->LoadData (WS->StartingEntity(num),WS->Model());
}
if (!stat) {
- sout<<"Loading not done"<<std::endl;
+ sout<<"Loading not done"<<'\n';
return IFSelect_RetFail;
}
- sout<<"Loading done"<<std::endl;
+ sout<<"Loading done"<<'\n';
return IFSelect_RetDone;
}
if (!dc.IsNull()) {
Standard_Integer nb = atoi( &(nam.ToCString())[paro]);
if (nb <= 0) {
- sout<<" DispPerCount, count is not positive"<<std::endl;
+ sout<<" DispPerCount, count is not positive"<<'\n';
disp.Nullify();
return disp;
}
if (!dp.IsNull()) {
Standard_Integer nb = atoi( &(nam.ToCString())[paro]);
if (nb <= 0) {
- sout<<" DispPerFiles, count is not positive"<<std::endl;
+ sout<<" DispPerFiles, count is not positive"<<'\n';
disp.Nullify();
return disp;
}
if (!ds.IsNull()) {
DeclareAndCast(IFSelect_Signature,sg,WS->NamedItem( &(nam.ToCString())[paro]));
if (sg.IsNull()) {
- sout<<"DispPerSignature "<<nam<<" , Signature not valid : "<<&(nam.ToCString())[paro]<<std::endl;
+ sout<<"DispPerSignature "<<nam<<" , Signature not valid : "<<&(nam.ToCString())[paro]<<'\n';
disp.Nullify();
return disp;
}
if (mode) ds->SetSignCounter (new IFSelect_SignCounter(sg));
return ds;
}
- sout<<"Dispatch : "<<name<<" , Parameter : "<<&(nam.ToCString())[paro]<<std::endl;
+ sout<<"Dispatch : "<<name<<" , Parameter : "<<&(nam.ToCString())[paro]<<'\n';
return disp;
}
const Handle(Interface_Protocol)& protocol,
Interface_CopyTool& TC)
{
- Message::SendInfo() << "** WorkSession : Copying split data before sending"<<std::endl;
+ Message::SendInfo() << "** WorkSession : Copying split data before sending"<<'\n';
const Interface_Graph& G = eval.Graph();
Interface_CheckIterator checks;
theshareout = eval.ShareOut();
(const Handle(IFSelect_WorkLibrary)& WL,
const Handle(Interface_Protocol)& protocol)
{
- Message::SendInfo() << "** WorkSession : Sending split data already copied"<<std::endl;
+ Message::SendInfo() << "** WorkSession : Sending split data already copied"<<'\n';
Standard_Integer nb = NbFiles();
Interface_CheckIterator checks;
if (nb > 0) {
if (!res) {
char mess[100]; sprintf(mess,"Split Send (WriteFile) abandon on file n0.%d",i);
checks.CCheck(0)->AddFail (mess);
- Message::SendInfo() << " ** Sending File n0."<<i<<" has failed, abandon **"<<std::endl;
+ Message::SendInfo() << " ** Sending File n0."<<i<<" has failed, abandon **"<<'\n';
return checks;
}
AddSentFile (FileName(i).ToCString());
const Interface_Graph& G = eval.Graph();
Interface_CheckIterator checks;
Standard_Integer i = 0;
- Message::SendInfo() << "** WorkSession : Copying then sending split data"<<std::endl;
+ Message::SendInfo() << "** WorkSession : Copying then sending split data"<<'\n';
theshareout = eval.ShareOut();
theremain = new TColStd_HArray1OfInteger(0,G.Size()); theremain->Init(0);
for (eval.Evaluate(); eval.More(); eval.Next()) {
if (!res) {
char mess[100]; sprintf(mess,"Split Send (WriteFile) abandon on file n0.%d",i);
checks.CCheck(0)->AddFail (mess);
- Message::SendInfo() << " ** Sending File "<<filename<<" has failed, abandon **"<<std::endl;
+ Message::SendInfo() << " ** Sending File "<<filename<<" has failed, abandon **"<<'\n';
checks.SetName ("X-STEP WorkSession : Split Send (only Write)");
return checks;
}
{
Interface_CheckIterator checks;
checks.SetName ("X-STEP WorkSession : Send All");
- Message::SendInfo() << "** WorkSession : Sending all data"<<std::endl;
+ Message::SendInfo() << "** WorkSession : Sending all data"<<'\n';
const Handle(Interface_InterfaceModel)& model = G.Model();
if (model.IsNull() || protocol.IsNull() || WL.IsNull()) return checks;
{
Interface_CheckIterator checks;
checks.SetName ("X-STEP WorkSession : Send Selected");
- Message::SendInfo() << "** WorkSession : Sending selected data"<<std::endl;
+ Message::SendInfo() << "** WorkSession : Sending selected data"<<'\n';
const Handle(Interface_InterfaceModel)& original = G.Model();
if (original.IsNull() || protocol.IsNull() || WL.IsNull()) return checks;
Handle(Interface_InterfaceModel) newmod = original->NewEmptyModel();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
SplitLine (headerline);
- if (theline.Length() != 4) { sout<<"File Form Incorrect"<<std::endl; return Standard_False; }
+ if (theline.Length() != 4) { sout<<"File Form Incorrect"<<'\n'; return Standard_False; }
Handle(Standard_Type) sesstype = thesess->DynamicType();
if (!theline.Value(1).IsEqual("!XSTEP") ||
!theline.Value(2).IsEqual("SESSION") ||
!theline.Value(4).IsEqual(sesstype->Name()) )
- { sout<<"Lineno."<<thenl<<" : File Header Description Incorrect"<<std::endl; return Standard_False; }
+ { sout<<"Lineno."<<thenl<<" : File Header Description Incorrect"<<'\n'; return Standard_False; }
// Value(3) definit la VERSION du format de fichier
return Standard_True;
}
thenames.Clear();
// .. Donnees generales, controle
if (!ReadLine()) return 1;
- if (theline.Length() != 4) { sout<<"File Form Incorrect"<<std::endl; return 1; }
+ if (theline.Length() != 4) { sout<<"File Form Incorrect"<<'\n'; return 1; }
Handle(Standard_Type) sesstype = thesess->DynamicType();
if (!theline.Value(1).IsEqual("!XSTEP") ||
!theline.Value(2).IsEqual("SESSION") ||
!theline.Value(4).IsEqual(sesstype->Name()) )
- { sout<<"Lineno."<<thenl<<" : File Header Description Incorrect"<<std::endl; return 1; }
+ { sout<<"Lineno."<<thenl<<" : File Header Description Incorrect"<<'\n'; return 1; }
// Value(3) definit la VERSION du format de fichier
if (!ReadLine()) return 1;
if (ungen.Value(1) == '!') break; // fin des generaux
if (ungen.IsEqual("ErrorHandle")) {
if (theline.Length() != 2)
- { sout<<"Lineno."<<thenl<<" : ErrorHandle Description Incorrect"<<std::endl; continue; }
+ { sout<<"Lineno."<<thenl<<" : ErrorHandle Description Incorrect"<<'\n'; continue; }
if (theline.Value(2).IsEqual("0"))
thesess->SetErrorHandle(Standard_False);
else if (theline.Value(2).IsEqual("1"))
thesess->SetErrorHandle(Standard_True);
- else { sout<<"Lineno."<<thenl<<" : ErrorHandle Incorrect : "<<theline.Value(2)<<std::endl; continue; }
+ else { sout<<"Lineno."<<thenl<<" : ErrorHandle Incorrect : "<<theline.Value(2)<<'\n'; continue; }
continue;
}
- else sout<<"Lineno."<<thenl<<" : Unknown General Parameter : "<<ungen<<" , ignored"<<std::endl;
+ else sout<<"Lineno."<<thenl<<" : Unknown General Parameter : "<<ungen<<" , ignored"<<'\n';
}
// .. IntParams
if (!ReadLine()) return 1;
if (theline.Value(1).Value(1) == '!') break; // liste suivante
if (theline.Length() != 2)
- { sout<<"Lineno."<<thenl<<" : An Integer Parameter is badly defined"<<std::endl; continue; }
+ { sout<<"Lineno."<<thenl<<" : An Integer Parameter is badly defined"<<'\n'; continue; }
Handle(IFSelect_IntParam) par = new IFSelect_IntParam;
par->SetValue ( atoi(theline.Value(2).ToCString()) );
AddItem (par);
if (!ReadLine()) return 1;
if (theline.Value(1).Value(1) == '!') break; // liste suivante
if (theline.Length() != 2)
- { sout<<"Lineno."<<thenl<<" : A Text Parameter is badly defined"<<std::endl; continue; }
+ { sout<<"Lineno."<<thenl<<" : A Text Parameter is badly defined"<<'\n'; continue; }
// Attention, un texte peut contenir des blancs ... repartir de line(thenl)
TCollection_AsciiString oneline = thelist.Value(thenl);
Standard_Integer iw = 0, inc = 0;
if (!ReadLine()) return 1;
if (theline.Value(1).Value(1) == '!') break; // liste suivante
if (theline.Length() < 2)
- { sout<<"Lineno."<<thenl<<" : A Selection is badly defined"<<std::endl; continue; }
+ { sout<<"Lineno."<<thenl<<" : A Selection is badly defined"<<'\n'; continue; }
// .. Analyse de certains cas generaux
Handle(IFSelect_IntParam) low,up;
Standard_Integer firstown = 3;
if (item.IsNull()) continue;
DeclareAndCast(IFSelect_SelectExtract,sxt,item);
if (!sxt.IsNull()) {
- if (direct == 0) sout<<"Lineno."<<thenl<<" : A SelectExtract is badly defined"<<std::endl;
+ if (direct == 0) sout<<"Lineno."<<thenl<<" : A SelectExtract is badly defined"<<'\n';
else sxt->SetDirect( (direct > 0) );
}
DeclareAndCast(IFSelect_SelectAnyList,sli,item);
if (!sli.IsNull()) {
- if (numlist == 0) sout<<"Lineno."<<thenl<<" : A SelectAnyList is badly defined"<<std::endl;
+ if (numlist == 0) sout<<"Lineno."<<thenl<<" : A SelectAnyList is badly defined"<<'\n';
else sli->SetRange(low,up);
}
AddItem(item);
if (!ReadLine()) return 1;
if (theline.Value(1).Value(1) == '!') break; // liste suivante
if (theline.Length() < 3)
- { sout<<"Lineno."<<thenl<<" : A Selection Source List is badly defined"<<std::endl; continue; }
+ { sout<<"Lineno."<<thenl<<" : A Selection Source List is badly defined"<<'\n'; continue; }
DeclareAndCast(IFSelect_Selection,sel,ItemValue(1));
if (sel.IsNull())
- { sout<<"Lineno."<<thenl<<" : A Source List is not for a Selection"<<std::endl; continue; }
+ { sout<<"Lineno."<<thenl<<" : A Source List is not for a Selection"<<'\n'; continue; }
Standard_Integer nbs = atoi(theline.Value(2).ToCString());
// .. Differents cas reconnus
DeclareAndCast(IFSelect_SelectExtract,sxt,sel);
if (!sxt.IsNull()) {
if (nbs > 1)
- sout<<"Lineno."<<thenl<<" : SelectExtract, more than one source, following ignored"<<std::endl;
+ sout<<"Lineno."<<thenl<<" : SelectExtract, more than one source, following ignored"<<'\n';
DeclareAndCast(IFSelect_Selection,source,ItemValue(3));
sxt->SetInput(source);
}
DeclareAndCast(IFSelect_SelectDeduct,sdt,sel);
if (!sdt.IsNull()) {
if (nbs > 1)
- sout<<"Lineno."<<thenl<<" : SelectDeduct, more than one source, following ignored"<<std::endl;
+ sout<<"Lineno."<<thenl<<" : SelectDeduct, more than one source, following ignored"<<'\n';
sdt->SetInput(GetCasted(IFSelect_Selection,ItemValue(3)));
}
DeclareAndCast(IFSelect_SelectControl,sct,sel);
if (!sct.IsNull()) {
if (nbs != 2)
- sout<<"Lineno."<<thenl<<" : SelectControl, not two sources, following ignored"<<std::endl;
+ sout<<"Lineno."<<thenl<<" : SelectControl, not two sources, following ignored"<<'\n';
sct->SetMainInput (GetCasted(IFSelect_Selection,ItemValue(3)));
sct->SetSecondInput (GetCasted(IFSelect_Selection,ItemValue(4)));
}
if (!ReadLine()) return 1;
if (theline.Value(1).Value(1) == '!') break; // liste suivante
if (theline.Length() < 2)
- { sout<<"Lineno."<<thenl<<" : A Modifier is badly defined"<<std::endl; continue; }
+ { sout<<"Lineno."<<thenl<<" : A Modifier is badly defined"<<'\n'; continue; }
Handle(Standard_Transient) item; // a fournir ...
ReadOwn(item);
if (item.IsNull()) continue;
DeclareAndCast(IFSelect_GeneralModifier,modif,item);
if (modif.IsNull())
- { sout<<"Lineno."<<thenl<<" : A Modifier has not been Recognized"<<std::endl; continue; }
+ { sout<<"Lineno."<<thenl<<" : A Modifier has not been Recognized"<<'\n'; continue; }
AddItem(modif,Standard_False); // active plus tard
}
if (!ReadLine()) return 1;
if (theline.Value(1).Value(1) == '!') break; // liste suivante
if (theline.Length() < 2)
- { sout<<"Lineno."<<thenl<<" : A Transformer is badly defined"<<std::endl; continue; }
+ { sout<<"Lineno."<<thenl<<" : A Transformer is badly defined"<<'\n'; continue; }
Handle(Standard_Transient) item; // a fournir ...
ReadOwn(item);
if (item.IsNull()) continue;
DeclareAndCast(IFSelect_Transformer,trf,item);
if (trf.IsNull())
- { sout<<"Lineno."<<thenl<<" : A Transformer has not been Recognized"<<std::endl; continue; }
+ { sout<<"Lineno."<<thenl<<" : A Transformer has not been Recognized"<<'\n'; continue; }
AddItem(trf,Standard_False); // active plus tard
}
if (!ReadLine()) return 1;
if (theline.Value(1).Value(1) == '!') break; // liste suivante
if (theline.Length() < 3)
- { sout<<"Lineno."<<thenl<<" : A Dispatch is badly defined"<<std::endl; continue; }
+ { sout<<"Lineno."<<thenl<<" : A Dispatch is badly defined"<<'\n'; continue; }
DeclareAndCast(IFSelect_Selection,input,ItemValue(3));
SetLastGeneral(3);
Handle(Standard_Transient) item; // a fournir ...
if (item.IsNull()) continue;
DeclareAndCast(IFSelect_Dispatch,disp,item);
if (disp.IsNull())
- { sout<<"Lineno."<<thenl<<" : A Dispatch has not been Recognized"<<std::endl; continue; }
+ { sout<<"Lineno."<<thenl<<" : A Dispatch has not been Recognized"<<'\n'; continue; }
AddItem(disp);
thesess->SetItemSelection(disp,input);
}
if (!ReadLine()) return 1;
if (theline.Value(1).Value(1) == '!') break; // liste suivante
if (theline.Length() != 2)
- { sout<<"Lineno."<<thenl<<" : A File Root is badly defined"<<std::endl; continue; }
+ { sout<<"Lineno."<<thenl<<" : A File Root is badly defined"<<'\n'; continue; }
DeclareAndCast(IFSelect_Dispatch,disp,ItemValue(1));
thesess->SetFileRoot (disp,theline.Value(2).ToCString());
}
if (!ReadLine()) return 1;
if (theline.Value(1).Value(1) == '!') break; // liste suivante
if (theline.Length() < 3)
- { sout<<"Lineno."<<thenl<<" : A General Modifier is badly defined"<<std::endl; continue; }
+ { sout<<"Lineno."<<thenl<<" : A General Modifier is badly defined"<<'\n'; continue; }
DeclareAndCast(IFSelect_GeneralModifier,modif,ItemValue(1));
DeclareAndCast(IFSelect_Selection,input,ItemValue(2));
DeclareAndCast(IFSelect_Dispatch,disp,ItemValue(3));
if (modif.IsNull())
- { sout<<"Lineno."<<thenl<<" : A General Modifier has not been Recognized"<<std::endl; continue; }
+ { sout<<"Lineno."<<thenl<<" : A General Modifier has not been Recognized"<<'\n'; continue; }
thesess->SetItemSelection (modif,input);
if (!disp.IsNull()) thesess->SetAppliedModifier (modif,disp);
else thesess->SetAppliedModifier (modif,thesess->ShareOut());
if ( theline.Length() != 2 ||
!theline.Value(1).IsEqual("!XSTEP") ||
!theline.Value(2).IsEqual("END"))
- { sout<<"End of File Incorrect, lineno"<<thenl<<std::endl; return 1; }
+ { sout<<"End of File Incorrect, lineno"<<thenl<<'\n'; return 1; }
return 0;
}
if (dumper->ReadOwn(*this,type,item)) break;
dumper = dumper->Next();
}
- if (dumper.IsNull()) sout<<" -- Lineno."<<thenl<<" : an Item could not be read"<<std::endl;
+ if (dumper.IsNull()) sout<<" -- Lineno."<<thenl<<" : an Item could not be read"<<'\n';
return (!dumper.IsNull()); // IsNull -> echec
}
else id = thesess->AddNamedItem(name.ToCString(),item,active);
}
else sout<<"Lineno."<<thenl<<" -- Name : "<<name
- <<" : Item could not be defined" << std::endl;
+ <<" : Item could not be defined" << '\n';
thenames.Bind(name,id);
}
if (id != 0) filenum = thenums->Value(id);
if (filenum == 0) {
if (!par.IsNull()) sout << "Lineno " << thenl << " -- Unknown Item : "
- << " Type:" << par->DynamicType()->Name() << std::endl; //sout<<Handle par
+ << " Type:" << par->DynamicType()->Name() << '\n'; //sout<<Handle par
SendVoid();
thedone = Standard_False;
return;
if (name.IsEqual("$")) return res; // item non-defini justement
if (!thenames.Find(name, id)) {
sout << " -- Item Unknown in File : " << name
- << " lineno " << thenl << " param." << nm << std::endl;
+ << " lineno " << thenl << " param." << nm << '\n';
id = 0;
}
return thesess->Item(id);
(const TCollection_AsciiString& command)
{
Standard_Integer lc = command.Length();
- if (lc > 200) std::cout<<" Commande TRES LONGUE : "<<lc<<" caracteres :"<<std::endl
- <<command.ToCString()<<std::endl;
+ if (lc > 200) std::cout<<" Commande TRES LONGUE : "<<lc<<" caracteres :"<<'\n'
+ <<command.ToCString()<<'\n';
thecommand = command;
if (thecommand.Value(lc) <= ' ') { thecommand.Remove(lc); lc --; }
thenbwords = 0;
continue;
}
if (nc == 0) thewordeb.SetValue (thenbwords,i);
- if (nc > MAXCARS) { std::cout<<"Arg."<<thenbwords<<" > "<<MAXCARS<<" car.s, tronque"<<std::endl; continue; }
+ if (nc > MAXCARS) { std::cout<<"Arg."<<thenbwords<<" > "<<MAXCARS<<" car.s, tronque"<<'\n'; continue; }
unarg[nc] = val; nc ++;
}
if (nc > 0) {
if (file != NULL && file[0] != '\0') {
fic = OSD_OpenFile (file,"r");
if (fic) lefic = 1;
- else { std::cout<<" ... Script File "<<file<<" not found"<<std::endl; return IFSelect_RetFail; }
- std::cout << " ... Reading Script File " << file << std::endl;
+ else { std::cout<<" ... Script File "<<file<<" not found"<<'\n'; return IFSelect_RetFail; }
+ std::cout << " ... Reading Script File " << file << '\n';
}
else fic = stdin;
IFSelect_ReturnStatus stat = IFSelect_RetVoid;
stat = Execute(command);
if (stat == IFSelect_RetStop) break;
if ((stat == IFSelect_RetError || stat == IFSelect_RetFail) && lefic)
- { std::cout << " ... Error in Script File, abandon"<<std::endl; break; }
+ { std::cout << " ... Error in Script File, abandon"<<'\n'; break; }
}
if (!lefic) return IFSelect_RetStop;
fclose(fic);
- std::cout<<"End of Reading Script File " << file << std::endl;
+ std::cout<<"End of Reading Script File " << file << '\n';
if (stat == IFSelect_RetError || stat == IFSelect_RetFail) return stat;
return IFSelect_RetVoid; // fin fichier : depiler
}
if (!theobjrec.IsNull()) {
thesession->RemoveItem(theobjrec); //// depannage ?
Standard_Integer addws = thesession->AddItem(theobjrec);
- if (addws == 0) { std::cout<<"Could not add item to session, sorry"<<std::endl; return IFSelect_RetFail; }
+ if (addws == 0) { std::cout<<"Could not add item to session, sorry"<<'\n'; return IFSelect_RetFail; }
}
if (stat == IFSelect_RetVoid || stat == IFSelect_RetDone) {
if (therecord) thecomlist.Append(thecommand);
}
- else if (stat == IFSelect_RetError) std::cout<<"Error in Command : "<<thecommand<<std::endl;
- else if (stat == IFSelect_RetFail) std::cout << "Execution Failure for : " <<thecommand<<std::endl;
+ else if (stat == IFSelect_RetError) std::cout<<"Error in Command : "<<thecommand<<'\n';
+ else if (stat == IFSelect_RetFail) std::cout << "Execution Failure for : " <<thecommand<<'\n';
return stat;
}
- std::cout << " Command : " << thewords(0) << " unknown" << std::endl;
+ std::cout << " Command : " << thewords(0) << " unknown" << '\n';
return IFSelect_RetError; // pas reconnu donc incorrect
}
// on demande un givelist
Handle(TColStd_HSequenceOfTransient) list = thesession->GiveList (CommandPart(numword));
if (list.IsNull()) {
- std::cout<<"Nothing selected from : "<<CommandPart(numword)<<std::endl;
+ std::cout<<"Nothing selected from : "<<CommandPart(numword)<<'\n';
return IFSelect_RetError;
}
counter->AddWithGraph (list,thesession->Graph());
(const Standard_CString val) const
{
Standard_Integer num = thesession->NumberFromLabel (val);
- if (num < 0) std::cout<<" Label:"<<val<<" ->"<<-num<<" ent.s, refus"<<std::endl;
+ if (num < 0) std::cout<<" Label:"<<val<<" ->"<<-num<<" ent.s, refus"<<'\n';
return num;
}
switch (number) {
case -1 : // **** HELP-XSNEW
modhelp = 1;
- std::cout<<" -- Commands candidate for xsnew --"<<std::endl;
+ std::cout<<" -- Commands candidate for xsnew --"<<'\n';
// HELP : soit complet (par defaut) soit limite a xsnew
Standard_FALLTHROUGH
case 0 : { // **** HELP
list = IFSelect_Activator::Commands(modhelp);
Standard_Integer nbcom = 0;
Standard_Integer nb = list->Length();
- std::cout << " -- Liste des Commands Disponibles --"<<std::endl;
+ std::cout << " -- Liste des Commands Disponibles --"<<'\n';
for (Standard_Integer i = 1; i <= nb; i ++) {
const TCollection_AsciiString& uncom = list->Value(i);
Standard_Integer loncom = uncom.Length();
nbcom ++;
- if (nbcom > MAXCOMPERLINE) { std::cout<<std::endl; nbcom = 1; }
+ if (nbcom > MAXCOMPERLINE) { std::cout<<'\n'; nbcom = 1; }
std::cout<<" "<<uncom;
if (nbcom == MAXCOMPERLINE) continue;
for (Standard_Integer j = loncom; j < LENGTHFORCOM; j ++) std::cout<<" ";
}
- if (nbcom > 0) std::cout<<std::endl;
+ if (nbcom > 0) std::cout<<'\n';
std::cout<<"\nhelp * liste toutes les commandes avec un help sur chacune\n"
<<"help <com> liste la ou les commande debutant par <com>"
- <<" avec un help sur chacune"<<std::endl;
+ <<" avec un help sur chacune"<<'\n';
// Un Help particulier
} else {
(list->Value(i).ToCString(),num,actor)) {
if (IFSelect_Activator::Mode (list->Value(i).ToCString()) == 1)
std::cout<<"[xsnew name] ";
- std::cout << list->Value(i) << " : " << actor->Help(num) << std::endl;
+ std::cout << list->Value(i) << " : " << actor->Help(num) << '\n';
}
}
if (nb == 0 && thenbwords > 1) std::cout<<" Command "<<Word(1)<<" unknown. "
- << " help (without command) lists all the commands" << std::endl;
+ << " help (without command) lists all the commands" << '\n';
}
return IFSelect_RetVoid;
}
if (argc < 2) { std::cout << "Donner une option :\n"
<<"a : analyse une ligne r : toggle record mode\n"
<<"l : list recorded c : clear f nom : sauver dans fichier de nom"
- << std::endl; return IFSelect_RetVoid; }
+ << '\n'; return IFSelect_RetVoid; }
switch (arg1[0]) {
case 'a' : { // **** command analyse
- std::cout<<"Command n0 " << number <<" : "<< session->CommandLine()<<std::endl;
+ std::cout<<"Command n0 " << number <<" : "<< session->CommandLine()<<'\n';
std::cout<<"Nb Words : " << argc-2 << " :\n";
for (Standard_Integer i = 2; i < argc; i ++) {
- std::cout << " Word." << i-1 << " : " << session->Word(i) <<std::endl;
+ std::cout << " Word." << i-1 << " : " << session->Word(i) <<'\n';
}
break;
}
case 'c' : session->Clear(); break; // **** command clear
case 'f' : {
- if (argc < 3) { std::cout<<"Donner nom de fichier"<<std::endl; return IFSelect_RetError; }
+ if (argc < 3) { std::cout<<"Donner nom de fichier"<<'\n'; return IFSelect_RetError; }
Standard_Integer nb = session->NbCommands();
- if (nb == 0) { std::cout<<"Aucune commande enregistree"<<std::endl; break; }
- std::cout << "Nb Commandes enregistrees : " << nb <<std::endl;
+ if (nb == 0) { std::cout<<"Aucune commande enregistree"<<'\n'; break; }
+ std::cout << "Nb Commandes enregistrees : " << nb <<'\n';
std::ofstream fout(Word(2).ToCString(),std::ios::out);
for (Standard_Integer i = 1; i <= nb; i ++)
- fout<<session->Command(i)<<std::endl;
+ fout<<session->Command(i)<<'\n';
break;
}
case 'l' : { // **** command list
- if (session->RecordMode()) std::cout<<" -- Record Mode Actif"<<std::endl;
- else std::cout<<" -- Record Mode Inactif"<<std::endl;
+ if (session->RecordMode()) std::cout<<" -- Record Mode Actif"<<'\n';
+ else std::cout<<" -- Record Mode Inactif"<<'\n';
Standard_Integer nb = session->NbCommands();
- std::cout << "Nb Commandes enregistrees : " << nb << " :"<<std::endl;
+ std::cout << "Nb Commandes enregistrees : " << nb << " :"<<'\n';
for (Standard_Integer i = 1; i <= nb; i ++) {
- std::cout<<" "<<i<<" "<<session->Command(i)<<std::endl;
+ std::cout<<" "<<i<<" "<<session->Command(i)<<'\n';
}
break;
}
case 'r' : { // **** command record
Standard_Boolean mode = session->RecordMode();
- if (mode) std::cout << " -- Record Mode a present Inactif" <<std::endl;
- else std::cout << " -- Record Mode a present Actif" <<std::endl;
+ if (mode) std::cout << " -- Record Mode a present Inactif" <<'\n';
+ else std::cout << " -- Record Mode a present Actif" <<'\n';
session->SetRecordMode(!mode);
break;
}
- default : std::cout << "Option de controle de commande non comprise"<<std::endl;
+ default : std::cout << "Option de controle de commande non comprise"<<'\n';
}
return IFSelect_RetVoid;
}
case 4 : { // **** FILE
- if (argc < 2) { std::cout<<"Donner nom de fichier"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { std::cout<<"Donner nom de fichier"<<'\n'; return IFSelect_RetError; }
return session->ReadScript
(TCollection_AsciiString(session->Word(1)).ToCString());
// On recopie la string parce que Word(1) change tout le temps !
case 5 : { // **** XSTEP
if (argc < 2) {
- std::cout<<"xstep : prefixe neutre pour toute commande xstep-draw"<<std::endl
- <<"xstep command args equivaut a command args"<<std::endl;
+ std::cout<<"xstep : prefixe neutre pour toute commande xstep-draw"<<'\n'
+ <<"xstep command args equivaut a command args"<<'\n';
return Do(2,this);
} else {
RemoveWord(0);
}
case 6 : { // **** XSNEW(variable)
if (argc < 3) {
- std::cout<<"xsnew nomvar command [args] creates an item"<<std::endl
- <<" nomvar : name of item (must be a new name) in the session"<<std::endl;
+ std::cout<<"xsnew nomvar command [args] creates an item"<<'\n'
+ <<" nomvar : name of item (must be a new name) in the session"<<'\n';
return Do (-1,this);
} else {
theobjrec.Nullify();
TCollection_AsciiString name = Word(1);
// Le nom ne doit pas etre deja pris !
- if (thesession.IsNull()) { std::cout<<"Command with a Name and no Session defined !"<<std::endl; return IFSelect_RetFail; }
+ if (thesession.IsNull()) { std::cout<<"Command with a Name and no Session defined !"<<'\n'; return IFSelect_RetFail; }
////// if (thesession->NameIdent(thewords(0).ToCString()) > 0)
////// { std::cout<<"Command with name:"<<thewords(0)<<", already taken"<<std::endl; return IFSelect_RetFail; }
RemoveWord(0); RemoveWord(0);
Standard_Integer addws =
thesession->AddNamedItem(name.ToCString(),theobjrec);
theobjrec.Nullify();
- if (addws == 0) { std::cout<<"Could not add named item:"<<name<<", sorry"<<std::endl; return IFSelect_RetFail; }
+ if (addws == 0) { std::cout<<"Could not add named item:"<<name<<", sorry"<<'\n'; return IFSelect_RetFail; }
}
- else std::cout<<"Remark : xsnew with name:"<<name<<" and no result"<<std::endl;
+ else std::cout<<"Remark : xsnew with name:"<<name<<" and no result"<<'\n';
return stat;
}
- std::cout << " Command : " << thewords(0) << " unknown" << std::endl;
+ std::cout << " Command : " << thewords(0) << " unknown" << '\n';
return IFSelect_RetError; // pas reconnu donc incorrect
}
}
{
Standard_Integer nbtot = 0, nbsign = 0;
NCollection_IndexedDataMap<TCollection_AsciiString, Standard_Integer>::Iterator iter(thedicount);
- S << " Count "<<thename->ToCString()<<"\n ----- -----------"<<std::endl;
+ S << " Count "<<thename->ToCString()<<"\n ----- -----------"<<'\n';
for (; iter.More(); iter.Next()) {
Standard_Integer val = iter.Value();
- S << Interface_MSG::Blanks(val,6) << val <<" "<<iter.Key()<<std::endl;
+ S << Interface_MSG::Blanks(val,6) << val <<" "<<iter.Key()<<'\n';
nbtot += val;
nbsign ++;
}
- if (thenbnuls > 0) S << thename->ToCString()<< " Nul : " << thenbnuls <<std::endl;
- S << " Nb Total:"<<nbtot<<" for "<<nbsign<<" items"<<std::endl;
+ if (thenbnuls > 0) S << thename->ToCString()<< " Nul : " << thenbnuls <<'\n';
+ S << " Nb Total:"<<nbtot<<" for "<<nbsign<<" items"<<'\n';
}
void IFSelect_SignatureList::PrintList
if (mod == IFSelect_CountByItem) { PrintCount (S); return; }
if (mod == IFSelect_CountSummary) { PrintSum (S); return; }
if (!HasEntities()) {
- S <<" SignatureList "<<Name()<<" : PrintList, list not available"<<std::endl;
+ S <<" SignatureList "<<Name()<<" : PrintList, list not available"<<'\n';
PrintCount(S);
return;
}
NCollection_IndexedDataMap<TCollection_AsciiString, Handle(Standard_Transient)>::Iterator iter(thediclist);
for (; iter.More(); iter.Next()) {
DeclareAndCast(TColStd_HSequenceOfTransient,list,iter.Value());
- S<<Name()<<" : "<<iter.Key()<<std::endl;
- if (list.IsNull()) { S<<" - (empty list)"<<std::endl; continue; }
+ S<<Name()<<" : "<<iter.Key()<<'\n';
+ if (list.IsNull()) { S<<" - (empty list)"<<'\n'; continue; }
Standard_Integer nb = list->Length();
S<<" - Nb: "<<nb<<" : ";
Standard_Integer nc = nb; if (nb > 5 && mod == IFSelect_ShortByItem) nc = 5;
{ S<<":"; model->PrintLabel(list->Value(i), S); }
}
if (nc < nb) S<<" .. etc";
- S<<std::endl;
+ S<<'\n';
nbtot += nb;
nbsign ++;
}
- S <<" Nb Total:"<<nbtot<<" for "<<nbsign<<" items"<<std::endl;
+ S <<" Nb Total:"<<nbtot<<" for "<<nbsign<<" items"<<'\n';
}
void IFSelect_SignatureList::PrintSum (Standard_OStream& S) const
{
NCollection_IndexedDataMap<TCollection_AsciiString, Standard_Integer>::Iterator iter(thedicount);
- S << " Summary "<<thename->ToCString()<<"\n ----- -----------"<<std::endl;
+ S << " Summary "<<thename->ToCString()<<"\n ----- -----------"<<'\n';
Standard_Integer nbtot = 0, nbsign = 0, maxent = 0, nbval = 0, nbve = 0, minval = 0, maxval = 0, totval = 0;
for (; iter.More(); iter.Next()) {
Standard_Integer nbent = iter.Value();
nbve += nbent;
totval += (val*nbent);
}
- S << " Nb Total:"<<nbtot<<" for "<<nbsign<<" items"<<std::endl;
- S << " Highest count of entities : "<<maxent<<" on one item"<<std::endl;
+ S << " Nb Total:"<<nbtot<<" for "<<nbsign<<" items"<<'\n';
+ S << " Highest count of entities : "<<maxent<<" on one item"<<'\n';
if (nbval > 0) {
- S<<" Summary on Integer Values"<<std::endl;
- S<<" Nb Integer Items : "<<nbval<<std::endl;
- S<<" For Nb Entities : "<<nbve<<std::endl;
- S<<" Cumulated Values : "<<totval<<std::endl;
- S <<" Maximum Value : "<<maxval<<std::endl;
+ S<<" Summary on Integer Values"<<'\n';
+ S<<" Nb Integer Items : "<<nbval<<'\n';
+ S<<" For Nb Entities : "<<nbve<<'\n';
+ S<<" Cumulated Values : "<<totval<<'\n';
+ S <<" Maximum Value : "<<maxval<<'\n';
Standard_Integer avg1, avg2;
avg1 = totval/nbve;
avg2 = ((totval - (avg1*nbve)) * 10) / nbve;
- S <<" Average Value : "<<avg1<<" "<<avg2<<"/10"<<std::endl;
- S <<" Minimum Value : "<<minval<<std::endl;
+ S <<" Average Value : "<<avg1<<" "<<avg2<<"/10"<<'\n';
+ S <<" Minimum Value : "<<minval<<'\n';
}
}
Interface_CheckIterator checklist = ctx.CheckList();
if (!checklist.IsEmpty(Standard_False)) {
checks.Merge(checklist);
- sout<<"IFSelect_TransformStandard : Messages from Modifier n0 "<<i<<" of "<<nb<<std::endl;
+ sout<<"IFSelect_TransformStandard : Messages from Modifier n0 "<<i<<" of "<<nb<<'\n';
checklist.Print(sout,newmod,Standard_False);
}
if (!checklist.IsEmpty(Standard_True)) {
- sout<<" -- Abandon TransformStandard --"<<std::endl;
+ sout<<" -- Abandon TransformStandard --"<<'\n';
res = Standard_False; break;
}
}
Message_Messenger::StreamBuffer sout = Message::SendInfo();
sout<<" **** Interruption ReadFile par Exception : ****\n";
sout << anException.GetMessageString();
- sout<<"\n Abandon"<<std::endl;
+ sout<<"\n Abandon"<<'\n';
status = IFSelect_RetFail;
}
if (status != IFSelect_RetDone) return status;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
sout << " **** Interruption ReadFile par Exception : ****\n";
sout << anException.GetMessageString();
- sout << "\n Abandon" << std::endl;
+ sout << "\n Abandon" << '\n';
status = IFSelect_RetFail;
}
if (status != IFSelect_RetDone) return status;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
sout<<" **** Interruption EvalSelection par Exception : ****\n";
sout<<anException.GetMessageString();
- sout<<"\n Abandon"<<std::endl;
+ sout<<"\n Abandon"<<'\n';
}
errhand = theerrhand;
return iter;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
sout<<" **** Interruption SelectionResult par Exception : ****\n";
sout<<anException.GetMessageString();
- sout<<"\n Abandon"<<std::endl;
+ sout<<"\n Abandon"<<'\n';
}
errhand = theerrhand;
return res;
}
if (!IsLoaded()) {
- std::cout<< " *** Data for Evaluation not available ***"<<std::endl;
+ std::cout<< " *** Data for Evaluation not available ***"<<'\n';
return new TColStd_HSequenceOfTransient();
}
// if (ItemIdent(sel) == 0)
if (sel.IsNull())
- { std::cout << " Selection : Unknown"<<std::endl; return res; } //std::cout<<Handle
+ { std::cout << " Selection : Unknown"<<'\n'; return res; } //std::cout<<Handle
return EvalSelection (sel).Content();
}
if (!checks.IsEmpty(Standard_False)) {
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- sout<<" ** RunTransformer has produced Check Messages : **"<<std::endl;
+ sout<<" ** RunTransformer has produced Check Messages : **"<<'\n';
checks.Print (sout,myModel,Standard_False);
}
thecheckdone = Standard_False;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
sout<<" **** Interruption EvaluateFile par Exception : ****\n";
sout<<anException.GetMessageString();
- sout<<"\n Abandon"<<std::endl;
+ sout<<"\n Abandon"<<'\n';
checks.CCheck(0)->AddFail ("Exception Raised -> Abandon");
}
errhand = theerrhand;
checks = thecopier->Copy (R,thelibrary,theprotocol);
if (!checks.IsEmpty(Standard_False)) {
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- sout<<" ** EvaluateFile has produced Check Messages : **"<<std::endl;
+ sout<<" ** EvaluateFile has produced Check Messages : **"<<'\n';
checks.Print (sout,myModel,Standard_False);
}
thecopier->SetRemaining (thegraph->CGraph());
Message_Messenger::StreamBuffer sout = Message::SendInfo();
sout<<" **** Interruption SendSplit par Exception : ****\n";
sout<<anException.GetMessageString();
- sout<<"\n Abandon"<<std::endl;
+ sout<<"\n Abandon"<<'\n';
checks.CCheck(0)->AddFail ("Exception Raised -> Abandon");
}
errhand = theerrhand;
}
if (!IsLoaded()) {
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- sout<< " *** Data for SendSplit not available ***"<<std::endl;
+ sout<< " *** Data for SendSplit not available ***"<<'\n';
checks.CCheck(0)->AddFail("Data not available");
thecheckrun = checks;
return Standard_False;
filepart = FileExtension();
if (!filepart.IsNull()) filnam.AssignCat (filepart->ToCString());
IFSelect_ReturnStatus stat = SendSelected (filnam.ToCString(),sp);
- if (stat != IFSelect_RetDone) std::cout<<"File "<<filnam<<" failed"<<std::endl;
+ if (stat != IFSelect_RetDone) std::cout<<"File "<<filnam<<" failed"<<'\n';
}
}
- sout<<" .. Files Written : "<<nf<<std::endl;
+ sout<<" .. Files Written : "<<nf<<'\n';
}
thecheckrun = checks;
return Standard_True;
Interface_CopyTool TC(myModel,theprotocol);
thecopier->CopiedRemaining (thegraph->Graph(),thelibrary,TC,newmod);
if (newmod.IsNull()) {
- sout<<" No Remaining Data recorded"<<std::endl; return Standard_False;
+ sout<<" No Remaining Data recorded"<<'\n'; return Standard_False;
} else if (newmod == myModel) {
- sout<<" Remaining causes all original data to be kept"<<std::endl;
+ sout<<" Remaining causes all original data to be kept"<<'\n';
thecopier->SetRemaining (thegraph->CGraph());
return Standard_False;
} else {
for (Standard_Integer i = 1; i <= nb; i ++)
{ if (thegraph->Graph().Status(i) >= 0) ne ++; }
if (ne == 0) {
- sout<<" - All entities are remaining, none yet sent"<<std::endl; return Standard_True;
+ sout<<" - All entities are remaining, none yet sent"<<'\n'; return Standard_True;
}
Interface_EntityIterator iter = SentList(0);
nb = iter.NbEntities();
if (nb == 0) {
- sout<<" - No recorded remaining entities"<<std::endl; return Standard_True;
+ sout<<" - No recorded remaining entities"<<'\n'; return Standard_True;
}
- sout <<" -- Recorded Remaining (not yet sent) Entities --"<<std::endl;
+ sout <<" -- Recorded Remaining (not yet sent) Entities --"<<'\n';
ListEntities (iter, 2, sout);
sout << " -- Maximum Sending Count (i.e. duplication in files) "<<
- MaxSendingCount() << std::endl;
+ MaxSendingCount() << '\n';
/*
sout<< " - Now, dispatches are deactivated"<<std::endl;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
sout<<" **** Interruption SendAll par Exception : ****\n";
sout<<anException.GetMessageString();
- sout<<"\n Abandon"<<std::endl;
+ sout<<"\n Abandon"<<'\n';
errhand = theerrhand;
checks.CCheck(0)->AddFail ("Exception Raised -> Abandon");
thecheckrun = checks;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
sout<<" **** Interruption SendSelected par Exception : ****\n";
sout<<anException.GetMessageString();
- sout<<"\n Abandon"<<std::endl;
+ sout<<"\n Abandon"<<'\n';
checks.CCheck(0)->AddFail ("Exception Raised -> Abandon");
errhand = theerrhand;
thecheckrun = checks;
{
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (use > 0) {
- if (mode == 0) sout<<"******************************************"<<std::endl;
+ if (mode == 0) sout<<"******************************************"<<'\n';
if (use == 1) {
- if (mode == 0) sout<<"***** General Parameters *****"<<std::endl;
+ if (mode == 0) sout<<"***** General Parameters *****"<<'\n';
} else if (use == 2) {
- if (mode == 0) sout<<"***** Load File *****"<<std::endl;
+ if (mode == 0) sout<<"***** Load File *****"<<'\n';
} else if (use == 3) {
- if (mode == 0) sout<<"***** Write File *****"<<std::endl;
+ if (mode == 0) sout<<"***** Write File *****"<<'\n';
} else if (use == 4) {
- if (mode == 0) sout<<"***** Split File *****"<<std::endl;
+ if (mode == 0) sout<<"***** Split File *****"<<'\n';
} else if (use == 5) {
- if (mode == 0) sout<<"***** Transfer (Read) *****"<<std::endl;
+ if (mode == 0) sout<<"***** Transfer (Read) *****"<<'\n';
} else if (use == 6) {
- if (mode == 0) sout<<"***** Transfer (Write) *****"<<std::endl;
+ if (mode == 0) sout<<"***** Transfer (Write) *****"<<'\n';
}
- if (mode == 0) sout<<"******************************************"<<std::endl<<std::endl;
+ if (mode == 0) sout<<"******************************************"<<'\n'<<'\n';
}
// Echainements particuliers (use > 0)
if (use == 5) {
TraceStatics (-2,mode);
- if (mode == 0) sout<<std::endl;
+ if (mode == 0) sout<<'\n';
} else if (use == 4 || use == 6) {
TraceStatics (-3,mode);
- if (mode == 0) sout<<std::endl;
+ if (mode == 0) sout<<'\n';
}
// Valeurs particulieres
} else if (use == 4 || use == -4) { // Split : Prefix & cie
if (mode == 0) {
Handle(TCollection_HAsciiString) str = theshareout->Prefix();
- if (!str.IsNull()) sout << "Prefix : "<<str->ToCString()<<std::endl;
- else sout << "Prefix not Defined" << std::endl;
+ if (!str.IsNull()) sout << "Prefix : "<<str->ToCString()<<'\n';
+ else sout << "Prefix not Defined" << '\n';
str = theshareout->DefaultRootName();
- if (!str.IsNull()) sout << "Default Root : "<<str->ToCString()<<std::endl;
- else sout << "Default Root not Defined" << std::endl;
+ if (!str.IsNull()) sout << "Default Root : "<<str->ToCString()<<'\n';
+ else sout << "Default Root not Defined" << '\n';
str = theshareout->Extension();
- if (!str.IsNull()) sout << "Extension : "<<str->ToCString()<<std::endl;
- else sout << "Extension not defined" << std::endl;
+ if (!str.IsNull()) sout << "Extension : "<<str->ToCString()<<'\n';
+ else sout << "Extension not defined" << '\n';
}
}
// Fin
if (use > 0) {
- if (mode == 0) sout<<"******************************************"<<std::endl<<std::endl;
+ if (mode == 0) sout<<"******************************************"<<'\n'<<'\n';
}
}
void IFSelect_WorkSession::DumpShare () const
{
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- sout<<" ********** Definition ShareOut (Complete) **********"<<std::endl;
+ sout<<" ********** Definition ShareOut (Complete) **********"<<'\n';
Handle(TCollection_HAsciiString) str = theshareout->Prefix();
- if (!str.IsNull()) sout << "Prefix : " << str->ToCString() << std::endl;
- else sout << "Prefix not Defined" << std::endl;
+ if (!str.IsNull()) sout << "Prefix : " << str->ToCString() << '\n';
+ else sout << "Prefix not Defined" << '\n';
str = theshareout->DefaultRootName();
- if (!str.IsNull()) sout << "Default Root : " << str->ToCString() << std::endl;
- else sout << "Default Root not Defined" << std::endl;
+ if (!str.IsNull()) sout << "Default Root : " << str->ToCString() << '\n';
+ else sout << "Default Root not Defined" << '\n';
str = theshareout->Extension();
- if (!str.IsNull()) sout << "Extension : " << str->ToCString() << std::endl;
- else sout << "Extension not defined" << std::endl;
+ if (!str.IsNull()) sout << "Extension : " << str->ToCString() << '\n';
+ else sout << "Extension not defined" << '\n';
Standard_Integer lr = theshareout->LastRun();
Standard_Integer nb = theshareout->NbDispatches();
- sout << "Nb Dispatches : " << nb <<" (Last Run : " << lr << ") : "<<std::endl;
+ sout << "Nb Dispatches : " << nb <<" (Last Run : " << lr << ") : "<<'\n';
for (Standard_Integer i = 1; i <= nb; i ++) {
Handle(IFSelect_Dispatch) disp = theshareout->Dispatch(i);
sout << "Dispatch n0 " << i;
if (HasName(disp)) sout << " Name:"<< Name(disp)->ToCString();
- sout << " Label:" << disp->Label() << std::endl;
+ sout << " Label:" << disp->Label() << '\n';
Handle(IFSelect_Selection) sel = disp->FinalSelection();
- if (sel.IsNull()) sout << " No Final Selection Defined" << std::endl;
+ if (sel.IsNull()) sout << " No Final Selection Defined" << '\n';
else if (HasName(sel)) sout << " Final Selection : Name:"
- << Name(sel)->ToCString() << " Label:" << sel->Label() << std::endl;
- else sout << " Final Selection : " << sel->Label() << std::endl;
+ << Name(sel)->ToCString() << " Label:" << sel->Label() << '\n';
+ else sout << " Final Selection : " << sel->Label() << '\n';
if (disp->HasRootName())
- sout<<" File Root Name : "<<disp->RootName()->ToCString()<<std::endl;
- else sout<<" No specific file root name (see Default Root)"<<std::endl;
+ sout<<" File Root Name : "<<disp->RootName()->ToCString()<<'\n';
+ else sout<<" No specific file root name (see Default Root)"<<'\n';
}
Standard_Integer nbm = theshareout->NbModifiers(Standard_True);
if (nbm > 0) sout<<
- " *** "<<nbm<<" active Model Modifiers : see ListModifiers ***"<<std::endl;
+ " *** "<<nbm<<" active Model Modifiers : see ListModifiers ***"<<'\n';
Standard_Integer nbf = theshareout->NbModifiers(Standard_False);
if (nbf > 0) sout<<
- " *** "<<nbf<<" active File Modifiers : see ListModifiers ***"<<std::endl;
- if (nbm+nbf == 0) sout<<" *** No active Modifiers ***"<<std::endl;
+ " *** "<<nbf<<" active File Modifiers : see ListModifiers ***"<<'\n';
+ if (nbm+nbf == 0) sout<<" *** No active Modifiers ***"<<'\n';
}
// #### #### #### #### #### #### #### #### ####
void IFSelect_WorkSession::ListItems (const Standard_CString lab) const
{
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- sout<< " ********** Items in Session **********"<<std::endl;
+ sout<< " ********** Items in Session **********"<<'\n';
Standard_Integer nb = MaxIdent();
Handle(TCollection_HAsciiString) str;
if (lab[0] != '\0') str = new TCollection_HAsciiString (lab);
sout<<"#"<<i;
if (HasName(var)) sout<<" - Named : "<<Name(var)->ToCString()<<" - ";
else sout<<" - (no name) - ";
- sout<<var->DynamicType()->Name()<<std::endl<<" "<<label->ToCString()<<std::endl;
+ sout<<var->DynamicType()->Name()<<'\n'<<" "<<label->ToCString()<<'\n';
}
}
Standard_Integer nb = theshareout->NbModifiers(formodel);
sout<< " ********** Modifiers in Session ";
sout<<(formodel ? "(For Model)" : "(For File)");
- sout<<": "<<nb<<" **********"<<std::endl;
+ sout<<": "<<nb<<" **********"<<'\n';
for (Standard_Integer i = 1; i <= nb; i ++) {
Handle(IFSelect_GeneralModifier) modif =
theshareout->GeneralModifier(formodel,i);
if (!modif.IsNull()) sout<<"Modifier n0."<<i<<" : "<<modif->Label();
if (HasName(modif)) sout << " Named as : " << Name(modif)->ToCString();
- sout<<std::endl;
+ sout<<'\n';
}
}
{
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (ItemIdent(sel) == 0) {
- sout << "Selection : Unknown"<<std::endl; //sout<<Handle
+ sout << "Selection : Unknown"<<'\n'; //sout<<Handle
return;
}
sout << " ********** Selection";
if (HasName(sel)) sout << " , Name : " << Name(sel)->ToCString();
- sout <<" **********"<<std::endl;
- sout<< "Label : " << sel->Label() << " . Input(s) : "<< std::endl;
+ sout <<" **********"<<'\n';
+ sout<< "Label : " << sel->Label() << " . Input(s) : "<< '\n';
Standard_Integer nb = 0;
IFSelect_SelectionIterator iter; sel->FillIterator(iter);
for (; iter.More(); iter.Next()) {
nb ++;
const Handle(IFSelect_Selection)& newsel = iter.Value();
- sout<<" -- "<<newsel->Label()<<std::endl;
+ sout<<" -- "<<newsel->Label()<<'\n';
}
- sout << " Nb Inputs:"<<nb<<std::endl;
+ sout << " Nb Inputs:"<<nb<<'\n';
}
else if (!cnt.IsNull()) selsign =
new IFSelect_SelectSignature (cnt,&nomsel[debsign],Standard_False);
else {
- std::cout<<selname<<" : neither Signature nor Counter"<<std::endl;
+ std::cout<<selname<<" : neither Signature nor Counter"<<'\n';
return sel;
}
Handle(IFSelect_Selection) sel = GiveSelection (nomsel);
if (sel.IsNull()) {
- std::cout<<"Neither Entity Number/Label nor Selection :"<<nomsel<<std::endl;
+ std::cout<<"Neither Entity Number/Label nor Selection :"<<nomsel<<'\n';
return list;
}
(const Standard_Integer level, Standard_OStream& S)
{
if (!IsLoaded())
- { S << " *** Data for List not available ***"<<std::endl; return; }
+ { S << " *** Data for List not available ***"<<'\n'; return; }
S << "\n *****************************************************************\n";
if (theloaded.Length() > 0)
- S << " ******** Loaded File : "<<theloaded.ToCString()<<Interface_MSG::Blanks(32-theloaded.Length())<<" ********"<<std::endl;
- else S << " ******** No name for Loaded File"<<std::endl;
+ S << " ******** Loaded File : "<<theloaded.ToCString()<<Interface_MSG::Blanks(32-theloaded.Length())<<" ********"<<'\n';
+ else S << " ******** No name for Loaded File"<<'\n';
if (level == 0) {
S <<" ******** Short Dump of Header ********\n";
S << " *****************************************************************\n\n";
- myModel->DumpHeader (S); S <<std::endl;
+ myModel->DumpHeader (S); S <<'\n';
}
Standard_Integer nbent = myModel->NbEntities();
}
S << " *****************************************************************\n"
<< " ******** Model : "<<nbent<<" Entities, of which "<<nbr<<" Root(s)\n"
- << " *****************************************************************\n"<<std::endl;
+ << " *****************************************************************\n"<<'\n';
if (level <= 0) return;
else if (level == 1) {
if (level == 7 || level == 10) mode = IFSelect_EntitiesByItem;
PrintCheckList (S, ModelCheckList(),Standard_False, mode);
} else {
- if (level == 3) S << " ******** Check Model (Fails) ********"<<std::endl;
- else S << " ******** Check Model (Complete) ********"<<std::endl;
+ if (level == 3) S << " ******** Check Model (Fails) ********"<<'\n';
+ else S << " ******** Check Model (Complete) ********"<<'\n';
Interface_CheckTool CT (Graph());
Interface_CheckIterator C;
if (theerrhand) {
Message_Messenger::StreamBuffer sout = Message::SendInfo();
sout<<" **** Interruption DumpModel (Check) par Exception ****\n";
S <<" ** ** Exception Raised during Check ! ** **\n";
- S <<" --> what could be determined is listed"<<std::endl;
+ S <<" --> what could be determined is listed"<<'\n';
}
}
else if (level == 3) C = CT.CheckList();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
sout<<" **** Interruption DumpModel par Exception : ****\n";
sout<<anException.GetMessageString();
- sout<<"\n Abandon"<<std::endl;
+ sout<<"\n Abandon"<<'\n';
}
}
- S <<std::endl<<"There are "<<nbent<<" Entities, of which "<<nbr<<" Root(s)"<<std::endl;
+ S <<'\n'<<"There are "<<nbent<<" Entities, of which "<<nbr<<" Root(s)"<<'\n';
}
// .... TraceDumpModel .... (Model + CheckList)
Standard_OStream& S) const
{
if (!IsLoaded())
- { S << " *** Data for List not available ***"<<std::endl; return; }
+ { S << " *** Data for List not available ***"<<'\n'; return; }
Standard_Integer num = myModel->Number(ent);
- if (num == 0) { S <<" *** Entity to Dump not in the Model ***"<<std::endl; return; }
- if (thelibrary.IsNull()) { S <<" *** WorkLibrary not defined ***"<<std::endl; return; }
+ if (num == 0) { S <<" *** Entity to Dump not in the Model ***"<<'\n'; return; }
+ if (thelibrary.IsNull()) { S <<" *** WorkLibrary not defined ***"<<'\n'; return; }
S << " ******** Dumping Entity n0 "<<num
- <<" level:"<<level<<" ********"<<std::endl;
+ <<" level:"<<level<<" ********"<<'\n';
thelibrary->DumpEntity (myModel,theprotocol,ent,S,level);
}
{
Standard_Integer i,nb;
Standard_Integer num = StartingNumber(ent);
- if (num == 0) { std::cout<<" -- PrintEntityStatus : unknown"<<std::endl; return; }
+ if (num == 0) { std::cout<<" -- PrintEntityStatus : unknown"<<'\n'; return; }
S <<" Ent. n0/id: ";
myModel->Print (ent, S);
Handle(TCollection_HAsciiString) hname = EntityName(ent);
if (!hname.IsNull() && hname->Length() > 0) S <<" Name:"<<hname->ToCString();
- S <<std::endl;
+ S <<'\n';
Handle(IFSelect_Signature) signtype = SignType();
- if (signtype.IsNull()) S <<" Type(CDL):"<<ent->DynamicType()->Name()<<std::endl;
- else S <<" Type:"<<signtype->Value (ent,myModel)<<std::endl;
+ if (signtype.IsNull()) S <<" Type(CDL):"<<ent->DynamicType()->Name()<<'\n';
+ else S <<" Type:"<<signtype->Value (ent,myModel)<<'\n';
S <<" Category : " <<CategoryName (ent)
- <<" Validity : " <<ValidityName (ent) << std::endl;
+ <<" Validity : " <<ValidityName (ent) << '\n';
Interface_CheckIterator chl = CheckOne (ent);
chl.Print (S,myModel,Standard_False,Standard_False);
Handle(TColStd_HSequenceOfTransient) list = Sharings(ent);
- if (list.IsNull()) S <<" Root"<<std::endl;
+ if (list.IsNull()) S <<" Root"<<'\n';
else {
nb = list->Length();
if (nb == 0) S <<" Root";
else S <<" Super-entities:"<<nb<<" : (n0/id):";
for (i = 1; i <= nb; i ++) { S <<" "; myModel->Print(list->Value(i), S); }
- S <<std::endl;
+ S <<'\n';
}
list = Shareds (ent);
- if (list.IsNull()) S <<" No sub-entity"<<std::endl;
+ if (list.IsNull()) S <<" No sub-entity"<<'\n';
else {
nb = list->Length();
if (nb == 0) S <<" No sub-entity";
else S <<" Sub-entities:"<<nb<<" , i.e. (n0/id):";
for (i = 1; i <= nb; i ++) { S <<" "; myModel->Print(list->Value(i), S); }
- S <<std::endl;
+ S <<'\n';
}
}
catch (Standard_Failure const& anException) {
sout<<" **** Interruption EvaluateSelection par Exception **** Intitule\n";
sout<<anException.GetMessageString();
- sout<<"\n Abandon"<<std::endl;
+ sout<<"\n Abandon"<<'\n';
}
errhand = theerrhand;
return;
}
if (!IsLoaded())
- { sout<< " *** Data for Evaluation not available ***"<<std::endl; return; }
+ { sout<< " *** Data for Evaluation not available ***"<<'\n'; return; }
if (ItemIdent(sel) == 0)
- { sout << " Selection : Unknown"<<std::endl; return; } //sout<<Handle
+ { sout << " Selection : Unknown"<<'\n'; return; } //sout<<Handle
Interface_EntityIterator iter = EvalSelection (sel);
ListEntities (iter, 1, sout);
sout << "**** (Unique) RootResult, Selection : "
- <<sel->Label()<<std::endl;
+ <<sel->Label()<<'\n';
}
catch (Standard_Failure const& anException) {
sout<<" **** Interruption EvaluateDispatch par Exception **** Intitule\n";
sout<<anException.GetMessageString();
- sout<<"\n Abandon"<<std::endl;
+ sout<<"\n Abandon"<<'\n';
}
errhand = theerrhand;
return;
Standard_Integer numdisp = DispatchRank(disp);
if (!IsLoaded())
- { sout<< " *** Data for List not available ***"<<std::endl; return; }
+ { sout<< " *** Data for List not available ***"<<'\n'; return; }
if (theshareout->NbDispatches() < numdisp || numdisp <= 0)
- { sout<<"Dispatch : Unknown"<<std::endl; return; } //sout<<Handle
+ { sout<<"Dispatch : Unknown"<<'\n'; return; } //sout<<Handle
if (disp->FinalSelection().IsNull())
- { sout<<"Dispatch : No Final Selection"<<std::endl; return; }//sout<<Handle
- sout<<" --- Dispatch Label : "<<disp->Label()<<std::endl;
+ { sout<<"Dispatch : No Final Selection"<<'\n'; return; }//sout<<Handle
+ sout<<" --- Dispatch Label : "<<disp->Label()<<'\n';
IFSelect_ShareOutResult eval(disp,thegraph->Graph());
eval.Evaluate();
eval.Packets (mode ? Standard_True : Standard_False);
Standard_Integer nbpack = evres->NbPackets();
- sout<<"Nb Packets produced : "<<nbpack<<" :"<<std::endl;
+ sout<<"Nb Packets produced : "<<nbpack<<" :"<<'\n';
for (numpack = 1; numpack <= nbpack; numpack ++) {
- sout<<"\n **** Packet n0 : "<<numpack<<" ****"<<std::endl;
- if (!mode) std::cout<<"Root Entities :"<<std::endl;
+ sout<<"\n **** Packet n0 : "<<numpack<<" ****"<<'\n';
+ if (!mode) std::cout<<"Root Entities :"<<'\n';
ListEntities (evres->Entities(numpack), (mode ? 2 : -1), sout);
}
//// Interface_EntityIterator iterem = disp->Remainder(thegraph->Graph());
if (mode == 0) return;
if (mode == 1 || mode == 3) {
- sout<<std::endl;
+ sout<<'\n';
if (evres->NbDuplicated(0,Standard_False) == 0)
- sout<<" **** All the Model is taken into account ****"<<std::endl;
+ sout<<" **** All the Model is taken into account ****"<<'\n';
else {
- sout<<" **** Starting Entities not taken by this Dispatch ****"<<std::endl;
+ sout<<" **** Starting Entities not taken by this Dispatch ****"<<'\n';
ListEntities (evres->Duplicated(0,Standard_False), 2, sout);
}
}
if (mode >= 2) {
sout<<" **** Entites in more than one packet ****";
Standard_Integer max = evres->HighestDuplicationCount();
- if (max < 2) sout<<" : There are none"<<std::endl;
+ if (max < 2) sout<<" : There are none"<<'\n';
else {
Standard_Integer newcount;
- sout<<std::endl;
+ sout<<'\n';
for (newcount = 2; newcount <= max; newcount ++) {
if (evres->NbDuplicated(newcount,Standard_False) == 0) continue;
- sout<<" **** Entities put in "<<newcount<<" packets ****"<<std::endl;
+ sout<<" **** Entities put in "<<newcount<<" packets ****"<<'\n';
ListEntities (evres->Duplicated(newcount,Standard_False), 2, sout);
}
}
catch (Standard_Failure const& anException) {
sout<<" **** Interruption EvaluateComplete par Exception : ****\n";
sout<<anException.GetMessageString();
- sout<<"\n Abandon"<<std::endl;
+ sout<<"\n Abandon"<<'\n';
}
errhand = theerrhand;
return;
}
if (!IsLoaded())
- { sout<< " *** Data for List not available ***"<<std::endl; return; }
+ { sout<< " *** Data for List not available ***"<<'\n'; return; }
IFSelect_ShareOutResult eval(theshareout,thegraph->Graph());
eval.Evaluate();
sout<<"\n******** Evaluation ShareOutResult (Complete) ********\n";
- sout<<" **** List of Packets **** Count : "<<eval.NbPackets()<<std::endl;
- if (mode == 0) sout << " ** (for each one : Root Entities) **"<<std::endl;
- else sout << " ** (for each one : Evaluated Content) **"<<std::endl;
+ sout<<" **** List of Packets **** Count : "<<eval.NbPackets()<<'\n';
+ if (mode == 0) sout << " ** (for each one : Root Entities) **"<<'\n';
+ else sout << " ** (for each one : Evaluated Content) **"<<'\n';
Standard_Integer numpack = 0;
Handle(IFSelect_PacketList) evres =
eval.Packets (mode ? Standard_True : Standard_False);
Standard_Integer nbpack = evres->NbPackets();
- sout<<"Nb Packets produced : "<<nbpack<<" :"<<std::endl;
+ sout<<"Nb Packets produced : "<<nbpack<<" :"<<'\n';
for (numpack = 1; numpack <= nbpack; numpack ++) {
- sout<<"\n **** Packet n0 : "<<numpack<<" ****"<<std::endl;
- if (!mode) std::cout<<"Root Entities :"<<std::endl;
+ sout<<"\n **** Packet n0 : "<<numpack<<" ****"<<'\n';
+ if (!mode) std::cout<<"Root Entities :"<<'\n';
ListEntities (evres->Entities(numpack), (mode ? 2: -1), sout);
}
if (mode == 0) return;
if (mode == 1 || mode == 3) {
- sout<<std::endl;
+ sout<<'\n';
if (evres->NbDuplicated(0,Standard_False) == 0)
- sout<<" **** All the Model is taken into account ****"<<std::endl;
+ sout<<" **** All the Model is taken into account ****"<<'\n';
else {
- sout<<" **** Starting Entities Forgotten ****"<<std::endl;
+ sout<<" **** Starting Entities Forgotten ****"<<'\n';
ListEntities (evres->Duplicated(0,Standard_False), 2, sout);
}
}
if (mode >= 2) {
- sout<<" **** Entites in more than one packet ****"<<std::endl;
+ sout<<" **** Entites in more than one packet ****"<<'\n';
Standard_Integer max = evres->HighestDuplicationCount();
- if (max < 2) sout<<" : There are none"<<std::endl;
+ if (max < 2) sout<<" : There are none"<<'\n';
else {
Standard_Integer newcount;
- sout<<std::endl;
+ sout<<'\n';
for (newcount = 2; newcount <= max; newcount ++) {
if (evres->NbDuplicated(newcount,Standard_False) == 0) continue;
- sout<<" **** Entities put in "<<newcount<<" packets ****"<<std::endl;
+ sout<<" **** Entities put in "<<newcount<<" packets ****"<<'\n';
ListEntities (evres->Duplicated(newcount,Standard_False), 2, sout);
}
}
{
int titre = 0;
Standard_Integer mode = (mmode < 0 ? -mmode : mmode);
- if (mmode >= 0) sout << " List of " << iter.NbEntities() << " Entities :"<<std::endl;
+ if (mmode >= 0) sout << " List of " << iter.NbEntities() << " Entities :"<<'\n';
if (!IsLoaded())
- { sout<< " *** Data for List not available ***"<<std::endl; return; }
+ { sout<< " *** Data for List not available ***"<<'\n'; return; }
Interface_ShareFlags tool(thegraph->Graph());
try {
int newcount = -1; int mods = 0; int cnt = 0;
for (iter.Start(); iter.More(); iter.Next()) {
if (!titre && mode == 1) sout
- << "Number/Id. Category Validity Type\n----------- ----...."<<std::endl;
+ << "Number/Id. Category Validity Type\n----------- ----...."<<'\n';
// 123456789 123456789 123456 123456789 123456789 123456
- if (!titre && mode == 0) sout<<" Keys : R Root ? Unknown * Unloaded"<<std::endl;
+ if (!titre && mode == 0) sout<<" Keys : R Root ? Unknown * Unloaded"<<'\n';
if (!titre && mode == 2) sout<<"(";
titre = 1;
const Handle(Standard_Transient)& ent = iter.Value();
if (catnum > 0) sout<<" "<<Interface_Category::Name (catnum);
sout << " (" << ValidityName (ent) << ") ";
- sout<<" Type:"<<myModel->TypeName (ent, Standard_False)<<std::endl;
+ sout<<" Type:"<<myModel->TypeName (ent, Standard_False)<<'\n';
} else if (mode == 2) {
newcount ++;
if (newcount > 0) sout<<",";
sout<<num;
} else {
newcount ++; mods = 0; cnt ++;
- if (newcount >= 10) { sout << std::endl<<"["<<cnt<<"]:"; newcount = 1; }
+ if (newcount >= 10) { sout << '\n'<<"["<<cnt<<"]:"; newcount = 1; }
if (newcount > 0) sout << " ";
myModel->Print (ent, sout, 0);
if (!tool.IsShared(ent)) { if(mods == 0) sout<<"("; sout<<"R"; mods++; }
if (mods) { sout<<")"; newcount ++; }
}
}
- if (mode == 0) sout<<std::endl;
- if (mode == 2) sout<<")"<<std::endl;
+ if (mode == 0) sout<<'\n';
+ if (mode == 2) sout<<")"<<'\n';
}
catch (Standard_Failure const& anException) {
sout<<" **** Interruption ListEntities par Exception : ****\n";
sout<<anException.GetMessageString();
- sout<<"\n Abandon"<<std::endl;
+ sout<<"\n Abandon"<<'\n';
}
}
(const Handle(IGESAppli_DrilledHole)& ent, const IGESData_IGESDumper& /*dumper*/,
Standard_OStream& S, const Standard_Integer /*level*/) const
{
- S << "IGESAppli_DrilledHole" << std::endl;
+ S << "IGESAppli_DrilledHole" << '\n';
- S << "Number of property values : " << ent->NbPropertyValues() << std::endl;
+ S << "Number of property values : " << ent->NbPropertyValues() << '\n';
S << "Drill diameter size :" << ent->DrillDiaSize() << " ";
- S << "Finish diameter size : " << ent->FinishDiaSize() << std::endl;
+ S << "Finish diameter size : " << ent->FinishDiaSize() << '\n';
S << "Plating indication flag : ";
if (!ent->IsPlating()) S << "NO" << " - ";
else S << "YES - ";
S << "Lower Numbered Layer : " << ent->NbLowerLayer() << " ";
- S << "Higher Numbered Layer : " << ent->NbHigherLayer() << std::endl;
+ S << "Higher Numbered Layer : " << ent->NbHigherLayer() << '\n';
}
S << "Nodes : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbNodes(),ent->Node);
S << "\nElement Name : " << ent->Name()->String();
- S << std::endl;
+ S << '\n';
}
S << "\nContinuation Flow Associativities : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbContFlowAssociativities(),
ent->ContFlowAssociativity);
- S << std::endl;
+ S << '\n';
}
S << "incorrect value\n";
if (ent->ExtensionFlag() == 2)
- S << "Extension Value : " << ent->ExtensionValue() << std::endl;
+ S << "Extension Value : " << ent->ExtensionValue() << '\n';
else
- S << "No Extension Value (Extension Flag != 2)" << std::endl;
+ S << "No Extension Value (Extension Flag != 2)" << '\n';
}
S << "\n";
S << "Tabular Data Properties : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbCases(),ent->TabularData);
- S << std::endl;
+ S << '\n';
}
// IGESData_DumpListXYZL(S,-level,1,nbcases,ent->TranslationParameter,loca);
S << "Rotational Parameters : ";
// IGESData_DumpListXYZL(S,-level,1,nbcases,ent->RotationalParameter,loca);
- S << " TO BE DONE" << std::endl;
+ S << " TO BE DONE" << '\n';
break;
case 5:
case 6: {
{
S << "[" << i << "]: ";
dumper.Dump (ent->Note(i),S, 1);
- S << std::endl;
+ S << '\n';
}
S << "Nodes :\n";
S << "Node Identifiers :\n";
break;
default: break;
}
- S << std::endl;
+ S << '\n';
}
dumper.Dump(ent->System(),S, level);
else
S << "Global Cartesian Coordinate System (default)";
- S << std::endl;
+ S << '\n';
}
S << "\n";
S << "Level Numbers : ";
IGESData_DumpVals(S,level,1, ent->NbLevelNumbers(),ent->LevelNumber);
- S << std::endl;
+ S << '\n';
}
<< "Number of property values : " << ent->NbPropertyValues() << "\n"
<< "Drill Diameter Size : " << ent->DrillDiameterSize() << "\n"
<< "Finish Diameter Size : " << ent->FinishDiameterSize() << "\n"
- << "Drilled Hole Function Code : " << ent->FunctionCode() << std::endl;
+ << "Drilled Hole Function Code : " << ent->FunctionCode() << '\n';
}
S << "\n";
S << "Internal Number or Name : ";
IGESData_DumpString(S,ent->InternalNumber());
- S << std::endl;
+ S << '\n';
}
S << "Number of Property Values : " << ent->NbPropertyValues() << "\n";
S << "PinNumber : ";
IGESData_DumpString(S,ent->PinNumberVal());
- S << std::endl;
+ S << '\n';
}
S << "Continuation Flow Associativities : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbContFlowAssociativities(),
ent->ContFlowAssociativity);
- S << std::endl;
+ S << '\n';
}
S << "Number of Property Values : " << ent->NbPropertyValues() << "\n";
S << "ReferenceDesignator : ";
IGESData_DumpString(S,ent->RefDesignatorText());
- S << std::endl;
+ S << '\n';
}
<< "Electrical components restriction : "
<< ent->ElectricalComponentRestriction() << "\n"
<< "Electrical circuitary restriction : "
- << ent->ElectricalCktRestriction() << std::endl;
+ << ent->ElectricalCktRestriction() << '\n';
}
<< "Type of attached associativity : " << ent->AssocType() << "\n"
<< "Name of attached associativity : ";
IGESData_DumpString(S,ent->Name());
- S << std::endl;
+ S << '\n';
}
S << "IGESBasic_ExternalRefFile\n"
<< "External Reference File Identifier : ";
IGESData_DumpString(S,ent->FileId());
- S << std::endl;
+ S << '\n';
}
dumper.Dump (ent->Entity(i),S, 1);
S << "\n";
}
- S << std::endl;
+ S << '\n';
}
S << "\n"
<< "External Reference Symbolic Name : ";
IGESData_DumpString(S,ent->ReferenceName());
- S << std::endl;
+ S << '\n';
}
S << "\n"
<< "External Reference Symbolic Name : ";
IGESData_DumpString(S,ent->ReferenceName());
- S << std::endl;
+ S << '\n';
}
S << "IGESBasic_ExternalRefName\n"
<< "External Reference Symbolic Name : ";
IGESData_DumpString(S,ent->ReferenceName());
- S << std::endl;
+ S << '\n';
}
S << "IGESBasic_ExternalReferenceFile\n"
<< "External Reference Names : ";
IGESData_DumpStrings(S,level,1, ent->NbListEntries(),ent->Name);
- S << std::endl;
+ S << '\n';
}
S << "IGESBasic_Group\n"
<< "Entries in the Group : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbEntities(),ent->Entity);
- S << std::endl;
+ S << '\n';
}
S << "IGESBasic_GroupWithoutBackP\n"
<< "Entries in the Group : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbEntities(),ent->Entity);
- S << std::endl;
+ S << '\n';
}
<< "Entity level : " << ent->NewEntityLevel() << "\n"
<< "Blank status : " << ent->NewBlankStatus() << "\n"
<< "Line weight : " << ent->NewLineWeight() << "\n"
- << "Color number : " << ent->NewColorNum() << std::endl;
+ << "Color number : " << ent->NewColorNum() << '\n';
}
<< "Number of property values : " << ent->NbPropertyValues() << "\n"
<< "Name : ";
IGESData_DumpString(S,ent->Value());
- S << std::endl;
+ S << '\n';
}
S << "IGESBasic_OrderedGroup\n"
<< "Entries in the Group : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbEntities(),ent->Entity);
- S << std::endl;
+ S << '\n';
}
S << "IGESBasic_OrderedGroupWithoutBackP\n"
<< "Entries in the Group : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbEntities(),ent->Entity);
- S << std::endl;
+ S << '\n';
}
S << "\n"
<< "Children : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbChildren(),ent->Child);
- S << std::endl;
+ S << '\n';
}
<< " Translation Data : ";
IGESData_DumpXYZL(S,level, ent->Translation(), ent->Location());
S << " Scale Factors : " << ent->ScaleFactor() << "\n"
- << std::endl;
+ << '\n';
}
S << "\n"
<< "The Associated Entities : ";
IGESData_DumpEntities(S,dumper,level,1,ent->NbEntities(),ent->AssociatedEntity);
- S << std::endl;
+ S << '\n';
}
for(; aMapCountIter.More() && aMapListIter.More();
aMapCountIter.Next(), aMapListIter.Next()) {
Message_Messenger::StreamBuffer aSender = TF->SendInfo();
- aSender << aMapCountIter.Value() << aMapCountIter.Key() << std::endl;
+ aSender << aMapCountIter.Value() << aMapCountIter.Key() << '\n';
if (mode == IFSelect_ListByItem) {
const Handle(TColStd_HSequenceOfInteger)& entityList = aMapListIter.Value();
Standard_Integer length = entityList->Length();
aSender << line;
}
}
- aSender << std::endl;
+ aSender << '\n';
}
}
break;
NCollection_DataMap<TCollection_AsciiString, Standard_Integer>::Iterator aMapIter(aMapCountResult);
for (; aMapIter.More(); aMapIter.Next())
{
- TF->SendInfo() << aMapIter.Key() << aMapIter.Value() << std::endl;
+ TF->SendInfo() << aMapIter.Key() << aMapIter.Value() << '\n';
}
break;
}
for(; aMapCountIter.More(); aMapCountIter.Next()) {
char mess[80];
sprintf(mess, aMapCountIter.Key().ToCString(), aMapCountIter.Value());
- TF->SendInfo() << mess << std::endl; //dicoCountIter.Value() << dicoCountIter.Name() << std::endl;
+ TF->SendInfo() << mess << '\n'; //dicoCountIter.Value() << dicoCountIter.Name() << std::endl;
}
break;
}
else { S <<" ["<<i<<"]=" << cont->ParamValue(i)->String(); }
if ( i == (i%5)*5) S << "\n";
}
- S << std::endl;
+ S << '\n';
}
if (own >= 1) {
if (ent->HasShortLabel()) S <<"**** Label :"<<ent->ShortLabel()->ToCString();
if (ent->HasSubScriptNumber()) S <<" SubScript:"<<ent->SubScriptNumber();
- if (ent->HasShortLabel()) S <<std::endl;
+ if (ent->HasShortLabel()) S <<'\n';
if (ent->HasTransf())
{ S <<"** Transf.Matrix :"; PrintDNum(ent->Transf(),S); S <<"\n"; }
if (ent->LineWeightNumber() != 0) {
S <<"** LineWeight Num:"<<ent->LineWeightNumber();
if (diratt > 0) S <<" -> Value:"<<ent->LineWeight();
- S <<std::endl;
+ S <<'\n';
}
if (ent->DefColor() == IGESData_DefValue)
{ S <<"** Color Value :"<<ent->RankColor(); }
else if (ent->DefColor() == IGESData_DefReference)
{ S <<"** Color Ref :"; PrintDNum (ent->Color(),S); }
- S <<std::endl;
+ S <<'\n';
if (own > 3) {
S <<"**** Own Data ****\n\n";
}
}
if (iasuit) { if (att <= 1) S << "\n"; }
- S <<"\n**** End of Dump ****\n"<<std::endl;
+ S <<"\n**** End of Dump ****\n"<<'\n';
}
if (thelib.Select(ent,module,CN))
module->OwnDump(CN,ent,*this,S,own);
else if (themodel.IsNull())
- S <<" **** Dump impossible. Type "<<ent->DynamicType()->Name()<<std::endl;
+ S <<" **** Dump impossible. Type "<<ent->DynamicType()->Name()<<'\n';
else
S <<" **** Dump Impossible, n0:id:"<<themodel->Number(ent)<<":D"
- <<themodel->DNum(ent)<<" Type "<<ent->DynamicType()->Name()<<std::endl;
+ <<themodel->DNum(ent)<<" Type "<<ent->DynamicType()->Name()<<'\n';
}
(Standard_OStream& S, const Standard_Integer ) const
{
Standard_Integer ns = thestart->Length();
- S <<"**** Dump of IGES Model , Start and Global Sections ****"<<std::endl;
+ S <<"**** Dump of IGES Model , Start and Global Sections ****"<<'\n';
if (ns > 0) {
S << "**** Start Section : "<<ns<<" Line(s) ****\n";
for (Standard_Integer i = 1; i <= ns; i ++)
- S <<"["<<(i<10 ? " ": "")<<i<<"]:"<<thestart->Value(i)->ToCString()<<std::endl;
+ S <<"["<<(i<10 ? " ": "")<<i<<"]:"<<thestart->Value(i)->ToCString()<<'\n';
}
S << "\n**** Global Section ****\n";
char sep = theheader.Separator();
S <<"\n";
Handle(TCollection_HAsciiString) str;
str = theheader.SendName();
- if (!str.IsNull()) S <<"[ 3] Sender : "<<str->ToCString()<<std::endl;
+ if (!str.IsNull()) S <<"[ 3] Sender : "<<str->ToCString()<<'\n';
str = theheader.FileName();
- if (!str.IsNull()) S <<"[ 4] (recorded) File Name : "<<str->ToCString()<<std::endl;
+ if (!str.IsNull()) S <<"[ 4] (recorded) File Name : "<<str->ToCString()<<'\n';
str = theheader.SystemId();
- if (!str.IsNull()) S <<"[ 5] System Identification : "<<str->ToCString()<<std::endl;
+ if (!str.IsNull()) S <<"[ 5] System Identification : "<<str->ToCString()<<'\n';
str = theheader.InterfaceVersion();
- if (!str.IsNull()) S <<"[ 6] Interface Version : "<<str->ToCString()<<std::endl;
- S <<std::endl;
+ if (!str.IsNull()) S <<"[ 6] Interface Version : "<<str->ToCString()<<'\n';
+ S <<'\n';
S << "[ 7] Integer Bits : " << theheader.IntegerBits()
- << " Features for Reals : " << std::endl;
+ << " Features for Reals : " << '\n';
S << "[ 8] Single Max.Power(10) : " << theheader.MaxPower10Single();
S << " [ 9] Digits : " << theheader.MaxDigitsSingle()<<"\n";
S << "[10] Double Max.Power(10) : " << theheader.MaxPower10Double();
num = theheader.DraftingStandard();
S << "\n[24] Drafting Standard : " << num;
if (num > 0) S << " -> Name : " << IGESData_BasicEditor::DraftingName(num);
- S <<std::endl;
+ S <<'\n';
if (theheader.HasLastChangeDate()) {
str = theheader.LastChangeDate();
S << "[25] Last Change Date : " << str->ToCString()
- <<" i.e. "<<IGESData_GlobalSection::NewDateString(str,1)->ToCString()<<std::endl;
+ <<" i.e. "<<IGESData_GlobalSection::NewDateString(str,1)->ToCString()<<'\n';
}
- else S <<"[25] Last Change Date not defined (version IGES < 5.1)" << std::endl;
+ else S <<"[25] Last Change Date not defined (version IGES < 5.1)" << '\n';
if (theheader.HasApplicationProtocol()) {
str = theheader.ApplicationProtocol();
- S << "[26] Application Protocol : " << str->ToCString() <<std::endl;
+ S << "[26] Application Protocol : " << str->ToCString() <<'\n';
}
- S << " **** End of Dump ****"<<std::endl;
+ S << " **** End of Dump ****"<<'\n';
}
#endif
// Attention aux cas d erreur : contenu redefini
if (themodel->IsRedefinedContent(i)) {
- sout << " -- IGESWriter : Erroneous Entity N0."<<i<<" --"<<std::endl;
+ sout << " -- IGESWriter : Erroneous Entity N0."<<i<<" --"<<'\n';
Handle(Interface_ReportEntity) rep = themodel->ReportEntity(i);
if (!rep.IsNull()) cnt = GetCasted(IGESData_IGESEntity,rep->Content());
if (cnt.IsNull()) cnt = ent; // secours
undent->WriteOwnParams (*this);
}
else sout<<" -- IGESWriter : Not Processed for n0."<<i<<" in file, Type "
- <<cnt->TypeNumber()<<" Form "<<cnt->FormNumber()<<std::endl;
+ <<cnt->TypeNumber()<<" Form "<<cnt->FormNumber()<<'\n';
Associativities (cnt);
Properties (cnt);
Standard_Integer nbs = 1;
if (thestar.IsNull()) {
if (fnes) {
- S << " *** EUCLID/STRIM DESKTOP CLIPBOARD ***"<<std::endl;
+ S << " *** EUCLID/STRIM DESKTOP CLIPBOARD ***"<<'\n';
writefnes (S," S0000001");
}
else S <<" S0000001";
// 123456789 123456789 123456789 123456789 123456789 123456789 123456789 12
- S << std::endl;
+ S << '\n';
} else {
nbs = thestar->Length();
for (i = 1; i <= nbs; i ++) {
S << &blancs[line->Length()];
if (fnes) writefnes (S,finlin);
else S << finlin;
- S << std::endl;
+ S << '\n';
}
}
#ifdef PATIENCELOG
S << &blancs[line->Length()];
if (fnes) writefnes (S,finlin);
else S << finlin;
- S << std::endl;
+ S << '\n';
isGood = S.good();
}
if(!isGood)
S << &blancs[line->Length()];
if (fnes) writefnes (S,finlin);
else S << finlin;
- S << std::endl;
+ S << '\n';
isGood = S.good();
#ifdef PATIENCELOG
lignespatience --;
<< "Number Of Items per Entry :\n"
<< "Items :\n";
IGESData_DumpVals(S,-level,1, ent->NbClassDefs(),ent->BackPointerReq);
- S << std::endl;
+ S << '\n';
if (level > 4)
{
// Warning : Item is a JAGGED Array
S << "]\n";
}
}
- S << std::endl;
+ S << '\n';
}
S << " Attribute Value Pointer : ";
dumper.Dump (ent->AttributeTextDisplay(i,j),S, sublevel);
}
- S << std::endl;
+ S << '\n';
}
}
}
}
- S << std::endl;
+ S << '\n';
}
S << "\n";
}
}
- S << std::endl;
+ S << '\n';
}
<< "Number of property values : " << ent->NbPropertyValues() << "\n"
<< "Property Name : ";
IGESData_DumpString(S,ent->Name());
- S << std::endl;
+ S << '\n';
switch (level)
{
case 4:
}
}
}
- S << std::endl;
+ S << '\n';
}
IGESData_DumpStrings(S,level,1, ent->NbStatements(),ent->LanguageStatement);
S << "END MACRO : ";
IGESData_DumpString(S,ent->ENDMACRO());
- S << std::endl;
+ S << '\n';
}
S << "\nNumber of values of independent variables : ";
IGESData_DumpVals(S,level,1, nbIndeps,ent->NbValues);
// ?? JAGGED ??
- S << std::endl << "Values of the independent variable : ";
+ S << '\n' << "Values of the independent variable : ";
if (level < 5) S << " [ask level > 4]";
else {
for (Standard_Integer ind = 1; ind <= nbIndeps; ind ++) {
- S << std::endl << "[" << ind << "]:";
+ S << '\n' << "[" << ind << "]:";
Standard_Integer nbi = ent->NbValues(ind);
for (Standard_Integer iv = 1; iv <= nbi; iv ++)
S << " " << ent->IndependentValue(ind,iv);
}
}
// IGESData_DumpVals(aSender,level,1, nbIndeps,ent->IndependentValue);
- S << std::endl << "Values of the dependent variable : ";
+ S << '\n' << "Values of the dependent variable : ";
// IGESData_DumpVals(aSender,level,1, nbDeps,ent->DependentValue);
S << " TO BE DONE"
- << std::endl;
+ << '\n';
}
<< " ScaleFactor: " << ent->ScaleFactor(i) << "\n";
}
}
- S << std::endl;
+ S << '\n';
}
S << "\n"
<< "Second Leader Entity : ";
dumper.Dump(ent->SecondLeader(),S, sublevel);
- S << std::endl;
+ S << '\n';
}
IGESData_DumpXY(S, ent->UpperRight());
S << "\n Upper left corner : ";
IGESData_DumpXY(S, ent->UpperLeft());
- S << std::endl;
+ S << '\n';
}
<< "Data Points :\n";
IGESData_DumpListXYLZ(S,level,1, ent->NbPoints(),ent->Point,
ent->Location(), ent->ZDisplacement());
- S << std::endl;
+ S << '\n';
}
S << "\n"
<< "Second Witness Entity : ";
dumper.Dump(ent->SecondWitnessLine(),S, sublevel);
- S << std::endl;
+ S << '\n';
}
S << "\n"
<< "Center Point : ";
IGESData_DumpXYL(S,level, ent->Center(), ent->Location());
- S << std::endl;
+ S << '\n';
}
<< ", Start Index : " << ent->StartIndex(i)
<< ", End Index : " << ent->EndIndex(i) << "\n";
}
- S << std::endl;
+ S << '\n';
}
<< "Lower Tolerance : " << ent->LowerTolerance() << "\n"
<< "Sign Suppression Flag : " << ( ent->SignSuppressionFlag() ? "True" : "False" ) << "\n"
<< "Fraction Flag : " << ent->FractionFlag() << "\n"
- << "Precision : " << ent->Precision() << std::endl;
+ << "Precision : " << ent->Precision() << '\n';
}
<< "Fraction Flag : " << ent->FractionFlag();
if (ent->FractionFlag() == 0) S << " Decimal , Precision : ";
else S << " Fraction , Denominator : ";
- S << ent->PrecisionOrDenominator() << std::endl;
+ S << ent->PrecisionOrDenominator() << '\n';
}
S << "\n"
<< "Geometry Entities : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbGeometryEntities(),ent->GeometryEntity);
- S << std::endl;
+ S << '\n';
}
S << "\n"
<< "Number of Leaders : " << ent->NbLeaders() << " Leaders : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbLeaders(),ent->Leader);
- S << std::endl;
+ S << '\n';
}
<< "Number of Leaders : " << ent->NbLeaders() << "\n"
<< "Leaders : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbLeaders(),ent->Leader);
- S << std::endl;
+ S << '\n';
}
S << "\n";
}
}
- S << std::endl;
+ S << '\n';
}
IGESData_DumpEntities(S,dumper ,level,1, ent->NbGeomEntities(),ent->GeomEntity);
S << "\nLeader Arrows : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbLeaders(),ent->LeaderArrow);
- S << std::endl;
+ S << '\n';
}
S << "\nSegment Tails : ";
IGESData_DumpListXYLZ(S,level,1, ent->NbSegments(),ent->SegmentTail,
ent->Location(), ent->ZDepth());
- S << std::endl;
+ S << '\n';
}
S << "\n"
<< "Second Witness Entity : ";
dumper.Dump(ent->SecondWitness(),S, sublevel);
- S << std::endl;
+ S << '\n';
}
<< "Point : ";
IGESData_DumpXYZL(S,level, ent->Point(i), ent->Location());
}
- S << std::endl;
+ S << '\n';
}
S << "\n";
}
}
- else S << std::endl;
+ else S << '\n';
}
dumper.Dump(ent->Leader2(),S, sublevel);
S << "\n";
}
- S << std::endl;
+ S << '\n';
}
<< "Data Points : ";
IGESData_DumpListXYLZ(S,level,1, ent->NbPoints(),ent->Point,
ent->Location(), ent->ZDisplacement());
- S << std::endl;
+ S << '\n';
}
<< "Data Points : ";
IGESData_DumpListXYLZ(S,level,1, ent->NbPoints(),ent->Point,
ent->Location(), ent->ZDisplacement());
- S << std::endl;
+ S << '\n';
}
else S << "Do\n";
S << "The Do-Dont List : ";
IGESData_DumpVals(S,level,1, ent->ListCount(),ent->ListPosition);
- S << std::endl;
+ S << '\n';
}
<< "Swap Flag : " << ( ent->SwapFlag() ? "True" : "False" ) << "\n"
<< "Owner Subfigure Entity : ";
dumper.Dump(ent->OwnerSubfigure(),S, tempSubLevel);
- S << std::endl;
+ S << '\n';
}
}
S << "\nAnnotation Entities : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbAnnotations(),ent->Annotation);
- S << std::endl;
+ S << '\n';
}
}
S << "Annotation Entities : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbAnnotations(),ent->Annotation);
- S << std::endl;
+ S << '\n';
}
S << "\n";
}
}
- S << std::endl;
+ S << '\n';
}
dumper.Dump(ent->DesignatorTemplate(),S, sublevel);
S << "\nConnect Points : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbConnectPoints(),ent->ConnectPoint);
- S << std::endl;
+ S << '\n';
}
dumper.Dump(ent->DesignatorTemplate(),S, tempSubLevel);
S << "\nConnect Point Entities : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbPointEntities(),ent->PointEntity);
- S << std::endl;
+ S << '\n';
}
}
S << "Back Plane Distance : " << ent->BackPlaneDistance() << " "
<< "Front Plane Distance : " << ent->FrontPlaneDistance() << "\n"
- << std::endl;
+ << '\n';
}
S << "\n"
<< "Array of Entities on the specified plane : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbEntities(),ent->Entity);
- S << std::endl;
+ S << '\n';
}
else S << "(0)Do ";
S << "Do-Dont List : ";
IGESData_DumpVals(S,level,1, ent->ListCount(),ent->ListPosition);
- S << std::endl;
+ S << '\n';
}
}
break;
}
- S << std::endl;
+ S << '\n';
}
S << "Back Plane Of View Volume : ";
dumper.Dump(ent->BackPlane(),S, tempSubLevel); S << "\n";
S << "Front Plane Of View Volume : ";
- dumper.Dump(ent->FrontPlane(),S, tempSubLevel); S << std::endl;
+ dumper.Dump(ent->FrontPlane(),S, tempSubLevel); S << '\n';
}
S << "\n"
<< "Entities Displayed : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbDisplayedEntities(),ent->DisplayedEntity);
- S << std::endl;
+ S << '\n';
}
Standard_Boolean IGESDraw_ToolViewsVisible::OwnCorrect
if (ent->IsColorDefinition(I)) {
S << "Color Definition : ";
dumper.Dump (ent->ColorDefinition(I),S, tempSubLevel);
- S << std::endl;
+ S << '\n';
}
else S << "Color Value : " << ent->ColorValue(I) << "\n";
}
S << "Displayed Entities : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbDisplayedEntities(),ent->DisplayedEntity);
- S << std::endl;
+ S << '\n';
}
Standard_Boolean IGESDraw_ToolViewsVisibleWithAttr::OwnCorrect
<< " Ending Parameter Value : " << ent->UMax() << "\n"
<< "Unit Normal : ";
IGESData_DumpXYZL(S,level, ent->Normal(), ent->Location());
- S << std::endl;
+ S << '\n';
}
S << "\n"
<< "Control Points (Poles) : ";
//IGESData_DumpRectXYZL(S,level,1, ent->NbPoles(),ent->Pole, ent->Location());
- if (level < 5) { S << " [ content : ask level > 4 ]" << std::endl; return; }
+ if (level < 5) { S << " [ content : ask level > 4 ]" << '\n'; return; }
gp_GTrsf loca = ent->Location();
for (Standard_Integer JP = 0; JP <= indV; JP ++)
for (Standard_Integer IP = 0; IP <= indU; IP ++) {
S <<" - ["<<IP<<","<<JP<<"]: ";
IGESData_DumpXYZL(S,level,ent->Pole(IP,JP),loca);
}
- S << std::endl;
+ S << '\n';
}
}
S << "\n";
}
- S << std::endl;
+ S << '\n';
}
S << "\n"
<< "Boundary Entities : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbBoundaries(),ent->Boundary);
- S << std::endl;
+ S << '\n';
}
S << "\n";
if (level <= 5) return;
S << " Normal Axis : "; IGESData_DumpXYZL(S,level,ent->Axis(),ent->VectorLocation());
- S << std::endl;
+ S << '\n';
}
S << "IGESGeom_CompositeCurve\n"
<< "Curve Entities :\n";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbCurves(),ent->Curve);
- S << std::endl;
+ S << '\n';
}
<< "End Point : ";
IGESData_DumpXYLZ(S,level, ent->EndPoint(), ent->Location(), ent->ZPlane());
S << "\n";
- if (level <= 4) S <<" -- Computed Definition : ask level > 4" << std::endl;
+ if (level <= 4) S <<" -- Computed Definition : ask level > 4" << '\n';
else {
gp_Pnt Cen; gp_Dir Ax; Standard_Real Rmin,Rmax;
ent->Definition (Cen,Ax,Rmin,Rmax);
else S << " Major Radius : " << Rmax << " Minor Radius : " << Rmin <<"\n";
S << " Normal Axis : "; IGESData_DumpXYZL(S,level,ent->Axis(),ent->VectorLocation());
- S << std::endl;
+ S << '\n';
}
}
S << " Transformed ("<< T.X() << "," << T.Y() << "," << T.Z() << ")";
}
}
- S << std::endl;
+ S << '\n';
}
}
else S << " [ for content, ask level > 4 ]";
- S << std::endl;
+ S << '\n';
}
S << "IGESGeom_Direction\n\n"
<< "Value : ";
IGESData_DumpXYZL(S,level, ent->Value(), ent->VectorLocation());
- S << std::endl;
+ S << '\n';
}
<< " Rotation about reference entity : " << ent->Rotation() << "\n"
<< "Reference Entity : ";
dumper.Dump(ent->ReferenceEntity(),S, sublevel);
- S << std::endl;
+ S << '\n';
}
S << "\n"
"End Point : ";
IGESData_DumpXYZL(S,level, ent->EndPoint(), ent->Location());
- S << std::endl;
+ S << '\n';
}
<< "Normal Vector : ";
IGESData_DumpXYZL(S,level, ent->NormalVector(), ent->VectorLocation()); S <<"\n";
S << "Offset curve Parameters. Starting : " << ent->StartParameter() << " "
- << "Ending : " << ent->EndParameter() << std::endl;
+ << "Ending : " << ent->EndParameter() << '\n';
}
<< "Offset Distance : " << ent->Distance() << " "
<< "Surface to be offset : ";
dumper.Dump(ent->Surface(),S, sublevel);
- S << std::endl;
+ S << '\n';
}
S << "\n"
<< "Display Symbol Location : ";
IGESData_DumpXYZL(S,level, ent->SymbolAttach(), ent->Location());
- S << " Size : " << ent->SymbolSize() << std::endl;
+ S << " Size : " << ent->SymbolSize() << '\n';
}
S << "\n"
<< " Display Symbol : ";
dumper.Dump(ent->DisplaySymbol(),S, (level <= 4) ? 0 : 1);
- S << std::endl;
+ S << '\n';
}
<< "Segment Break Points : ";
IGESData_DumpVals(S,level,1, nbSegments+1,ent->BreakPoint);
if (level <= 4) {
- S << " [ also ask level > 4 for X-Y-Z Polynomials ]" << std::endl;
+ S << " [ also ask level > 4 for X-Y-Z Polynomials ]" << '\n';
return;
}
S << " -- Polynomial Values --\n";
<< " Value "<<AX<<" "<<AY<<" "<<AZ<<"\n"
<< " 1st Derivative "<<BX<<" "<<BY<<" "<<BZ<<"\n"
<< " 2nd Der./2! "<<CX<<" "<<CY<<" "<<CZ<<"\n"
- << " 3rd Der./3! "<<DX<<" "<<DY<<" "<<DZ<<std::endl;
+ << " 3rd Der./3! "<<DX<<" "<<DY<<" "<<DZ<<'\n';
}
S << "\n";
}
}
- else S << std::endl;
+ else S << '\n';
}
dumper.Dump(ent->Generatrix(),S, sublevel);
S << "\n"
<< "Start Angle : " << ent->StartAngle() << " "
- << "End Angle : " << ent->EndAngle() << std::endl;
+ << "End Angle : " << ent->EndAngle() << '\n';
}
S << "\n"
<< "Terminate Point : ";
IGESData_DumpXYZL(S,level, ent->EndPoint(), ent->Location());
- S << std::endl;
+ S << '\n';
}
<< ent->Data(3, 3) << ", " << ent->Data(3, 4) << "\n";
switch (ent->FormNumber()) {
- case 0 : S << "-- Direct Orthogonal Matrix" << std::endl; break;
- case 1 : S << "-- Reverse Orthogonal Matrix" << std::endl; break;
- case 10 : S << "-- Cartesien Coordinate System" << std::endl; break;
- case 11 : S << "-- Cylindrical Coordinate System" << std::endl; break;
- case 12 : S << "-- Spherical Coordinate System" << std::endl; break;
- default : S << "-- (Incorrect Form Number)" << std::endl; break;
+ case 0 : S << "-- Direct Orthogonal Matrix" << '\n'; break;
+ case 1 : S << "-- Reverse Orthogonal Matrix" << '\n'; break;
+ case 10 : S << "-- Cartesien Coordinate System" << '\n'; break;
+ case 11 : S << "-- Cylindrical Coordinate System" << '\n'; break;
+ case 12 : S << "-- Spherical Coordinate System" << '\n'; break;
+ default : S << "-- (Incorrect Form Number)" << '\n'; break;
}
}
S << "\n"
<< "Inner Boundaries : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbInnerContours(),ent->InnerContour);
- S << std::endl;
+ S << '\n';
}
void IGESGeom_TransformationMatrix::SetFormNumber (const Standard_Integer fm)
{
if(theData.IsNull())
- std::cout<<"Inavalid Transformation Data"<<std::endl;
+ std::cout<<"Inavalid Transformation Data"<<'\n';
if ((fm < 0 || fm > 1) && (fm < 10 || fm > 12)) throw Standard_OutOfRange("IGESGeom_TransformationMatrix : SetFormNumber");
InitTypeAndForm(124,fm);
}
<< "Blue (in % Of Full Intensity) : " << Blue << "\n"
<< "Color Name : ";
IGESData_DumpString(S,ent->ColorName());
- S << std::endl;
+ S << '\n';
}
S << "IGESGraph_DefinitionLevel\n"
<< "Level Numbers : ";
IGESData_DumpVals(S,level,1, ent->NbPropertyValues(),ent->LevelNumber);
- S << std::endl;
+ S << '\n';
}
<< "No. of property values : " << ent->NbPropertyValues() << "\n"
<< "Drawing extent along positive X-axis : " << ent->XSize() << "\n"
<< "Drawing extent along positive Y-axis : " << ent->YSize() << "\n"
- << std::endl;
+ << '\n';
}
<< " Units Name : ";
IGESData_DumpString(S,ent->Unit());
S << " computed Value (in meters) : " << ent->UnitValue()
- << std::endl;
+ << '\n';
}
S << "IGESGraph_HighLight\n"
<< "No. of property values : " << ent->NbPropertyValues() << "\n"
<< "Highlight Status : " << ent->HighLightStatus() << "\n"
- << std::endl;
+ << '\n';
}
S << "IGESGraph_IntercharacterSpacing\n"
<< "No. of property values : " << ent->NbPropertyValues() << "\n"
<< "Intercharacter space in % of text height : " << ent->ISpace() << "\n"
- << std::endl;
+ << '\n';
}
for (Standard_Integer I = 1; I <= nb; I ++) {
if (ent->IsVisible(I)) S << " " << I;
}
- S << std::endl;
+ S << '\n';
}
}
S << "\n"
<< "Length Between Successive Template Figure : " << ent->Distance()<< "\n"
<< "Scale Factor for Subfigure : " << ent->Scale() << "\n"
- << std::endl;
+ << '\n';
}
S << "IGESGraph_LineFontPredefined\n"
<< "No. of property values : " << ent->NbPropertyValues() << "\n"
<< "Line font pattern code : " << ent->LineFontPatternCode() << "\n"
- << std::endl;
+ << '\n';
}
S << "\n"
<< "Name of relevant engineering standard : ";
IGESData_DumpString(S,ent->StandardName());
- S << std::endl;
+ S << '\n';
}
<< "No. of property values : " << ent->NbPropertyValues() << "\n"
<< "Pick flag : " << ent->PickFlag()
<< (ent->PickFlag() == 0 ? " NO" : " YES" )
- << std::endl;
+ << '\n';
}
else
S << "Increments from coordinates : ";
IGESData_DumpXYZL(S,level, ent->StartingCorner(), ent->Location());
- S << std::endl;
+ S << '\n';
}
}
}
}
- S << std::endl;
+ S << '\n';
}
IGESData_DumpXY(S, ent->GridSpacing()); S << "\n";
if (ent->IsFinite())
S << "No. of points/lines in direction : X : " << ent->NbPointsX()
- << " - Y : " << ent->NbPointsY() << std::endl;
+ << " - Y : " << ent->NbPointsY() << '\n';
}
" l : liste resumee"<<
" c : liste complete par item (mais pas pour remaining)\n"<<
" r : idem + liste complete remaining\n"<<
- " sur tout le modele. Ajouter nom selection pour lister sur une partie"<<std::endl;
+ " sur tout le modele. Ajouter nom selection pour lister sur une partie"<<'\n';
return (argc >= 0 ? IFSelect_RetError : IFSelect_RetVoid);
}
if (arg1[0] == 'l') {
listmode = 0; std::cout<<"Liste resumee";
}
else if (arg1[0] == 'c') {
- listmode = 1; std::cout<<"Liste complete par item (pas pour Remaining)"<<std::endl;
+ listmode = 1; std::cout<<"Liste complete par item (pas pour Remaining)"<<'\n';
}
else if (arg1[0] == 'r') {
- listmode = 2; std::cout<<"Liste complete par item et pour Remaining"<<std::endl;
+ listmode = 2; std::cout<<"Liste complete par item et pour Remaining"<<'\n';
}
else {
- std::cout<<"Parametre de listage non compris"<<std::endl; return IFSelect_RetError;
+ std::cout<<"Parametre de listage non compris"<<'\n'; return IFSelect_RetError;
}
Handle(IGESSelect_ViewSorter) vs = new IGESSelect_ViewSorter;
// on demande une selection
DeclareAndCast(IFSelect_Selection,sel,WS->NamedItem(arg2));
if (sel.IsNull()) {
- std::cout<<"Pas une selection : "<<arg2<<std::endl;
+ std::cout<<"Pas une selection : "<<arg2<<'\n';
return IFSelect_RetError;
}
vs->AddList (WS->SelectionResult(sel));
if (number == 5) std::cout<<" Views & Drawings";
if (number == 6) std::cout<<" Drawings only (complete)";
if (number == 7) std::cout<<" Single Views & Drawing Frames";
- std::cout<<", on "<<vs->NbEntities()<<" ent.s, give "<<nb<<" Sets"<<std::endl;
+ std::cout<<", on "<<vs->NbEntities()<<" ent.s, give "<<nb<<" Sets"<<'\n';
Interface_EntityIterator iter;
for (Standard_Integer i = 1; i <= nb; i ++) {
std::cout<<" -- Set n0 "<<i<<" Item=entity n0: "<<
WS->Model()->Number(vs->SetItem(i,listdr))<<" List:";
- std::cout<<sets->NbEntities(i)<<" ent.s:"<<std::endl;
+ std::cout<<sets->NbEntities(i)<<" ent.s:"<<'\n';
if (listmode == 0) continue;
iter = sets->Entities(i);
WS->ListEntities (iter, 0, std::cout);
}
std::cout <<" -- Remaining Entities (not yet sorted) :"
- <<sets->NbDuplicated(0,Standard_False)<<std::endl;
+ <<sets->NbDuplicated(0,Standard_False)<<'\n';
if (listmode < 2) return IFSelect_RetVoid;
iter = sets->Duplicated(0,Standard_False);
WS->ListEntities (iter, 0, std::cout);
case 10 : { // **** IGESType (form Type/Form)
if (argc < 2) {
std::cout<<"Donner le n0 de type desire, + en option la forme\n"
- <<" Si pas de forme, prend toutes les formes du type demande"<<std::endl;
+ <<" Si pas de forme, prend toutes les formes du type demande"<<'\n';
return IFSelect_RetError;
}
char signature[20];
case 12 : { // **** IGES Name
if (argc < 2) {
- std::cout<<"Donner un Nom de TextParam pour IGESName"<<std::endl;
+ std::cout<<"Donner un Nom de TextParam pour IGESName"<<'\n';
return IFSelect_RetError;
}
Handle(IGESSelect_SelectName) sel = new IGESSelect_SelectName;
case 14 : { // **** IGES LevelNumber
if (argc < 2) {
- std::cout<<"Donner nom IntParam pour Level"<<std::endl;
+ std::cout<<"Donner nom IntParam pour Level"<<'\n';
return IFSelect_RetError;
}
DeclareAndCast(IFSelect_IntParam,lev,WS->NamedItem(arg1));
if (lev.IsNull()) {
- std::cout<<arg1<<" : pas un IntParam (pour Level)"<<std::endl;
+ std::cout<<arg1<<" : pas un IntParam (pour Level)"<<'\n';
return IFSelect_RetError;
}
Handle(IGESSelect_SelectLevelNumber) sel = new IGESSelect_SelectLevelNumber;
char prem = ' ';
if (argc < 2) prem = '?';
else if (argc == 5) {
- std::cout<<"floatformat tout court donne les formes admises"<<std::endl;
+ std::cout<<"floatformat tout court donne les formes admises"<<'\n';
return IFSelect_RetError;
}
else prem = arg1[0];
if (argc > 4) {
Rmin = Atof(pilot->Word(4).ToCString());
Rmax = Atof(pilot->Word(5).ToCString());
- if (Rmin <= 0 || Rmax <= 0) { std::cout<<"intervalle : donner reels > 0"<<std::endl; return IFSelect_RetError; }
+ if (Rmin <= 0 || Rmax <= 0) { std::cout<<"intervalle : donner reels > 0"<<'\n'; return IFSelect_RetError; }
}
Handle(IGESSelect_FloatFormat) fm = new IGESSelect_FloatFormat;
if (argc == 2) fm->SetDefault(digits);
case 41 : { // **** SetGlobalParameter
if (argc < 3) {
- std::cout<<"Donner entier=n0 param a changer + nom TextParam pour la valeur"<<std::endl;
+ std::cout<<"Donner entier=n0 param a changer + nom TextParam pour la valeur"<<'\n';
return IFSelect_RetError;
}
Standard_Integer numpar = atoi(arg1);
if (numpar <= 0) {
- std::cout<<"Pas un n0 de param global correct:"<<arg1<<std::endl;
+ std::cout<<"Pas un n0 de param global correct:"<<arg1<<'\n';
return IFSelect_RetError;
}
DeclareAndCast(TCollection_HAsciiString,val,WS->NamedItem(arg2));
if (val.IsNull()) {
- std::cout<<"Pas un nom de TextParam:"<<arg2<<std::endl;
+ std::cout<<"Pas un nom de TextParam:"<<arg2<<'\n';
return IFSelect_RetError;
}
Handle(IGESSelect_SetGlobalParameter) mod =
case 60 : { // **** Spline To BSpline
if (argc < 2) {
std::cout<<"Pour SplineToBSpline, donner mode :\n"<<
- " n pour normal, t pour tryC2"<<std::endl;
+ " n pour normal, t pour tryC2"<<'\n';
return IFSelect_RetError;
}
Standard_Boolean tryC2;
else if (arg1[0] == 't' || arg1[0] == 'T')
tryC2 = Standard_True;
else {
- std::cout<<" Mode incorrect : "<<arg1<<std::endl;
+ std::cout<<" Mode incorrect : "<<arg1<<'\n';
return IFSelect_RetError;
}
Handle(IGESSelect_SplineToBSpline) conv =
(Standard_OStream& S) const
{
IFSelect_SignatureList::PrintCount (S);
- S <<" Highest value : " << thehigh << std::endl;
+ S <<" Highest value : " << thehigh << '\n';
if (thenblists > 0) S <<"REMARK for LEVEL LIST : Entities are counted in"
- <<" <LEVEL LIST>\n, and in each Level value of their list"<<std::endl;
+ <<" <LEVEL LIST>\n, and in each Level value of their list"<<'\n';
}
char* pname=(char*) name;
Standard_Integer status = IGESFile_Read (pname,igesmod,prot);
- if (status < 0) sout<<"File not found : "<<name<<std::endl;
- if (status > 0) sout<<"Error when reading file : "<<name<<std::endl;
+ if (status < 0) sout<<"File not found : "<<name<<'\n';
+ if (status > 0) sout<<"Error when reading file : "<<name<<'\n';
if (status == 0) model = igesmod;
else model.Nullify();
return status;
if (aStream.get() == NULL)
{
ctx.CCheck(0)->AddFail("IGES File could not be created");
- sout<<" - IGES File could not be created : " << ctx.FileName() << std::endl; return 0;
+ sout<<" - IGES File could not be created : " << ctx.FileName() << '\n'; return 0;
}
sout<<" IGES File Name : "<<ctx.FileName();
IGESData_IGESWriter VW(igesmod);
VW.SendModel(prot);
sout<<" Write ";
if (themodefnes) VW.WriteMode() = 10;
- Standard_Boolean status = VW.Print (*aStream); sout<<" Done"<<std::endl;
+ Standard_Boolean status = VW.Print (*aStream); sout<<" Done"<<'\n';
errno = 0;
aStream->flush();
status = aStream->good() && status && !errno;
aStream.reset();
if(errno)
- sout << strerror(errno) << std::endl;
+ sout << strerror(errno) << '\n';
return status;
}
Standard_Boolean iserr = model->IsRedefinedContent(num);
Handle(Standard_Transient) con;
if (iserr) con = model->ReportEntity(num)->Content();
- if (entity.IsNull()) { S <<" Null"<<std::endl; return ; }
+ if (entity.IsNull()) { S <<" Null"<<'\n'; return ; }
// On attaque le dump : d abord cas de l Erreur
if (iserr) {
S << " ERRONEOUS, Content, Type cdl : ";
if (!con.IsNull()) S << con->DynamicType()->Name();
- else S << "(undefined)" << std::endl;
+ else S << "(undefined)" << '\n';
igesent = GetCasted(IGESData_IGESEntity,con);
con.Nullify();
Handle(Interface_Check) check = model->ReportEntity(num)->Check();
dump.Dump(igesent,S,level,(level-1)/3);
}
catch (Standard_Failure const&) {
- S << " ** Dump Interrupt **" << std::endl;
+ S << " ** Dump Interrupt **" << '\n';
}
}
IGESData_DumpXYZL(S,level, ent->XAxis(), ent->VectorLocation());
S << "\nZAxis : ";
IGESData_DumpXYZL(S,level, ent->ZAxis(), ent->VectorLocation());
- S << std::endl;
+ S << '\n';
}
IGESData_DumpXYZL(S,level, ent->FaceCenter(), ent->Location());
S << "\nAxis : ";
IGESData_DumpXYZL(S,level, ent->Axis(), ent->VectorLocation());
- S << std::endl;
+ S << '\n';
}
{
S << "Surface is Parametrised - Reference direction :\n";
dumper.Dump(ent->ReferenceDir(),S, sublevel);
- S << std::endl;
+ S << '\n';
}
- else S << "Surface is UnParametrised" << std::endl;
+ else S << "Surface is UnParametrised" << '\n';
}
IGESData_DumpXYZL(S,level, ent->FaceCenter(), ent->Location());
S << "\nAxis : ";
IGESData_DumpXYZL(S,level, ent->Axis(), ent->VectorLocation());
- S << std::endl;
+ S << '\n';
}
{
S << "Surface is Parametrised - Reference direction : ";
dumper.Dump(ent->ReferenceDir(),S, sublevel);
- S << std::endl;
+ S << '\n';
}
- else S << "Surface is UnParametrised" << std::endl;
+ else S << "Surface is UnParametrised" << '\n';
}
default :
break;
}
- S << std::endl;
+ S << '\n';
}
IGESData_DumpXYZL(S,level, ent->XAxis(), ent->VectorLocation());
S << "\nZAxis : ";
IGESData_DumpXYZL(S,level, ent->ZAxis(), ent->VectorLocation());
- S << std::endl;
+ S << '\n';
}
else S << "Outer loop is not present\n";
S << "Loops : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbLoops(),ent->Loop);
- S << std::endl;
+ S << '\n';
}
}
S << " ]";
}
- S << std::endl;
+ S << '\n';
}
S << "Orientation does not agrees with the underlying surface\n";
S << "Void shells :\nOrientation flags : ";
IGESData_DumpEntities(S,dumper,-level,1, ent->NbVoidShells(),ent->VoidShell);
- S << std::endl;
+ S << '\n';
if (level > 4)
{
S << "[\n";
}
S << " ]\n";
}
- S << std::endl;
+ S << '\n';
}
{
S << "Surface is Parametrised - Reference direction : ";
dumper.Dump(ent->ReferenceDir(),S, sublevel);
- S << std::endl;
+ S << '\n';
}
- else S << "Surface is UnParametrised" << std::endl;
+ else S << "Surface is UnParametrised" << '\n';
}
IGESData_DumpXYZL(S,level, ent->XAxis(), ent->VectorLocation());
S << "\nZAxis : ";
IGESData_DumpXYZL(S,level, ent->ZAxis(), ent->VectorLocation());
- S << std::endl;
+ S << '\n';
}
dumper.Dump(ent->Component(),S, (level <= 4) ? 0 : 1);
S << "Selected Point : ";
IGESData_DumpXYZL(S,level, ent->SelectPoint(), ent->Location());
- S << std::endl;
+ S << '\n';
}
else S << "False\n";
}
}
- S << std::endl;
+ S << '\n';
}
S << "\n"
<< "Matrices : ";
IGESData_DumpEntities(S,dumper ,level,1, ent->NbItems(),ent->TransfMatrix);
- S << std::endl;
+ S << '\n';
}
S << "IGESSolid_SolidInstance\n"
<< "Solid entity : ";
dumper.Dump(ent->Entity(),S, (level <= 4) ? 0 : 1);
- S << std::endl;
+ S << '\n';
}
<< "Extrusion length : " << ent->ExtrusionLength() << "\n"
<< "Extrusion direction : ";
IGESData_DumpXYZL(S,level, ent->ExtrusionDirection(), ent->VectorLocation());
- S << std::endl;
+ S << '\n';
}
IGESData_DumpXYZL(S,level, ent->AxisPoint(), ent->Location());
S << "\nAxis direction : ";
IGESData_DumpXYZL(S,level, ent->Axis(), ent->VectorLocation());
- S << std::endl;
+ S << '\n';
}
<< "Radius : " << ent->Radius() << "\n"
<< "Center : ";
IGESData_DumpXYZL(S,level, ent->Center(), ent->Location());
- S << std::endl;
+ S << '\n';
}
S << "\n"
<< "Reference direction : ";
dumper.Dump(ent->ReferenceDir(),S, sublevel);
- S << std::endl;
+ S << '\n';
}
- else S << "Surface is UnParametrised" << std::endl;
+ else S << "Surface is UnParametrised" << '\n';
}
{
S << "Surface is Parametrised - Reference direction : ";
dumper.Dump(ent->ReferenceDir(),S, sublevel);
- S << std::endl;
+ S << '\n';
}
- else S << "Surface is UnParametrised" << std::endl;
+ else S << "Surface is UnParametrised" << '\n';
}
IGESData_DumpXYZL(S,level, ent->AxisPoint(), ent->Location());
S << "\nAxis direction : ";
IGESData_DumpXYZL(S,level, ent->Axis(), ent->VectorLocation());
- S << std::endl;
+ S << '\n';
}
S << "IGESSolid_VertexList\n"
<< "Vertices : ";
IGESData_DumpListXYZL(S,level,1, ent->NbVertices(),ent->Vertex,ent->Location());
- S << std::endl;
+ S << '\n';
}
if (unitfactor != 1.)
{
if ( myTP->TraceLevel() > 2 )
- myTP->Messenger()->SendInfo() << "UnitFactor = "<< unitfactor << std::endl;
+ myTP->Messenger()->SendInfo() << "UnitFactor = "<< unitfactor << '\n';
myUnitFactor = unitfactor;
}
UpdateMinMaxTol();
Standard_Real& ,
Standard_Real& ) const
{
- std::cout << "IntAna_IntQuadQuad::Parameters(...) is not yet implemented" << std::endl;
+ std::cout << "IntAna_IntQuadQuad::Parameters(...) is not yet implemented" << '\n';
}
/*********************************************************************************
math_TrigonometricFunctionRoots Sol(pcc,p2sc,pc,ps,pcte,0.0,2.0*M_PI);
if(!Sol.IsDone()) {
- std::cout << "\n\nmath_TrigonometricFunctionRoots -> NotDone\n\n"<<std::endl;
+ std::cout << "\n\nmath_TrigonometricFunctionRoots -> NotDone\n\n"<<'\n';
done=Standard_False;
return;
}
for(i=1;i<=ni;i++) { Segment(i).Dump(); }
}
else {
- std::cout<<" Intersection NotDone"<<std::endl;
+ std::cout<<" Intersection NotDone"<<'\n';
}
}
}
//================================================================================
void IntCurveSurface_IntersectionPoint::Dump() const {
- std::cout<<"IntersectionPoint: P("<<myP.X()<<","<<myP.Y()<<","<<myP.Z()<<")"<<std::endl;
- std::cout<<" : USurf("<<myUSurf<<") VSurf("<<myVSurf<<") UCurve("<<myUCurv<<")"<<std::endl;
+ std::cout<<"IntersectionPoint: P("<<myP.X()<<","<<myP.Y()<<","<<myP.Z()<<")"<<'\n';
+ std::cout<<" : USurf("<<myUSurf<<") VSurf("<<myVSurf<<") UCurve("<<myUCurv<<")"<<'\n';
std::cout<<" : TransitionOnSurf ";
switch(myTrOnCurv) {
default: std::cout<< " XXXXX ";
}
- std::cout<<std::endl;
+ std::cout<<'\n';
}
}
//================================================================================
void IntCurveSurface_IntersectionSegment::Dump() const {
- std::cout<<"\nIntersectionSegment : "<<std::endl;
+ std::cout<<"\nIntersectionSegment : "<<'\n';
myP1.Dump();
myP2.Dump();
- std::cout<<std::endl;
+ std::cout<<'\n';
}
#include <Standard_Transient.hxx>
void IntPatch_Point::Dump() const {
- std::cout<<"----------- IntPatch_Point : "<<std::endl;
+ std::cout<<"----------- IntPatch_Point : "<<'\n';
Standard_Real u1,v1,u2,v2;
pt.Parameters(u1,v1,u2,v2);
std::cout<<"\n-traline2 : "; DumpTransition(traline2);
std::cout<<" -tra2 : "; DumpTransition(tra2);
}
- std::cout<<std::endl;
+ std::cout<<'\n';
}
std::cout << "\nToler = " << Tolerance();
- std::cout << std::endl;
+ std::cout << '\n';
}
{
static int num=0;
num++;
- std::cout<<"\n#------------- D u m p B o x 2 d ("<<num<<")"<<std::endl;
+ std::cout<<"\n#------------- D u m p B o x 2 d ("<<num<<")"<<'\n';
Bounding().Dump();
- std::cout<<"\n#-----------------------------------------------"<<std::endl;
+ std::cout<<"\n#-----------------------------------------------"<<'\n';
const Standard_Integer nbs = NbSegments();
std::cout<<"\npol2d "<<num<<" "<<nbs<<" ";
- std::cout<<DeflectionOverEstimation()<<std::endl;
+ std::cout<<DeflectionOverEstimation()<<'\n';
gp_Pnt2d P, PF;
for(Standard_Integer i=1;i<=nbs;i++) {
Segment(i,P,PF);
- std::cout<<"pnt2d "<<num<<" "<< P.X()<<" "<<P.Y()<<std::endl;
+ std::cout<<"pnt2d "<<num<<" "<< P.X()<<" "<<P.Y()<<'\n';
}
- std::cout<<"pnt2d "<<num<<" "<< PF.X()<<" "<<PF.Y()<<std::endl;
+ std::cout<<"pnt2d "<<num<<" "<< PF.X()<<" "<<PF.Y()<<'\n';
}
void IntPatch_RLine::Dump(const Standard_Integer theMode) const
{
- std::cout<<" ----------- D u m p I n t P a t c h _ R L i n e -(begin)------"<<std::endl;
+ std::cout<<" ----------- D u m p I n t P a t c h _ R L i n e -(begin)------"<<'\n';
const Standard_Integer aNbPoints = NbPnts();
const Standard_Integer aNbVertex = NbVertex();
std::cout<<"----> IntSurf_PntOn2S : "<<
polr <<", Pnt (" << Vertex(pol).Value().X() << "," <<
Vertex(pol).Value().Y() << "," <<
- Vertex(pol).Value().Z() <<")" <<std::endl;
+ Vertex(pol).Value().Z() <<")" <<'\n';
}
}
break;
}
- std::cout<<"\n--------------------------------------------------- (end) -------"<<std::endl;
+ std::cout<<"\n--------------------------------------------------- (end) -------"<<'\n';
}
static int debug_polygon2d =0;
if(debug_polygon2d) {
- std::cout<<" ***** Numero Restriction : "<<NumeroEdge<<" *****"<<std::endl;
+ std::cout<<" ***** Numero Restriction : "<<NumeroEdge<<" *****"<<'\n';
PLin.Dump();
Brise.Dump();
}
void IntPatch_WLine::Dump(const Standard_Integer theMode) const
{
- std::cout<<" ----------- D u m p I n t P a t c h _ W L i n e -(begin)------"<<std::endl;
+ std::cout<<" ----------- D u m p I n t P a t c h _ W L i n e -(begin)------"<<'\n';
const Standard_Integer aNbPoints = NbPnts();
const Standard_Integer aNbVertex = NbVertex();
std::cout<<"----> IntSurf_PntOn2S : "<<
polr <<", Pnt (" << Vertex(pol).Value().X() << "," <<
Vertex(pol).Value().Y() << "," <<
- Vertex(pol).Value().Z() <<")" <<std::endl;
+ Vertex(pol).Value().Z() <<")" <<'\n';
}
}
break;
}
- std::cout<<"\n--------------------------------------------------- (end) -------"<<std::endl;
+ std::cout<<"\n--------------------------------------------------- (end) -------"<<'\n';
}
// mesnum = mesnum0;
// if (yamod) mesnum = (nm0 > 0 ? mesnum1 : mesnum2);
- if (!titre) S <<" ** " << Name() << " **"<<std::endl;
+ if (!titre) S <<" ** " << Name() << " **"<<'\n';
titre = Standard_True;
S <<"Check:"; if(nb > 9 && i < 10) S <<" "; if (nb > 99 && i < 100) S <<" ";
S <<i;
- if (num < 0) S <<" -- Global Check"<<std::endl;
+ if (num < 0) S <<" -- Global Check"<<'\n';
else if (num == 0) S <<" -- Entity n0 ??:";
else {
if (yamod) { S <<" -- Entity (n0:id) "; model->Print (ent, S); }
// S<<" -- Entity n0 "<<num<<mesnum;
// if (yamod) model->PrintLabel(ent,S);
}
- if (num >= 0 && entnul) S <<" (unknown Type)"<<std::endl;
+ if (num >= 0 && entnul) S <<" (unknown Type)"<<'\n';
else if (num >= 0 && !entnul) {
- if (yamod) S <<" Type:"<<model->TypeName(ent)<<std::endl;
- else S <<" Type:"<<ent->DynamicType()->Name()<<std::endl;
+ if (yamod) S <<" Type:"<<model->TypeName(ent)<<'\n';
+ else S <<" Type:"<<ent->DynamicType()->Name()<<'\n';
}
ach->Print (S, (failsonly ? 1 : 3));
{
Standard_Integer nb = 0;
if (thedic.IsEmpty()) return nb;
- if (rootkey[0] != '\0') S<<"@@ ROOT:"<<rootkey<<std::endl;
+ if (rootkey[0] != '\0') S<<"@@ ROOT:"<<rootkey<<'\n';
NCollection_DataMap<TCollection_AsciiString, Handle(TCollection_HAsciiString)>::Iterator iter(thedic);
for (; iter.More(); iter.Next()) {
if (!iter.Key().StartsWith(rootkey)) continue;
if (thedic.Find(key, str))
return str->ToCString();
}
- if (theprint) std::cout<<" ** Interface_MSG:Translate ?? "<<key<<" **"<<std::endl;
+ if (theprint) std::cout<<" ** Interface_MSG:Translate ?? "<<key<<" **"<<'\n';
if (therec) {
if (thelist.IsBound(key)) {
thelist.ChangeFind(key)++;
thedic.Bind(key,str);
return;
}
- if (theprint) std::cout<<" ** Interface_MSG:Record ?? "<<key<<" ** "<<item<<" **"<<std::endl;
+ if (theprint) std::cout<<" ** Interface_MSG:Record ?? "<<key<<" ** "<<item<<" **"<<'\n';
if (therec) {
if (thedup.IsNull()) thedup = new TColStd_HSequenceOfHAsciiString();
dup = new TCollection_HAsciiString(key);
dup = thedup->Value(2*i-1);
S<<"** DUP:"<<dup->ToCString();
dup = thedup->Value(2*i);
- S<<" ** "<<dup->ToCString()<<std::endl;
+ S<<" ** "<<dup->ToCString()<<'\n';
}
if (thelist.IsEmpty()) return;
NCollection_DataMap<TCollection_AsciiString, Standard_Integer>::Iterator iter(thelist);
for (; iter.More(); iter.Next()) {
- S<<"** MSG(NB="<<iter.Value()<<"): "<<iter.Key()<<std::endl;
+ S<<"** MSG(NB="<<iter.Value()<<"): "<<iter.Key()<<'\n';
}
}
S << " n0/id:";
Model()->Print (ent, S);
}
- S <<std::endl;
+ S <<'\n';
}
S <<"--- Static Value : "<<Name()<<" Family:"<<Family();
Print (S);
if (!thewild.IsNull())
- S <<" -- Attached to wild-card : "<<thewild->Name()<<std::endl;
+ S <<" -- Attached to wild-card : "<<thewild->Name()<<'\n';
S <<"--- Actual status : "<<(theupdate ? "" : "original")<<" Value : ";
- if (thesatisf) S <<" -- Specific Function for Satisfies : "<<thesatisn.ToCString()<<std::endl;
+ if (thesatisf) S <<" -- Specific Function for Satisfies : "<<thesatisn.ToCString()<<'\n';
}
//----------------------------------------------------
void Intf_Interference::Dump() const
{
- std::cout << "Mes SectionPoint :" << std::endl;
+ std::cout << "Mes SectionPoint :" << '\n';
for (Standard_Integer p=1; p<=mySPoins.Length(); p++) {
mySPoins(p).Dump(2);
}
- std::cout << "Mes SectionLine :" << std::endl;
+ std::cout << "Mes SectionLine :" << '\n';
for (Standard_Integer l=1; l<=mySLines.Length(); l++) {
mySLines(l).Dump(2);
}
- std::cout << "Mes TangentZone :" << std::endl;
+ std::cout << "Mes TangentZone :" << '\n';
for (Standard_Integer t=1; t<=myTZones.Length(); t++) {
myTZones(t).Dump(2);
}
{
for (Standard_Integer id=0; id<Indent; id++) std::cout << " ";
std::cout << "LS ";
- if (IsClosed()) std::cout << "Closed :" << std::endl;
- else std::cout << "Open :" << std::endl;
+ if (IsClosed()) std::cout << "Closed :" << '\n';
+ else std::cout << "Open :" << '\n';
for (Standard_Integer p=1; p<=myPoints.Length(); p++) {
myPoints.Value(p).Dump(Indent+2);
}
default:
#ifndef _MSC_VER
std::cerr << "Unrecognized node type = "
- << (long)theNode.getNodeType() << std::endl
+ << (long)theNode.getNodeType() << '\n'
#endif
; }
}
}
if (!FinS) {
- std::cout << "LocOpe_SplitDrafts:!Fins throw Standard_ConstructionError()" << std::endl;
+ std::cout << "LocOpe_SplitDrafts:!Fins throw Standard_ConstructionError()" << '\n';
throw Standard_ConstructionError();
}
}
}
if (!itl.More()) {
- std::cout << "LocOpe_SplitDrafts: betite probleme "<< std::endl;
+ std::cout << "LocOpe_SplitDrafts: betite probleme "<< '\n';
return;
}
}
}
}
- std::cout << "fin newplane return standard_false" << std::endl;
+ std::cout << "fin newplane return standard_false" << '\n';
return Standard_False;
}
}
}
if (C2d.IsNull()) {
- std::cout << "Ca merde violemment" << std::endl;
+ std::cout << "Ca merde violemment" << '\n';
}
}
}
B.Add(F,lwires.First());
}
else {
- std::cout << "Not yet implemented : nbwire >= 2" << std::endl;
+ std::cout << "Not yet implemented : nbwire >= 2" << '\n';
}
}
}
//MODIFICATION PIERRE SMEYERS : si pas de possibilite, on sort avec erreur
else{
- std::cout<<"erreur Spliter : pas de chainage du wire"<<std::endl;
+ std::cout<<"erreur Spliter : pas de chainage du wire"<<'\n';
return Standard_False;
}
//fin MODIF.
else {
// Ce wire est ni dans newF2 ni dans newF1
// Peut etre faut il construire une troisieme face
- std::cout << "WARNING: LocOpe_SPlitShape : Ce wire est ni dans newF2 ni dans newF1" << std::endl;
+ std::cout << "WARNING: LocOpe_SPlitShape : Ce wire est ni dans newF2 ni dans newF1" << '\n';
}
}
}
/*********************************************************************************/
void LocalAnalysis::Dump(const LocalAnalysis_SurfaceContinuity& surfconti, Standard_OStream& o)
{ if (!surfconti.IsDone())
- { o<<"Problem in the computation "<<std::endl;
+ { o<<"Problem in the computation "<<'\n';
if (surfconti.StatusError()==LocalAnalysis_NullFirstDerivative)
- o<<"one of the first derivatives is null" <<std::endl;
+ o<<"one of the first derivatives is null" <<'\n';
else if(surfconti.StatusError()==LocalAnalysis_NullSecondDerivative)
- o<<"one of the second derivatives is null" <<std::endl;
+ o<<"one of the second derivatives is null" <<'\n';
else if(surfconti.StatusError()==LocalAnalysis_NormalNotDefined)
- o<<"one (or both) normal is undefined" <<std::endl;
+ o<<"one (or both) normal is undefined" <<'\n';
else if(surfconti.StatusError()==LocalAnalysis_CurvatureNotDefined)
- o<<"one of the mean curvatures is undefined" <<std::endl; }
+ o<<"one of the mean curvatures is undefined" <<'\n'; }
else
switch(surfconti.ContinuityStatus())
{ case GeomAbs_C0 :{ if (surfconti.IsC0() )
- o<<" Continuity Status : C0 " <<std::endl;
- else o<<" Continuity Status : No C0 "<<std::endl;
- o<<" C0Value = "<<surfconti.C0Value() <<std::endl;
+ o<<" Continuity Status : C0 " <<'\n';
+ else o<<" Continuity Status : No C0 "<<'\n';
+ o<<" C0Value = "<<surfconti.C0Value() <<'\n';
} break;
case GeomAbs_C1 :{ if (surfconti.IsC1())
- o<<" Continuity Status : C1 " <<std::endl;
+ o<<" Continuity Status : C1 " <<'\n';
else
{if (surfconti.IsC0() )
- o<<" Continuity Status : C0 " <<std::endl;
- else o<<" Continuity Status : NoC0 "<<std::endl;
+ o<<" Continuity Status : C0 " <<'\n';
+ else o<<" Continuity Status : NoC0 "<<'\n';
}
- o<<" C0Value = "<<surfconti.C0Value()<<std::endl;
- o<<" C1UAngle = "<<surfconti.C1UAngle()<<std::endl;
- o<<" C1URatio = "<<surfconti.C1URatio()<<std::endl;
- o<<" C1VAngle = "<<surfconti.C1VAngle()<<std::endl;
- o<<" C1VRatio = "<<surfconti.C1VRatio()<<std::endl;
+ o<<" C0Value = "<<surfconti.C0Value()<<'\n';
+ o<<" C1UAngle = "<<surfconti.C1UAngle()<<'\n';
+ o<<" C1URatio = "<<surfconti.C1URatio()<<'\n';
+ o<<" C1VAngle = "<<surfconti.C1VAngle()<<'\n';
+ o<<" C1VRatio = "<<surfconti.C1VRatio()<<'\n';
} break;
case GeomAbs_C2 :{ if (surfconti.IsC2())
- o<<" Continuity Status : C2 " <<std::endl;
+ o<<" Continuity Status : C2 " <<'\n';
else
{if (surfconti.IsC1() )
- o<<" Continuity Status : C1 " <<std::endl;
+ o<<" Continuity Status : C1 " <<'\n';
else
{ if (surfconti.IsC0() )
- o<<" Continuity Status : C0 " <<std::endl;
- else o<<" Continuity Status : NoC0 "<<std::endl;}
+ o<<" Continuity Status : C0 " <<'\n';
+ else o<<" Continuity Status : NoC0 "<<'\n';}
}
- o<<" C0Value = "<<surfconti.C0Value()<<std::endl;
- o<<" C1UAngle = "<<surfconti.C1UAngle()<<std::endl;
- o<<" C1VAngle = "<<surfconti.C1VAngle()<<std::endl;
- o<<" C2UAngle = "<<surfconti.C2UAngle()<<std::endl;
- o<<" C2VAngle = "<<surfconti.C2VAngle()<<std::endl;
- o<<" C1URatio = "<<surfconti.C1URatio()<<std::endl;
- o<<" C1VRatio = "<<surfconti.C1VRatio()<<std::endl;
- o<<" C2URatio = "<<surfconti.C2URatio()<<std::endl;
- o<<" C2VRatio = "<<surfconti.C2VRatio()<<std::endl;
+ o<<" C0Value = "<<surfconti.C0Value()<<'\n';
+ o<<" C1UAngle = "<<surfconti.C1UAngle()<<'\n';
+ o<<" C1VAngle = "<<surfconti.C1VAngle()<<'\n';
+ o<<" C2UAngle = "<<surfconti.C2UAngle()<<'\n';
+ o<<" C2VAngle = "<<surfconti.C2VAngle()<<'\n';
+ o<<" C1URatio = "<<surfconti.C1URatio()<<'\n';
+ o<<" C1VRatio = "<<surfconti.C1VRatio()<<'\n';
+ o<<" C2URatio = "<<surfconti.C2URatio()<<'\n';
+ o<<" C2VRatio = "<<surfconti.C2VRatio()<<'\n';
} break;
case GeomAbs_G1 :{ if (surfconti.IsG1())
- o<<" Continuity Status : G1 " <<std::endl;
+ o<<" Continuity Status : G1 " <<'\n';
else
{if (surfconti.IsC0() )
- o<<" Continuity Status : G0 " <<std::endl;
- else o<<" Continuity Status : NoG0 "<<std::endl;
+ o<<" Continuity Status : G0 " <<'\n';
+ else o<<" Continuity Status : NoG0 "<<'\n';
}
- o<<" G0Value = "<<surfconti.C0Value()<<std::endl;
- o<<" G1Angle = "<<surfconti.G1Angle()<<std::endl<<std::endl;
+ o<<" G0Value = "<<surfconti.C0Value()<<'\n';
+ o<<" G1Angle = "<<surfconti.G1Angle()<<'\n'<<'\n';
} break;
case GeomAbs_G2 :{ if (surfconti.IsG2())
- o<<" Continuity Status : G2 " <<std::endl;
+ o<<" Continuity Status : G2 " <<'\n';
else
{if (surfconti.IsG1() )
- o<<" Continuity Status : G1 " <<std::endl;
+ o<<" Continuity Status : G1 " <<'\n';
else
{ if (surfconti.IsC0() )
- o<<" Continuity Status : G0 " <<std::endl;
- else o<<" Continuity Status : NoG0 "<<std::endl;}
+ o<<" Continuity Status : G0 " <<'\n';
+ else o<<" Continuity Status : NoG0 "<<'\n';}
}
- o<<" G0Value = "<<surfconti.C0Value()<<std::endl;
- o<<" G1Value = "<<surfconti.G1Angle()<<std::endl;
- o<<" G2CurvatureGap = "<<surfconti.G2CurvatureGap()<<std::endl;
+ o<<" G0Value = "<<surfconti.C0Value()<<'\n';
+ o<<" G1Value = "<<surfconti.G1Angle()<<'\n';
+ o<<" G2CurvatureGap = "<<surfconti.G2CurvatureGap()<<'\n';
} break;
default : {}
void LocalAnalysis::Dump(const LocalAnalysis_CurveContinuity& curvconti, Standard_OStream& o)
{ if (!curvconti.IsDone())
- { o<<"Problem in the computation "<<std::endl;
+ { o<<"Problem in the computation "<<'\n';
if (curvconti.StatusError()==LocalAnalysis_NullFirstDerivative)
- o<<"one (or both) first derivative is null" <<std::endl;
+ o<<"one (or both) first derivative is null" <<'\n';
else if(curvconti.StatusError()==LocalAnalysis_NullSecondDerivative)
- o<<"one (or both) second derivative is null" <<std::endl;
+ o<<"one (or both) second derivative is null" <<'\n';
else if(curvconti.StatusError()==LocalAnalysis_TangentNotDefined)
- o<<"one (or both) tangent is undefined " <<std::endl;
+ o<<"one (or both) tangent is undefined " <<'\n';
else if(curvconti.StatusError()==LocalAnalysis_NormalNotDefined)
- o<<"one (or both) normal is undefined" <<std::endl;}
+ o<<"one (or both) normal is undefined" <<'\n';}
else
switch(curvconti.ContinuityStatus())
{ case GeomAbs_C0 :{ if (curvconti.IsC0() )
- o<<" Continuity Status : C0 " <<std::endl;
- else o<<" Continuity Status : No C0 "<<std::endl;
- o<<" C0Value = "<<curvconti.C0Value() <<std::endl;
+ o<<" Continuity Status : C0 " <<'\n';
+ else o<<" Continuity Status : No C0 "<<'\n';
+ o<<" C0Value = "<<curvconti.C0Value() <<'\n';
} break;
case GeomAbs_C1 :{ if (curvconti.IsC1())
- o<<" Continuity Status : C1 " <<std::endl;
+ o<<" Continuity Status : C1 " <<'\n';
else
{if (curvconti.IsC0() )
- o<<" Continuity Status : C0 " <<std::endl;
- else o<<" Continuity Status : NoC0 "<<std::endl;
+ o<<" Continuity Status : C0 " <<'\n';
+ else o<<" Continuity Status : NoC0 "<<'\n';
}
- o<<" C0Value = "<<curvconti.C0Value()<<std::endl;
- o<<" C1Angle = "<<curvconti.C1Angle()<<std::endl;
- o<<" C1Ratio = "<<curvconti.C1Ratio()<<std::endl;
+ o<<" C0Value = "<<curvconti.C0Value()<<'\n';
+ o<<" C1Angle = "<<curvconti.C1Angle()<<'\n';
+ o<<" C1Ratio = "<<curvconti.C1Ratio()<<'\n';
} break;
case GeomAbs_C2 :{ if (curvconti.IsC2())
- o<<" Continuity Status : C2 " <<std::endl;
+ o<<" Continuity Status : C2 " <<'\n';
else
{if (curvconti.IsC1() )
- o<<" Continuity Status : C1 " <<std::endl;
+ o<<" Continuity Status : C1 " <<'\n';
else
{ if (curvconti.IsC0() )
- o<<" Continuity Status : C0 " <<std::endl;
- else o<<" Continuity Status : NoC0 "<<std::endl;}
+ o<<" Continuity Status : C0 " <<'\n';
+ else o<<" Continuity Status : NoC0 "<<'\n';}
}
- o<<" C0Value = "<<curvconti.C0Value()<<std::endl;
- o<<" C1Angle = "<<curvconti.C1Angle()<<std::endl;
- o<<" C2Angle = "<<curvconti.C2Angle()<<std::endl;
- o<<" C1Ratio = "<<curvconti.C1Ratio()<<std::endl;
- o<<" C2Ratio = "<<curvconti.C2Ratio()<<std::endl;
+ o<<" C0Value = "<<curvconti.C0Value()<<'\n';
+ o<<" C1Angle = "<<curvconti.C1Angle()<<'\n';
+ o<<" C2Angle = "<<curvconti.C2Angle()<<'\n';
+ o<<" C1Ratio = "<<curvconti.C1Ratio()<<'\n';
+ o<<" C2Ratio = "<<curvconti.C2Ratio()<<'\n';
}break;
case GeomAbs_G1 :{ if (curvconti.IsG1())
- o<<" Continuity Status : G1 " <<std::endl;
+ o<<" Continuity Status : G1 " <<'\n';
else
{if (curvconti.IsC0() )
- o<<" Continuity Status : G0 " <<std::endl;
- else o<<" Continuity Status : NoG0 "<<std::endl;
+ o<<" Continuity Status : G0 " <<'\n';
+ else o<<" Continuity Status : NoG0 "<<'\n';
}
- o<<" G0Value = "<<curvconti.C0Value()<<std::endl;
- o<<" G1Angle = "<<curvconti.G1Angle()<<std::endl;
+ o<<" G0Value = "<<curvconti.C0Value()<<'\n';
+ o<<" G1Angle = "<<curvconti.G1Angle()<<'\n';
} break;
case GeomAbs_G2 :{ if (curvconti.IsG2())
- o<<" Continuity Status : G2 " <<std::endl;
+ o<<" Continuity Status : G2 " <<'\n';
else
{if (curvconti.IsG1() )
- o<<" Continuity Status : G1 " <<std::endl;
+ o<<" Continuity Status : G1 " <<'\n';
else
{ if (curvconti.IsC0() )
- o<<" Continuity Status : G0 " <<std::endl;
- else o<<" Continuity Status : NoG0 "<<std::endl;}
+ o<<" Continuity Status : G0 " <<'\n';
+ else o<<" Continuity Status : NoG0 "<<'\n';}
}
- o<<" G0Value = "<<curvconti.C0Value()<<std::endl;
- o<<" G1Angle = "<<curvconti.G1Angle()<<std::endl;
- o<<" G2Angle = "<<curvconti.G2Angle()<<std::endl;
- o<<" Relative curvature variation = "<<curvconti.G2CurvatureVariation()<<std::endl;
+ o<<" G0Value = "<<curvconti.C0Value()<<'\n';
+ o<<" G1Angle = "<<curvconti.G1Angle()<<'\n';
+ o<<" G2Angle = "<<curvconti.G2Angle()<<'\n';
+ o<<" Relative curvature variation = "<<curvconti.G2CurvatureVariation()<<'\n';
} break;
Standard_Integer i;
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" BISECTOR : "<<thebisectornumber<<std::endl;
+ std::cout<<" BISECTOR : "<<thebisectornumber<<'\n';
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" First edge : "<<thefirstedge->EdgeNumber()<<std::endl;
+ std::cout<<" First edge : "<<thefirstedge->EdgeNumber()<<'\n';
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" Second edge : "<<thesecondedge->EdgeNumber()<<std::endl;
+ std::cout<<" Second edge : "<<thesecondedge->EdgeNumber()<<'\n';
for(i=0; i<ashift; i++)std::cout<<" ";
if(alevel)
{
if(!thelistofbisectors->More())
{
- std::cout<<" Bisectors List : "<<std::endl;
+ std::cout<<" Bisectors List : "<<'\n';
thelistofbisectors->Dump(ashift+1,1);
}
}
- std::cout<<std::endl;
+ std::cout<<'\n';
}
{
Standard_Integer MyOffset = Offset;
Indent (Offset);
- std::cout<<"MAT2d_Connexion :"<<std::endl;
+ std::cout<<"MAT2d_Connexion :"<<'\n';
MyOffset++;
Indent (MyOffset);
- std::cout <<"IndexFirstLine :"<<lineA<<std::endl;
+ std::cout <<"IndexFirstLine :"<<lineA<<'\n';
Indent (MyOffset);
- std::cout <<"IndexSecondLine :"<<lineB<<std::endl;
+ std::cout <<"IndexSecondLine :"<<lineB<<'\n';
Indent (MyOffset);
- std::cout <<"IndexItemOnFirst :"<<itemA<<std::endl;
+ std::cout <<"IndexItemOnFirst :"<<itemA<<'\n';
Indent (MyOffset);
- std::cout <<"IndexItemOnSecond :"<<itemB<<std::endl;
+ std::cout <<"IndexItemOnSecond :"<<itemB<<'\n';
Indent (MyOffset);
- std::cout <<"ParameterOnFirst :"<<parameterOnA<<std::endl;
+ std::cout <<"ParameterOnFirst :"<<parameterOnA<<'\n';
Indent (MyOffset);
- std::cout <<"ParameterOnSecond :"<<parameterOnB<<std::endl;
+ std::cout <<"ParameterOnSecond :"<<parameterOnB<<'\n';
Indent (MyOffset);
- std::cout <<"PointOnFirst :"<<std::endl;
- std::cout <<" X = "<<pointA.X()<<std::endl;
- std::cout <<" Y = "<<pointA.Y()<<std::endl;
+ std::cout <<"PointOnFirst :"<<'\n';
+ std::cout <<" X = "<<pointA.X()<<'\n';
+ std::cout <<" Y = "<<pointA.Y()<<'\n';
Indent (MyOffset);
- std::cout <<"PointOnSecond :"<<std::endl;
- std::cout <<" X = "<<pointB.X()<<std::endl;
- std::cout <<" Y = "<<pointB.Y()<<std::endl;
+ std::cout <<"PointOnSecond :"<<'\n';
+ std::cout <<" X = "<<pointB.X()<<'\n';
+ std::cout <<" Y = "<<pointB.Y()<<'\n';
Indent (MyOffset);
- std::cout <<"Distance :"<<distance<<std::endl;
+ std::cout <<"Distance :"<<distance<<'\n';
}
if (aMeshData.IsNull())
return "Null mesh data structure";
Standard_Integer nbLinks = aMeshData->NbLinks();
- std::cout << "nblink=" << nbLinks << std::endl;
+ std::cout << "nblink=" << nbLinks << '\n';
TCollection_AsciiString aName(theNameStr);
for (Standard_Integer i = 1; i <= nbLinks; i++)
{
if (aMeshData.IsNull())
return "Null mesh data structure";
Standard_Integer nbElem = aMeshData->NbElements();
- std::cout << "nbelem=" << nbElem << std::endl;
+ std::cout << "nbelem=" << nbElem << '\n';
TCollection_AsciiString aName(theNameStr);
for (Standard_Integer i = 1; i <= nbElem; i++)
{
TopLoc_Location aLoc;
Handle(Poly_Triangulation) aPoly = BRep_Tool::Triangulation(aFace,aLoc);
if (aPoly.IsNull()) {
- std::cout << "face "<<i<<" has no triangulation"<<std::endl;
+ std::cout << "face "<<i<<" has no triangulation"<<'\n';
continue;
}
for (int j = 1; j <= aPoly->NbTriangles(); j++)
{
*aStream << theString;
}
- (*aStream) << std::endl;
+ (*aStream) << '\n';
}
//=======================================================================
const Message_ListOfAlert& anAlerts = theCompositeAlert->Alerts (theGravity);
for (Message_ListOfAlert::Iterator anIt (anAlerts); anIt.More(); anIt.Next())
{
- theOS << anIt.Value()->GetMessageKey() << std::endl;
+ theOS << anIt.Value()->GetMessageKey() << '\n';
Handle(Message_AlertExtended) anExtendedAlert = Handle(Message_AlertExtended)::DownCast (anIt.Value());
if (anExtendedAlert.IsNull())
Sprintf ( buff, "Elapsed:%6.1f sec, CPU User:%9.4f sec, CPU Sys:%9.4f sec, hits: %d",
elapsed, user, system, myCount );
- ostr << buff << std::endl;
+ ostr << buff << '\n';
}
//=======================================================================
Standard_Integer NbTimers = dic.Extent();
- ostr << "DUMP OF TIMERS:" << std::endl;
+ ostr << "DUMP OF TIMERS:" << '\n';
Standard_CString *keys = new Standard_CString[NbTimers];
Standard_Integer i=0;
for( ; iter.More() && i < NbTimers; iter.Next()) {
//iter.Value()->Dump ( ostr );
Timer(stmp)->Dump(ostr);
keys[ntmp]=0;
- if ( Timer(stmp)->IsRunning() ) std::cerr << "Warning: timer " << stmp << " is running" << std::endl;
+ if ( Timer(stmp)->IsRunning() ) std::cerr << "Warning: timer " << stmp << " is running" << '\n';
}
delete[] keys;
}
amAccess += ( 0.5 * ( cpu3 - cpu1 ) ) / NBTESTS;
amError = Abs ( cpu1 + cpu3 - 2 * cpu2 ) / NBTESTS;
- std::cout << "CPU 0: " << cpu0 << std::endl;
- std::cout << "CPU 1: " << cpu1 << " INTERNAL: " << cput1 << std::endl;
- std::cout << "CPU 2: " << cpu2 << " INTERNAL: " << cput2 << std::endl;
- std::cout << "CPU 3: " << cpu3 << " INTERNAL: " << cput3 << std::endl;
+ std::cout << "CPU 0: " << cpu0 << '\n';
+ std::cout << "CPU 1: " << cpu1 << " INTERNAL: " << cput1 << '\n';
+ std::cout << "CPU 2: " << cpu2 << " INTERNAL: " << cput2 << '\n';
+ std::cout << "CPU 3: " << cpu3 << " INTERNAL: " << cput3 << '\n';
std::cout << "Access: " << amAccess << ", External: " << amExternal <<
- ", Internal: " << amInternal << ", Error: " << amError << std::endl;
+ ", Internal: " << amInternal << ", Error: " << amError << '\n';
}
{
S <<"--- Typed Value : "<<Name();
if (thelabel.Length() > 0) S <<" Label : "<<Label();
- S <<std::endl<<"--- Type : "<<Definition()<<std::endl<<"--- Value : ";
+ S <<'\n'<<"--- Type : "<<Definition()<<'\n'<<"--- Value : ";
PrintValue (S);
- S <<std::endl;
+ S <<'\n';
- if (thesatisf) S <<" -- Specific Function for Satisfies : "<<thesatisn.ToCString()<<std::endl;
+ if (thesatisf) S <<" -- Specific Function for Satisfies : "<<thesatisn.ToCString()<<'\n';
}
<< std::setw(10) << "NbLeftPeak "
<< std::setw(20) << "AllocSize "
<< std::setw(20) << "LeftSize "
- << std::setw(20) << "PeakSize " << std::endl;
+ << std::setw(20) << "PeakSize " << '\n';
Standard_Size aTotAlloc = 0;
for (std::set<StorageInfo>::const_iterator it = aStMap.begin();
<< std::setw(10) << aInfo.nbLeftPeak << ' '
<< std::setw(20) << aSizeAlloc << ' '
<< std::setw(20) << aSizeLeft << ' '
- << std::setw(20) << aSizePeak << std::endl;
+ << std::setw(20) << aSizePeak << '\n';
if (aTotAlloc + aSizeAlloc < aTotAlloc) // overflow ?
aTotAlloc = SIZE_MAX;
<< (aTotAlloc == SIZE_MAX ? '>' : ' ')
<< std::setw(20) << aTotAlloc << ' '
<< std::setw(20) << aTotalLeftSize << ' '
- << std::setw(20) << aTotalPeakSize << std::endl;
+ << std::setw(20) << aTotalPeakSize << '\n';
aRepFile.close();
return Standard_True;
{
myMutex.Lock();
myLogFile << "alloc "<< std::setw(10) << theRequestNum
- << std::setw(20) << theSize << std::endl;
+ << std::setw(20) << theSize << '\n';
if (myBreakSize == theSize)
place_for_breakpoint();
myMutex.Unlock();
{
myMutex.Lock();
myLogFile << "free " << std::setw(20) << theRequestNum
- << std::setw(20) << theSize << std::endl;
+ << std::setw(20) << theSize << '\n';
myMutex.Unlock();
}
}
<< std::setw(10) << "NbLeftPeak "
<< std::setw(20) << "AllocSize "
<< std::setw(20) << "LeftSize "
- << std::setw(20) << "PeakSize " << std::endl;
+ << std::setw(20) << "PeakSize " << '\n';
Standard_Size aTotAlloc = 0;
for (int i = 0; i < MAX_ALLOC_SIZE; i++)
<< std::setw(10) << myArray[i].nbLeftPeak << ' '
<< std::setw(20) << aSizeAlloc << ' '
<< std::setw(20) << aSizeLeft << ' '
- << std::setw(20) << aSizePeak << std::endl;
+ << std::setw(20) << aSizePeak << '\n';
if (aTotAlloc + aSizeAlloc < aTotAlloc) // overflow ?
aTotAlloc = SIZE_MAX;
<< (aTotAlloc == SIZE_MAX ? '>' : ' ')
<< std::setw(20) << aTotAlloc << ' '
<< std::setw(20) << myTotalLeftSize << ' '
- << std::setw(20) << myTotalPeakSize << std::endl;
+ << std::setw(20) << myTotalPeakSize << '\n';
aRepFile.close();
return Standard_True;
}
sigemptyset(&anActOld2.sa_mask);
retcode = sigaction (aSignalTypes[i], &anActOld, &anActOld2);
}
- Standard_ASSERT(retcode == 0, "sigaction() failed", std::cout << "OSD::SetSignal(): sigaction() failed for " << aSignalTypes[i] << std::endl);
+ Standard_ASSERT(retcode == 0, "sigaction() failed", std::cout << "OSD::SetSignal(): sigaction() failed for " << aSignalTypes[i] << '\n');
}
}
if(!PluginResource->Find(theResource.ToCString())) {
Standard_SStream aMsg; aMsg << "could not find the resource:";
- aMsg << theResource.ToCString() << std::endl;
+ aMsg << theResource.ToCString() << '\n';
if (theVerbose)
- std::cout << "could not find the resource:" << theResource.ToCString() << std::endl;
+ std::cout << "could not find the resource:" << theResource.ToCString() << '\n';
throw Plugin_Failure(aMsg.str().c_str());
}
aMsg << "; reason:";
aMsg << error.ToCString();
if (theVerbose)
- std::cout << "could not open: " << PluginResource->Value(theResource.ToCString())<< " ; reason: "<< error.ToCString() << std::endl;
+ std::cout << "could not open: " << PluginResource->Value(theResource.ToCString())<< " ; reason: "<< error.ToCString() << '\n';
throw Plugin_Failure(aMsg.str().c_str());
}
f = theSharedLibrary.DlSymb("PLUGINFACTORY");
{
char buf[256];
Sprintf (buf, " X =%9.4f; Y =%9.4f; Z =%9.4f", X(), Y(), Z());
- theStream << buf << std::endl;
+ theStream << buf << '\n';
Poly_CoherentTriPtr::Iterator anIter(* myTriangles);
for (; anIter.More(); anIter.Next()) {
const Poly_CoherentTriangle& aTri = anIter.Value();
Sprintf (buf, " %5d %5d %5d", aTri.Node(0),aTri.Node(1),aTri.Node(2));
- theStream << buf << std::endl;
+ theStream << buf << '\n';
}
}
}
}
if ( Index == 0 ) {
- std::cout << " Extrema non trouve pour U = " << U << std::endl;
+ std::cout << " Extrema non trouve pour U = " << U << '\n';
return gp_Pnt(0.,0.,0.);
}
else {
}
catch (Standard_Failure const& anException) {
std::cout << "Caught successfully: ";
- std::cout << anException << std::endl;
+ std::cout << anException << '\n';
}
return 0;
}
{//==== Test Divide ByZero (Integer) ========================================
try{
OCC_CATCH_SIGNALS
- std::cout << "(Integer) Divide By Zero..." << std::endl;
+ std::cout << "(Integer) Divide By Zero..." << '\n';
di << "(Integer) Divide By Zero...";
//std::cout.flush();
di << "\n";
{//==== Test Divide ByZero (Real) ===========================================
try{
OCC_CATCH_SIGNALS
- std::cout << "(Real) Divide By Zero..." << std::endl;
+ std::cout << "(Real) Divide By Zero..." << '\n';
di << "(Real) Divide By Zero...";
//std::cout.flush();
di << "\n";
{//==== Test Overflow (Integer) =============================================
try{
OCC_CATCH_SIGNALS
- std::cout << "(Integer) Overflow..." << std::endl;
+ std::cout << "(Integer) Overflow..." << '\n';
di << "(Integer) Overflow...";
//std::cout.flush();
di << "\n";
{//==== Test Overflow (Real) ================================================
try{
OCC_CATCH_SIGNALS
- std::cout << "(Real) Overflow..." << std::endl;
+ std::cout << "(Real) Overflow..." << '\n';
di << "(Real) Overflow...";
//std::cout.flush();
di << "\n";
{//==== Test Underflow (Real) ===============================================
try{
OCC_CATCH_SIGNALS
- std::cout << "(Real) Underflow" << std::endl; // to have message in log even if process crashed
+ std::cout << "(Real) Underflow" << '\n'; // to have message in log even if process crashed
di << "(Real) Underflow";
//std::cout.flush();
di << "\n";
{//==== Test Invalid Operation (Real) ===============================================
try{
OCC_CATCH_SIGNALS
- std::cout << "(Real) Invalid Operation..." << std::endl;
+ std::cout << "(Real) Invalid Operation..." << '\n';
di << "(Real) Invalid Operation...";
//std::cout.flush();
di << "\n";
{//==== Test Access Violation ===============================================
try {
OCC_CATCH_SIGNALS
- std::cout << "Segmentation Fault..." << std::endl;
+ std::cout << "Segmentation Fault..." << '\n';
di << "Segmentation Fault...";
//std::cout.flush();
di << "\n";
Handle(TDataStd_RealArray) array;
if (label1.FindAttribute(TDataStd_RealArray::GetID(), array) &&
array->Lower() == LOWER && array->Upper() == UPPER)
- std::cout<<"1: OK"<<std::endl;
+ std::cout<<"1: OK"<<'\n';
else
{
- std::cout<<"1: Failed.."<<std::endl;
+ std::cout<<"1: Failed.."<<'\n';
return 1;
}
doc->CommitCommand();
{
if (array->Value(i) != i)
{
- std::cout<<"2: Failed.."<<std::endl;
+ std::cout<<"2: Failed.."<<'\n';
return 2;
}
}
- std::cout<<"2: OK"<<std::endl;
+ std::cout<<"2: OK"<<'\n';
doc->CommitCommand();
//! 3. Re-init the array
array->Init(LOWER + 2, UPPER + 4);
if (array->Lower() != LOWER + 2 && array->Upper() != UPPER + 4)
{
- std::cout<<"3: Failed.."<<std::endl;
+ std::cout<<"3: Failed.."<<'\n';
return 3;
}
for (i = LOWER + 2; i <= UPPER + 4; i++)
{
if (array->Value(i) != i)
{
- std::cout<<"3: Failed.."<<std::endl;
+ std::cout<<"3: Failed.."<<'\n';
return 3;
}
}
- std::cout<<"3: OK"<<std::endl;
+ std::cout<<"3: OK"<<'\n';
doc->CommitCommand();
//! 4. Change array
{
if (array->Value(i) != i)
{
- std::cout<<"4: Failed.."<<std::endl;
+ std::cout<<"4: Failed.."<<'\n';
return 4;
}
}
- std::cout<<"4: OK"<<std::endl;
+ std::cout<<"4: OK"<<'\n';
doc->CommitCommand();
//! 5. Copy the array
copier.Perform();
if (!copier.IsDone())
{
- std::cout<<"5: Failed.."<<std::endl;
+ std::cout<<"5: Failed.."<<'\n';
return 5;
}
Handle(TDataStd_RealArray) array2;
if (!label2.FindAttribute(TDataStd_RealArray::GetID(), array2))
{
- std::cout<<"5: Failed.."<<std::endl;
+ std::cout<<"5: Failed.."<<'\n';
return 5;
}
for (i = LOWER + 5; i <= UPPER + 5; i++)
{
if (array->Value(i) != i)
{
- std::cout<<"5: Failed.."<<std::endl;
+ std::cout<<"5: Failed.."<<'\n';
return 5;
}
}
- std::cout<<"5: OK"<<std::endl;
+ std::cout<<"5: OK"<<'\n';
doc->CommitCommand();
//! 6. Undo/Redo
if (!label1.FindAttribute(TDataStd_RealArray::GetID(), array) ||
label2.FindAttribute(TDataStd_RealArray::GetID(), array2))
{
- std::cout<<"6.a: Failed.."<<std::endl;
+ std::cout<<"6.a: Failed.."<<'\n';
return 6;
}
//! 6.b: undoes the 4th action: the array should be changed to (lower+2,upper+4)
array->Lower() != LOWER + 2 ||
array->Upper() != UPPER + 4)
{
- std::cout<<"6.b: Failed.."<<std::endl;
+ std::cout<<"6.b: Failed.."<<'\n';
return 6;
}
for (i = LOWER + 2; i <= UPPER + 4; i++)
{
if (array->Value(i) != i)
{
- std::cout<<"6.b: Failed.."<<std::endl;
+ std::cout<<"6.b: Failed.."<<'\n';
return 6;
}
}
array->Lower() != LOWER ||
array->Upper() != UPPER)
{
- std::cout<<"6.c: Failed.."<<std::endl;
+ std::cout<<"6.c: Failed.."<<'\n';
return 6;
}
for (i = LOWER; i <= UPPER; i++)
{
if (array->Value(i) != i)
{
- std::cout<<"6.c: Failed.."<<std::endl;
+ std::cout<<"6.c: Failed.."<<'\n';
return 6;
}
}
array->Lower() != LOWER ||
array->Upper() != UPPER)
{
- std::cout<<"6.d: Failed.."<<std::endl;
+ std::cout<<"6.d: Failed.."<<'\n';
return 6;
}
for (i = LOWER; i <= UPPER; i++)
{
if (array->Value(i) != i)
{
- std::cout<<"6.d: Failed.."<<std::endl;
+ std::cout<<"6.d: Failed.."<<'\n';
return 6;
}
}
- std::cout<<"6: OK"<<std::endl;
+ std::cout<<"6: OK"<<'\n';
//! 7. Re-set the array
doc->OpenCommand();
array = TDataStd_RealArray::Set(label1, LOWER + 1, UPPER + 1);
if (array->Lower() != LOWER + 1 && array->Upper() != UPPER + 1)
{
- std::cout<<"7: Failed.."<<std::endl;
+ std::cout<<"7: Failed.."<<'\n';
return 7;
}
for (i = LOWER + 1; i <= UPPER + 1; i++)
{
if (array->Value(i) != i)
{
- std::cout<<"7: Failed.."<<std::endl;
+ std::cout<<"7: Failed.."<<'\n';
return 7;
}
}
- std::cout<<"7: OK"<<std::endl;
+ std::cout<<"7: OK"<<'\n';
doc->CommitCommand();
//! 8.Test of speed: set LOWER and UPPER equal to great integer number and
GeomAdaptor_Curve adaptor_spline(spline);
GCPnts_AbscissaPoint temp;
l_abcissa=temp.Length(adaptor_spline);
- std::cout<<"Length Spline(abcissa_Pnt): "<<l_abcissa<<std::endl;
+ std::cout<<"Length Spline(abcissa_Pnt): "<<l_abcissa<<'\n';
//length!! 2.
TopoDS_Edge edge = BRepBuilderAPI_MakeEdge (spline);
GProp_GProps prop;
BRepGProp::LinearProperties(edge,prop);
l_gprop=prop.Mass();
- std::cout<<"Length Spline(GProp_GProps): "<<l_gprop<<std::endl;
+ std::cout<<"Length Spline(GProp_GProps): "<<l_gprop<<'\n';
- std::cout<<"Difference (abcissa_Pnt<->GProp_GProps): "<<l_gprop-l_abcissa<<std::endl;
+ std::cout<<"Difference (abcissa_Pnt<->GProp_GProps): "<<l_gprop-l_abcissa<<'\n';
return 0;
}
// check that messages output to sender and directly to messenger do not intermix
aSender << "Sender message 1: start ...";
aMsgMgr->Send ("Direct message 1");
- aSender << "... end" << std::endl; // endl should send the message
+ aSender << "... end" << '\n'; // endl should send the message
// check that empty stream buffer does not produce output on destruction
Message::SendInfo();
aMsgMgr->Send ("Direct message 2");
// check that empty stream buffer does produce empty line if std::endl is passed
- Message::SendInfo() << std::endl;
+ Message::SendInfo() << '\n';
// last message should be sent on destruction of a sender
aSender << "Sender message 2";
GeomConvert_ApproxSurface aGAS (info->surf, 1e-4, GeomAbs_C1, GeomAbs_C1, 9, 9, 100, 1);
if (!aGAS.IsDone()) {
- std::cout << "Error: ApproxSurface is not done!" << std::endl;
+ std::cout << "Error: ApproxSurface is not done!" << '\n';
return 0;
}
const Handle(Geom_BSplineSurface)& aBSurf = aGAS.Surface();
if (aBSurf.IsNull()) {
- std::cout << "Error: BSplineSurface is not created!" << std::endl;
+ std::cout << "Error: BSplineSurface is not created!" << '\n';
return 0;
}
std::cout << "Number of UPoles:" << aBSurf->NbUPoles();
if (aBSurf->NbUPoles() == info->nbupoles)
{
- std::cout << ": OK" << std::endl;
+ std::cout << ": OK" << '\n';
return data; // any non-null pointer
}
else
{
- std::cout << ": Error, must be " << info->nbupoles << std::endl;
+ std::cout << ": Error, must be " << info->nbupoles << '\n';
return 0;
}
}
static Standard_Integer OCC23952sweep (Draw_Interpretor& di, Standard_Integer argc, const char ** argv)
{
if (argc != 3) {
- std::cout << "Error: invalid number of arguments" << std::endl;
+ std::cout << "Error: invalid number of arguments" << '\n';
return 1;
}
aStorage.surf = DrawTrSurf::GetSurface(argv[2]);
if (aStorage.surf.IsNull())
{
- std::cout << "Error: " << argv[2] << " is not a DRAW surface!" << std::endl;
+ std::cout << "Error: " << argv[2] << " is not a DRAW surface!" << '\n';
return 0;
}
GeomInt_IntSS anInter;
anInter.Perform (info->surf1, info->surf2, Precision::Confusion(), Standard_True);
if (!anInter.IsDone()) {
- std::cout << "An intersection is not done!" << std::endl;
+ std::cout << "An intersection is not done!" << '\n';
return 0;
}
std::cout << "Number of Lines:" << anInter.NbLines();
if (anInter.NbLines() == info->nbsol)
{
- std::cout << ": OK" << std::endl;
+ std::cout << ": OK" << '\n';
return data; // any non-null pointer
}
else
{
- std::cout << ": Error, must be " << info->nbsol << std::endl;
+ std::cout << ": Error, must be " << info->nbsol << '\n';
return 0;
}
}
static Standard_Integer OCC23952intersect (Draw_Interpretor& di, Standard_Integer argc, const char ** argv)
{
if (argc != 4) {
- std::cout << "Error: invalid number of arguments" << std::endl;
+ std::cout << "Error: invalid number of arguments" << '\n';
return 1;
}
aStorage.surf2 = DrawTrSurf::GetSurface(argv[3]);
if (aStorage.surf1.IsNull() || aStorage.surf2.IsNull())
{
- std::cout << "Error: Either " << argv[2] << " or " << argv[3] << " is not a DRAW surface!" << std::endl;
+ std::cout << "Error: Either " << argv[2] << " or " << argv[3] << " is not a DRAW surface!" << '\n';
return 0;
}
const Standard_Integer aNbIts = (anArgIter < theNArg) ? Draw::Atoi (theArgv[anArgIter++]) : 100;
if (aShapeF.IsNull() || aShapeF.ShapeType() != TopAbs_FACE)
{
- std::cout << "Error: " << aFaceName << " shape is null / not a face" << std::endl;
+ std::cout << "Error: " << aFaceName << " shape is null / not a face" << '\n';
return 1;
}
if (aShapeV.IsNull() || aShapeV.ShapeType() != TopAbs_VERTEX)
{
- std::cout << "Error: " << aVertName << " shape is null / not a vertex" << std::endl;
+ std::cout << "Error: " << aVertName << " shape is null / not a vertex" << '\n';
return 1;
}
const TopoDS_Face aFace = TopoDS::Face (aShapeF);
aF.open(argv[1]);
if (!aF.is_open())
{
- std::cout << "cannot create file " << argv[1] << std::endl;
+ std::cout << "cannot create file " << argv[1] << '\n';
return 1;
}
}
theDI << "Conversion was done OK";
if (aF.is_open())
{
- std::cout << "the file " << argv[1] << " has been created" << std::endl;
+ std::cout << "the file " << argv[1] << " has been created" << '\n';
aF.close();
}
return 0;
{
if (theArgc != 5)
{
- std::cout << "Incorrect number of arguments. See usage:" << std::endl;
+ std::cout << "Incorrect number of arguments. See usage:" << '\n';
theDI.PrintHelp(theArgv[0]);
return 1;
}
Handle(AIS_InteractiveContext) aContext = ViewerTest::GetAISContext();
if (aContext.IsNull())
{
- std::cout << "Error: no view available, call 'vinit' before!" << std::endl;
+ std::cout << "Error: no view available, call 'vinit' before!" << '\n';
return 1;
}
Handle(OCC27700_Text) aPresentation = new OCC27700_Text();
math_FRPR aFRPR(aFunc, Precision::Confusion());
aFRPR.Perform(aFunc, aStartPnt);
if (!aFRPR.IsDone())
- std::cout << "OCC30492: Error: FRPR optimization is not done." << std::endl;
+ std::cout << "OCC30492: Error: FRPR optimization is not done." << '\n';
else
- std::cout << "OCC30492: OK: FRPR optimization is done." << std::endl;
+ std::cout << "OCC30492: OK: FRPR optimization is done." << '\n';
math_BFGS aBFGS(1, Precision::Confusion());
aBFGS.Perform(aFunc, aStartPnt);
if (!aBFGS.IsDone())
- std::cout << "OCC30492: Error: BFGS optimization is not done." << std::endl;
+ std::cout << "OCC30492: Error: BFGS optimization is not done." << '\n';
else
- std::cout << "OCC30492: OK: BFGS optimization is done." << std::endl;
+ std::cout << "OCC30492: OK: BFGS optimization is done." << '\n';
return 0;
}
{
if (theNArg != 2)
{
- std::cout << "Use: " << theArgVal[0] << " shape" << std::endl;
+ std::cout << "Use: " << theArgVal[0] << " shape" << '\n';
return 1;
}
{
if (theNArg != 5)
{
- std::cout << "Use: " << theArgVal[0] <<" surface curve start end" << std::endl;
+ std::cout << "Use: " << theArgVal[0] <<" surface curve start end" << '\n';
return 1;
}
{
if (theNArg != 4)
{
- std::cout << "Use: " << theArgVal[0] << " face point start_pnt2d" << std::endl;
+ std::cout << "Use: " << theArgVal[0] << " face point start_pnt2d" << '\n';
return 1;
}
static Standard_Integer OCC28829 (Draw_Interpretor&, Standard_Integer, const char**)
{
// do something that causes FPE exception
- std::cout << "sqrt(-1) = " << sqrt (-1.) << std::endl;
+ std::cout << "sqrt(-1) = " << sqrt (-1.) << '\n';
return 0;
}
{
if (theNbArgs != 2)
{
- std::cerr << "Error: wrong number of arguments" << std::endl;
+ std::cerr << "Error: wrong number of arguments" << '\n';
return 1;
}
isSame = Standard_True;
} else {
aGuid2.ShallowDump(std::cout);
- std::cout <<std::endl;
+ std::cout <<'\n';
}
return isSame;
}
{
if (theArgc < 2)
{
- std::cout << "Error: give argument indicating type of map (map, doublemap, datamap, indexedmap, indexeddatamap)" << std::endl;
+ std::cout << "Error: give argument indicating type of map (map, doublemap, datamap, indexedmap, indexeddatamap)" << '\n';
return 1;
}
AllocDummyArr<NCollection_IndexedDataMap<int, int> > (theDI, nbm1, nbm2);
else
{
- std::cout << "Error: unrecognized argument " << theArgv[1] << std::endl;
+ std::cout << "Error: unrecognized argument " << theArgv[1] << '\n';
return 1;
}
return 0;
{
if (theArgc < 4)
{
- std::cerr << "Use: " << theArgv[0] << " shape counter_name nb_iterations" << std::endl;
+ std::cerr << "Use: " << theArgv[0] << " shape counter_name nb_iterations" << '\n';
return 1;
}
{
std::cout << "\nOCC29195 [nbRep] doc1.cbf doc1.xml doc1.std outDoc1.cbf outDoc1.xml doc2.cbf doc2.xml doc2.std outDoc2.cbf outDoc2.xml ...], where:";
std::cout << "\nnbRep - number repetitions of a thread function (by default - 50)";
- std::cout << "\ndocN - names (5 in each group) of OCAF documents names (3 input files, 2 output)\n" << std::endl;
+ std::cout << "\ndocN - names (5 in each group) of OCAF documents names (3 input files, 2 output)\n" << '\n';
return 1;
}
int iThread(0), off(0);
}
if (isOK)
- std::cout << "OK: Kronrod points and weights are calculated successfully." << std::endl;
+ std::cout << "OK: Kronrod points and weights are calculated successfully." << '\n';
else
- std::cout << "Error: Problem occurred during calculation of Kronrod points and weights." << std::endl;
+ std::cout << "Error: Problem occurred during calculation of Kronrod points and weights." << '\n';
return 0;
}
TopoDS_Shape aShape = DBRep::Get (theArgv [2]);
if (aShape.IsNull())
{
- std::cout << theArgv[2] << " does not exist" << std::endl;
+ std::cout << theArgv[2] << " does not exist" << '\n';
return 1;
}
TopoDS_Shape aBShape = DBRep::Get (theArgv [3]);
if (aBShape.IsNull())
{
- std::cout << theArgv[3] << " does not exist" << std::endl;
+ std::cout << theArgv[3] << " does not exist" << '\n';
return 1;
}
aShape[0] = DBRep::Get (theArgv [2]);
if (aShape[0].IsNull())
{
- std::cout << theArgv[2] << " does not exist" << std::endl;
+ std::cout << theArgv[2] << " does not exist" << '\n';
return 1;
}
aShape[1] = DBRep::Get (theArgv [3]);
if (aShape[1].IsNull())
{
- std::cout << theArgv[3] << " does not exist" << std::endl;
+ std::cout << theArgv[3] << " does not exist" << '\n';
return 1;
}
aShape[0] = DBRep::Get (theArgv [1]);
if (aShape[0].IsNull())
{
- std::cout << theArgv[1] << " does not exist" << std::endl;
+ std::cout << theArgv[1] << " does not exist" << '\n';
return 1;
}
aShape[1] = DBRep::Get (theArgv [2]);
if (aShape[1].IsNull())
{
- std::cout << theArgv[2] << " does not exist" << std::endl;
+ std::cout << theArgv[2] << " does not exist" << '\n';
return 1;
}
aDistTool.SetBVHSets (aTriangleBoxSet[0].get(), aTriangleBoxSet[1].get());
Standard_Real aSqDist = aDistTool.ComputeDistance();
if (!aDistTool.IsDone())
- std::cout << "Not Done" << std::endl;
+ std::cout << "Not Done" << '\n';
else
theDI << "Distance " << sqrt (aSqDist) << "\n";
aShape = DBRep::Get (theArgv [1]);
if (aShape.IsNull())
{
- std::cout << theArgv[1] << " does not exist" << std::endl;
+ std::cout << theArgv[1] << " does not exist" << '\n';
return 1;
}
for (Standard_Integer iZ = 0; iZ < aDField.DimensionZ(); ++iZ)
{
Standard_Real aDist = aDField.Voxel (iX, iY, iZ);
- std::cout << "(" << iX << ", " << iY << ", " << iZ << "): " << aDist << std::endl;
+ std::cout << "(" << iX << ", " << iY << ", " << iZ << "): " << aDist << '\n';
}
}
}
TDF_Label Label;
Standard_Boolean Found = DDF::AddLabel (DF, LabelName, Label);
if (!Found) {
- std::cout <<"no labels"<<std::endl;
+ std::cout <<"no labels"<<'\n';
return S;
}
if (Found) {
Label.FindAttribute(TNaming_NamedShape::GetID(),NS);
S = TNaming_Tool::CurrentShape(NS);
if (S.IsNull())
- std::cout <<"current shape from "<< LabelName <<" is deleted"<<std::endl;
+ std::cout <<"current shape from "<< LabelName <<" is deleted"<<'\n';
return S;
}
return S;
const char** arg = (const char**)theArguments;
Handle(TDF_Data) DF;
if (!DDF::GetDF(arg[1],DF)) {
- std::cout<<"Wrong df"<<std::endl;
+ std::cout<<"Wrong df"<<'\n';
return Standard_False;
}
DDF::AddLabel(DF,arg[2],theLabel);
if (!theLabel.IsNull()) return Standard_True;
- std::cout<<"Wrong entry"<<std::endl;
+ std::cout<<"Wrong entry"<<'\n';
return Standard_False;
}
if (theArgNb < 3
|| theArgNb > 4)
{
- std::cerr << "Usage: type help " << theArgs[0] << std::endl;
+ std::cerr << "Usage: type help " << theArgs[0] << '\n';
return 1;
}
printAllMeters(theDI);
if (iFail1 || iFail2)
std::cout << "Warning : N map failed " << iFail1 << " times, T map - " <<
- iFail2 << std::endl;
+ iFail2 << '\n';
}
// ===================== Test perform of IndexedMap type ==========================
it2 = it; // assignment
it2 = it++; // postfix increment
if (it2 == it || ! (it2 != it))
- std::cout << "Failed " << typeid(it).name() << " equality check" << std::endl;
+ std::cout << "Failed " << typeid(it).name() << " equality check" << '\n';
it2 = ++it; // prefix increment
if (it2 != it || ! (it2 == it))
- std::cout << "Failed " << typeid(it).name() << " equality check" << std::endl;
+ std::cout << "Failed " << typeid(it).name() << " equality check" << '\n';
typename CollectionType::iterator::value_type t = *it;
*it2 = t;
cit2 = cit; // assignment
cit2 = cit++; // postfix increment
if (cit2 == cit || ! (cit2 != cit))
- std::cout << "Failed " << typeid(cit).name() << " equality check" << std::endl;
+ std::cout << "Failed " << typeid(cit).name() << " equality check" << '\n';
cit2 = ++cit; // prefix increment
if (cit2 != it || ! (cit2 == cit))
- std::cout << "Failed " << typeid(cit).name() << " equality check" << std::endl;
+ std::cout << "Failed " << typeid(cit).name() << " equality check" << '\n';
typename CollectionType::const_iterator::value_type ct = *cit;
ct = *cit;
typename CollectionType::iterator it = aCollec->end(); // copy construction
typename CollectionType::iterator it2 = it--; // postfix decrement
if (it2 == it || ! (it2 != it))
- std::cout << "Failed " << typeid(it).name() << " equality check" << std::endl;
+ std::cout << "Failed " << typeid(it).name() << " equality check" << '\n';
it2 = --it; // prefix decrement
if (it2 != it || ! (it2 == it))
- std::cout << "Failed " << typeid(it).name() << " equality check" << std::endl;
+ std::cout << "Failed " << typeid(it).name() << " equality check" << '\n';
delete aCollec;
}
typename CollectionType::iterator it = aCollec->begin(); // copy construction
typename CollectionType::iterator it2 = it + 5;
if ((it2 - it) != 5)
- std::cout << "Failed " << typeid(it).name() << " arithmetics" << std::endl;
+ std::cout << "Failed " << typeid(it).name() << " arithmetics" << '\n';
if (it2 < it || it2 <= it || ! (it2 > it) || ! (it2 >= it))
- std::cout << "Failed " << typeid(it).name() << " comparison" << std::endl;
+ std::cout << "Failed " << typeid(it).name() << " comparison" << '\n';
it += 5;
if (it2 != it)
- std::cout << "Failed " << typeid(it).name() << " arithmetics" << std::endl;
+ std::cout << "Failed " << typeid(it).name() << " arithmetics" << '\n';
it2 = it - 5;
if ((it2 - it) != -5)
- std::cout << "Failed " << typeid(it).name() << " arithmetics" << std::endl;
+ std::cout << "Failed " << typeid(it).name() << " arithmetics" << '\n';
if (it2 > it || it2 >= it || ! (it2 < it) || ! (it2 <= it))
- std::cout << "Failed " << typeid(it).name() << " comparison" << std::endl;
+ std::cout << "Failed " << typeid(it).name() << " comparison" << '\n';
it -= 5;
if (it2 != it)
- std::cout << "Failed " << typeid(it).name() << " arithmetics" << std::endl;
+ std::cout << "Failed " << typeid(it).name() << " arithmetics" << '\n';
typename CollectionType::value_type t = it[5]; // offset dereference
*it = t;
// run-time tests
Standard_Boolean aResult = TestIteration<NCollection_List<int>, std::list<int> >();
std::cout << "NCollection_List<int> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestIteration<NCollection_List<double>, std::list<double> >();
std::cout << "NCollection_List<double> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestMinMax<NCollection_List<int>, std::list<int> >();
std::cout << "NCollection_List<int> Min-Max: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestMinMax<NCollection_List<double>, std::list<double> >();
std::cout << "NCollection_List<double> Min-Max: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestReplace<NCollection_List<int>, std::list<int> >();
std::cout << "NCollection_List<int> Replace: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestReplace<NCollection_List<double>, std::list<double> >();
std::cout << "NCollection_List<double> Replace: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestParallel< NCollection_List<int>, std::list<int> >();
std::cout << "NCollection_List<int> Parallel: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestParallel<NCollection_List<double>, std::list<double> >();
std::cout << "NCollection_List<double> Parallel: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
return 0;
}
// run-time tests
Standard_Boolean aResult = TestMapIteration<NCollection_Map<Standard_Integer>, Standard_Integer>();
std::cout << "NCollection_Map<int> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestMapIteration<NCollection_Map<Standard_Real>, Standard_Real>();
std::cout << "NCollection_Map<double> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
return 0;
}
// run-time tests
Standard_Boolean aResult = TestMapIteration<NCollection_IndexedMap<Standard_Integer>, Standard_Integer>();
std::cout << "NCollection_IndexedMap<int> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestMapIteration<NCollection_IndexedMap<Standard_Real>, Standard_Real>();
std::cout << "NCollection_IndexedMap<double> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
return 0;
}
// run-time tests
Standard_Boolean aResult = TestMapIteration<NCollection_DataMap<Standard_Integer, Standard_Integer>, Standard_Integer>();
std::cout << "NCollection_DataMap<int> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestMapIteration<NCollection_DataMap<Standard_Real, Standard_Real>, Standard_Real>();
std::cout << "NCollection_DataMap<double> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestDataMapParallel<NCollection_DataMap<Standard_Integer, Standard_Integer>, Standard_Integer>();
std::cout << "NCollection_DataMap<int> Parallel: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestDataMapParallel<NCollection_DataMap<Standard_Real, Standard_Real>, Standard_Real>();
std::cout << "NCollection_DataMap<double> Parallel: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
return 0;
}
// run-time tests
Standard_Boolean aResult = TestMapIteration<NCollection_IndexedDataMap<Standard_Integer, Standard_Integer>, Standard_Integer>();
std::cout << "NCollection_IndexedDataMap<int> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestMapIteration<NCollection_IndexedDataMap<Standard_Real, Standard_Real>, Standard_Real>();
std::cout << "NCollection_IndexedDataMap<double> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestDataMapParallel<NCollection_IndexedDataMap<Standard_Integer, Standard_Integer>, Standard_Integer>();
std::cout << "NCollection_IndexedDataMap<int> Parallel: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestDataMapParallel<NCollection_IndexedDataMap<Standard_Real, Standard_Real>, Standard_Real>();
std::cout << "NCollection_IndexedDataMap<double> Parallel: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
return 0;
}
// run-time tests
Standard_Boolean aResult = TestIteration<NCollection_Sequence<int>, std::list<int> >();
std::cout << "NCollection_Sequence<int> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestIteration<NCollection_Sequence<double>, std::list<double> >();
std::cout << "NCollection_Sequence<double> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestMinMax<NCollection_Sequence<int>, std::list<int> >();
std::cout << "NCollection_Sequence<int> Min-Max: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestMinMax<NCollection_Sequence<double>, std::list<double> >();
std::cout << "NCollection_Sequence<double> Min-Max: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestReplace<NCollection_Sequence<int>, std::list<int> >();
std::cout << "NCollection_Sequence<int> Replace: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestReplace<NCollection_Sequence<double>, std::list<double> >();
std::cout << "NCollection_Sequence<double> Replace: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestReverse<NCollection_Sequence<int>, std::list<int> >();
std::cout << "NCollection_Sequence<int> Reverse: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestReverse<NCollection_Sequence<double>, std::list<double> >();
std::cout << "NCollection_Sequence<double> Reverse: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestParallel<NCollection_Sequence<int>, std::list<int> >();
std::cout << "NCollection_Sequence<int> Parallel: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestParallel<NCollection_Sequence<double>, std::list<double> >();
std::cout << "NCollection_Sequence<double> Parallel: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
return 0;
}
// run-time tests
Standard_Boolean aResult = TestIteration<NCollection_Vector<int>, std::vector<int> >();
std::cout << "NCollection_Vector<int> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestIteration<NCollection_Vector<double>, std::vector<double> >();
std::cout << "NCollection_Vector<double> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestMinMax<NCollection_Vector<int>, std::vector<int> >();
std::cout << "NCollection_Vector<int> Min-Max: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestMinMax<NCollection_Vector<double>, std::vector<double> >();
std::cout << "NCollection_Vector<double> Min-Max: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestReplace<NCollection_Vector<int>, std::vector<int> >();
std::cout << "NCollection_Vector<int> Replace: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestReplace<NCollection_Vector<double>, std::vector<double> >();
std::cout << "NCollection_Vector<double> Replace: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestReverse<NCollection_Vector<int>, std::vector<int> >();
std::cout << "NCollection_Vector<int> Reverse: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestReverse<NCollection_Vector<double>, std::vector<double> >();
std::cout << "NCollection_Vector<double> Reverse: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestSort<NCollection_Vector<int>, std::vector<int> >();
std::cout << "NCollection_Vector<int> Sort: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestSort<NCollection_Vector<double>, std::vector<double> >();
std::cout << "NCollection_Vector<double> Sort: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestParallel<NCollection_Vector<int>, std::vector<int> >();
std::cout << "NCollection_Vector<int> Parallel: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestParallel<NCollection_Vector<double>, std::vector<double> >();
std::cout << "NCollection_Vector<double> Parallel: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
{
// Test case for a corner case described in a bug #0027941
NCollection_Vector<int>::iterator aShift = aBegin + THE_INCREMENT;
aResult = (aShift == anEnd);
std::cout << "NCollection_Vector<int> Offset: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
std::stable_sort (aVector.begin(), aVector.end());
}
// run-time tests
Standard_Boolean aResult = TestIteration<NCollection_Array1<int>, std::vector<int> >();
std::cout << "NCollection_Array1<int> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestIteration<NCollection_Array1<double>, std::vector<double> >();
std::cout << "NCollection_Array1<double> Iteration: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestMinMax<NCollection_Array1<int>, std::vector<int> >();
std::cout << "NCollection_Array1<int> Min-Max: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestMinMax<NCollection_Array1<double>, std::vector<double> >();
std::cout << "NCollection_Array1<double> Min-Max: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestReplace<NCollection_Array1<int>, std::vector<int> >();
std::cout << "NCollection_Array1<int> Replace: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestReplace<NCollection_Array1<double>, std::vector<double> >();
std::cout << "NCollection_Array1<double> Replace: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestReverse<NCollection_Array1<int>, std::vector<int> >();
std::cout << "NCollection_Array1<int> Reverse: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestReverse<NCollection_Array1<double>, std::vector<double> >();
std::cout << "NCollection_Array1<double> Reverse: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestSort<NCollection_Array1<int>, std::vector<int> >();
std::cout << "NCollection_Array1<int> Sort: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestSort<NCollection_Array1<double>, std::vector<double> >();
std::cout << "NCollection_Array1<double> Sort: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestParallel<NCollection_Array1<int>, std::vector<int> >();
std::cout << "NCollection_Array1<int> Parallel: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
aResult = TestParallel<NCollection_Array1<double>, std::vector<double> >();
std::cout << "NCollection_Array1<double> Parallel: " <<
- (aResult ? "SUCCESS" : "FAIL") << std::endl;
+ (aResult ? "SUCCESS" : "FAIL") << '\n';
return 0;
}
aVec.Append(5);
if (aVec(0) != 5)
- std::cout << "Error: wrong value in original vector!" << std::endl;
+ std::cout << "Error: wrong value in original vector!" << '\n';
aVec2.Append(5);
if (aVec2(0) != 5)
- std::cout << "Error: wrong value in copy-constructed vector!" << std::endl;
+ std::cout << "Error: wrong value in copy-constructed vector!" << '\n';
aVec3.Append(5);
if (aVec3(0) != 5)
- std::cout << "Error: wrong value in copied vector!" << std::endl;
- std::cout << "Test OK" << std::endl;
+ std::cout << "Error: wrong value in copied vector!" << '\n';
+ std::cout << "Test OK" << '\n';
return 0;
}
{
if (theArray.Value(i) != i + 113.)
{
- std::cout << "Error at item " << i << ": value = " << theArray.Value(i) << ", expected " << i + 113. << std::endl;
+ std::cout << "Error at item " << i << ": value = " << theArray.Value(i) << ", expected " << i + 113. << '\n';
return false;
}
}
}
else if (myVerbose)
{
- std::cout << "Resource Manager Warning: aDefaultsDirectory is empty." << std::endl;
+ std::cout << "Resource Manager Warning: aDefaultsDirectory is empty." << '\n';
}
if (!theUserDefaultsDirectory.IsEmpty())
}
else if (myVerbose)
{
- std::cout << "Resource Manager Warning: anUserDefaultsDirectory is empty." << std::endl;
+ std::cout << "Resource Manager Warning: anUserDefaultsDirectory is empty." << '\n';
}
}
if (!aPath.IsEmpty())
Load(aPath,myRefMap);
else if (myVerbose)
- std::cout << "Resource Manager Warning: Environment variable \"CSF_" << aName << "Defaults\" not set." << std::endl;
+ std::cout << "Resource Manager Warning: Environment variable \"CSF_" << aName << "Defaults\" not set." << '\n';
if (!aUserPath.IsEmpty())
Load(aUserPath,myRefMap);
else if (myVerbose)
- std::cout << "Resource Manager Warning: Environment variable \"CSF_" << aName << "UserDefaults\" not set." << std::endl;
+ std::cout << "Resource Manager Warning: Environment variable \"CSF_" << aName << "UserDefaults\" not set." << '\n';
}
// =======================================================================
if (File.Failed()) {
if (myVerbose)
std::cout << "Resource Manager Warning: Cannot read file \"" << FileName
- << "\". File not found or permission denied." << std::endl;
+ << "\". File not found or permission denied." << '\n';
return;
}
Standard_Integer LineNumber = 1;
case Resource_KOL_Error:
if (myVerbose)
std::cout << "Resource Manager: Syntax error at line "
- << LineNumber << " in file : " << FileName << std::endl;
+ << LineNumber << " in file : " << FileName << '\n';
break;
}
LineNumber++;
File.Close();
if (myVerbose)
std::cout << "Resource Manager: " << ((&aMap == &myUserMap) ? "User" : "Reference")
- << " file \"" << FileName << "\" loaded" << std::endl;
+ << " file \"" << FileName << "\" loaded" << '\n';
}
static Resource_KindOfLine WhatKindOfLine(OSD_File& aFile,
aToken2 = Line;
}
if (Debug)
- std::cout << "'\t Value = '" << aToken2 << "'" << std::endl << std::flush;
+ std::cout << "'\t Value = '" << aToken2 << "'" << '\n' << std::flush;
return Resource_KOL_Resource;
}
if (dir.IsEmpty()) {
if (myVerbose)
std::cout << "Resource Manager Warning: environment variable \""
- << anEnvVar << "\" not set. Cannot save resources." << std::endl ;
+ << anEnvVar << "\" not set. Cannot save resources." << '\n' ;
return Standard_False;
}
if (!aStatus) {
if (myVerbose)
std::cout << "Resource Manager: Error opening or creating directory \"" << aFilePath
- << "\". Permission denied. Cannot save resources." << std::endl;
+ << "\". Permission denied. Cannot save resources." << '\n';
return Standard_False;
}
}
if (!aStatus) {
if (myVerbose)
std::cout << "Resource Manager: Error opening or creating file \"" << aFilePath
- << "\". Permission denied. Cannot save resources." << std::endl;
+ << "\". Permission denied. Cannot save resources." << '\n';
return Standard_False;
}
Line = KeyArray(Index) + ":\t" + Value + "\n";
if (Debug)
- std::cout << "Line = '" << Line << "'" << std::endl;
+ std::cout << "Line = '" << Line << "'" << '\n';
File.Write(Line, Line.Length());
}
if (myVerbose)
- std::cout << "Resource Manager: Resources saved in file " << aFilePath << std::endl;
+ std::cout << "Resource Manager: Resources saved in file " << aFilePath << '\n';
}
File.Close();
return Standard_True;
#ifdef TRANSLOG
if (TP->TraceLevel() > 1)
- sout<<" -- Actor : Ent.n0 "<<TP->Model()->Number(PD)<<" -> Shared Ent.no"<<TP->Model()->Number(NAUO)<<std::endl;
+ sout<<" -- Actor : Ent.n0 "<<TP->Model()->Number(PD)<<" -> Shared Ent.no"<<TP->Model()->Number(NAUO)<<'\n';
#endif
Handle(Transfer_Binder) binder;
Message_ProgressRange aRange = PS.Next();
Message_Messenger::StreamBuffer sout = TP->Messenger()->SendInfo();
#ifdef TRANSLOG
if (TP->TraceLevel() > 2)
- sout<<" -- Actor : case ShapeRepr. NbItems="<<nb<<std::endl;
+ sout<<" -- Actor : case ShapeRepr. NbItems="<<nb<<'\n';
#endif
// Compute unit conversion factors and geometric Accuracy
Message_ProgressRange aRange = aPS.Next();
#ifdef TRANSLOG
if (TP->TraceLevel() > 2)
- sout<<" -- Actor, shape_representation.item n0. "<<i<<std::endl;
+ sout<<" -- Actor, shape_representation.item n0. "<<i<<'\n';
#endif
Handle(StepRepr_RepresentationItem) anitem = sr->ItemsValue(i);
if(anitem.IsNull())
#ifdef TRANSLOG
if (TP->TraceLevel() > 2)
- sout<<" -- Actor : case shape_definition_representation."<<std::endl;
+ sout<<" -- Actor : case shape_definition_representation."<<'\n';
#endif
Handle(Transfer_Binder) binder = TP->Find(rep);
{
// if (anitem.IsNull()) continue;
#ifdef TRANSLOG
if (TP->TraceLevel() > 1)
- sout<<" -- Actor : Ent.n0 "<<TP->Model()->Number(start)<<" -> Shared Ent.no"<<TP->Model()->Number(anitem)<<std::endl;
+ sout<<" -- Actor : Ent.n0 "<<TP->Model()->Number(start)<<" -> Shared Ent.no"<<TP->Model()->Number(anitem)<<'\n';
#endif
if (!TP->IsBound(anitem)) binder = TP->Transferring(anitem, aRange);
OSD_Timer chrono;
if (TP->TraceLevel() > 2)
sout << "Begin transfer STEP -> CASCADE, Type "
- << start->DynamicType()->Name() << std::endl;
+ << start->DynamicType()->Name() << '\n';
chrono.Start();
#endif
Handle(StepData_StepModel) aStepModel = Handle(StepData_StepModel)::DownCast(TP->Model());
#ifdef TRANSLOG
chrono.Stop();
if (TP->TraceLevel() > 2)
- sout<<"End transfer STEP -> CASCADE :" << (found ? "OK" : " : no result")<<std::endl;
+ sout<<"End transfer STEP -> CASCADE :" << (found ? "OK" : " : no result")<<'\n';
if (TP->TraceLevel() > 2)
chrono.Show();
#endif
#ifdef TRANSLOG
// POUR MISE AU POINT, a supprimer ensuite
if (TP->TraceLevel() > 1)
- sout<<" -- Actor : Transfer Ent.n0 "<<TP->Model()->Number(start)<<" Type "<<start->DynamicType()->Name()<<std::endl;
+ sout<<" -- Actor : Transfer Ent.n0 "<<TP->Model()->Number(start)<<" Type "<<start->DynamicType()->Name()<<'\n';
#endif
Handle(TransferBRep_ShapeBinder) shbinder;
// Assign uncertainty
#ifdef TRANSLOG
if (TP->TraceLevel() > 1)
- TP->Messenger()->SendInfo() <<" Cc1ToTopoDS : Length Unit = "<<myUnit.LengthFactor()<<" Tolerance CASCADE = "<<myPrecision<<std::endl;
+ TP->Messenger()->SendInfo() <<" Cc1ToTopoDS : Length Unit = "<<myUnit.LengthFactor()<<" Tolerance CASCADE = "<<myPrecision<<'\n';
#endif
}
Message_Messenger::StreamBuffer sout = Message::SendInfo();
sout << " **** Interruption ReadFile par Exception : ****\n";
sout << anException.GetMessageString();
- sout << "\n Abandon" << std::endl;
+ sout << "\n Abandon" << '\n';
status = IFSelect_RetFail;
}
if (status != IFSelect_RetDone) return status;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
sout << " **** Interruption ReadFile par Exception : ****\n";
sout << anException.GetMessageString();
- sout << "\n Abandon" << std::endl;
+ sout << "\n Abandon" << '\n';
status = IFSelect_RetFail;
}
if (status != IFSelect_RetDone) return status;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
sout << " **** Interruption ReadFile par Exception : ****\n";
sout << anException.GetMessageString();
- sout << "\n Abandon" << std::endl;
+ sout << "\n Abandon" << '\n';
status = IFSelect_RetFail;
}
if (status != IFSelect_RetDone) return status;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
sout << " **** Interruption ReadFile par Exception : ****\n";
sout << anException.GetMessageString();
- sout << "\n Abandon" << std::endl;
+ sout << "\n Abandon" << '\n';
status = IFSelect_RetFail;
}
if (status != IFSelect_RetDone) return status;
//for ( Standard_Integer j=0; j < level; j++ ) os << "\t";
os << "SDR: " <<Model->StringLabel(cmp->GetSDR())->ToCString()<<"\t";
- os << "Product: "<<GetProductName(cmp->GetSDR())<<std::endl;
+ os << "Product: "<<GetProductName(cmp->GetSDR())<<'\n';
for ( Standard_Integer i = 1; i <= cmp->GetList()->Length(); i++) {
for ( Standard_Integer j=0; j < level+1; j++ ) os << "\t";
os << "NAUO :"<<Model->StringLabel(cmp->GetList()->Value(i)->GetNAUO())->ToCString()<<";\t";
{
Handle(Interface_InterfaceModel) model = myGraph.Model();
for(Standard_Integer i = 1 ; i <=myRoots.Length(); i++) {
- os<<"Assembly N: "<<i<<std::endl<<std::endl;
+ os<<"Assembly N: "<<i<<'\n'<<'\n';
PrintSubAssembly(os,myRoots.Value(i),model,0);
}
}
return S;
}
}
- std::cout<<"BRepTools_ReShape::Apply NOT YET IMPLEMENTED"<<std::endl;
+ std::cout<<"BRepTools_ReShape::Apply NOT YET IMPLEMENTED"<<'\n';
return shape;
}
//==== Check if can do the "longjmp" =======================================
if(anActive == NULL) {
- std::cerr << "*** Abort *** an exception was raised, but no catch was found." << std::endl;
+ std::cerr << "*** Abort *** an exception was raised, but no catch was found." << '\n';
if (!theError.IsNull())
- std::cerr << "\t... The exception is:" << theError->GetMessageString() << std::endl;
+ std::cerr << "\t... The exception is:" << theError->GetMessageString() << '\n';
exit(1);
}
myReaderStatus = PCDM_RS_OpenError;
Standard_SStream aMsg;
- aMsg << anException << std::endl;
+ aMsg << anException << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
myReaderStatus = PCDM_RS_NoDocument;
Standard_SStream aMsg;
- aMsg << "could not find any document in this file" << std::endl;
+ aMsg << "could not find any document in this file" << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
{
aMsg << anUnknownTypes(i);
if (i < anUnknownTypes.Length()) aMsg << ",";
- else aMsg << std::endl;
+ else aMsg << '\n';
}
throw Standard_Failure(aMsg.str().c_str());
case Storage_VSNotOpen:
case Storage_VSAlreadyOpen:
myReaderStatus = PCDM_RS_OpenError;
- aMsg << "Stream Open Error" << std::endl;
+ aMsg << "Stream Open Error" << '\n';
throw Standard_Failure(aMsg.str().c_str());
case Storage_VSModeError:
myReaderStatus = PCDM_RS_WrongStreamMode;
- aMsg << "Stream is opened with a wrong mode for operation" << std::endl;
+ aMsg << "Stream is opened with a wrong mode for operation" << '\n';
throw Standard_Failure(aMsg.str().c_str());
case Storage_VSSectionNotFound:
myReaderStatus = PCDM_RS_FormatFailure;
- aMsg << "Section is not found" << std::endl;
+ aMsg << "Section is not found" << '\n';
throw Standard_Failure(aMsg.str().c_str());
case Storage_VSFormatError:
myReaderStatus = PCDM_RS_FormatFailure;
- aMsg << "Wrong format error" << std::endl;
+ aMsg << "Wrong format error" << '\n';
throw Standard_Failure(aMsg.str().c_str());
case Storage_VSUnknownType:
myReaderStatus = PCDM_RS_TypeFailure;
- aMsg << "Try to read an unknown type" << std::endl;
+ aMsg << "Try to read an unknown type" << '\n';
throw Standard_Failure(aMsg.str().c_str());
case Storage_VSTypeMismatch:
myReaderStatus = PCDM_RS_TypeFailure;
- aMsg << "Try to read a wrong primitive type" << std::endl;
+ aMsg << "Try to read a wrong primitive type" << '\n';
throw Standard_Failure(aMsg.str().c_str());
default:
myReaderStatus = PCDM_RS_DriverFailure;
- aMsg << "Retrieval Driver Failure" << std::endl;
+ aMsg << "Retrieval Driver Failure" << '\n';
throw Standard_Failure(aMsg.str().c_str());
}
}
TColStd_SequenceOfAsciiString listypes;
if (!module->ComplexType(CN,listypes))
S << "(Complex Type : ask level > 0) cdl = "
- << ent->DynamicType()->Name() << " (...);" << std::endl;
+ << ent->DynamicType()->Name() << " (...);" << '\n';
else {
Standard_Integer n = listypes.Length();
for (i = 1; i <= n; i ++) S << listypes.Value(i) << " (...)";
- S << std::endl;
+ S << '\n';
}
}
- else S << module->StepType(CN) << " (...);" << std::endl;
+ else S << module->StepType(CN) << " (...);" << '\n';
}
else S << "(Unrecognized Type for protocol) cdl = "
- << ent->DynamicType()->Name() << " (...);" << std::endl;
- if (nlab > 0) S << "/* Ident in file for "<<num<<" : #"<<nlab<<" */"<<std::endl;
+ << ent->DynamicType()->Name() << " (...);" << '\n';
+ if (nlab > 0) S << "/* Ident in file for "<<num<<" : #"<<nlab<<" */"<<'\n';
}
else if (level == 1) {
S <<" (no ident): ";
for (i = 1; i <= nb; i ++)
{ if (ids.Value(i) >= 0) continue; S <<" #"<<i; }
- S <<std::endl;
+ S <<'\n';
}
if (nbq > 0) {
S <<" (ident = num): ";
for (i = 1; i <= nb; i ++) { if (ids.Value(i) == i) S <<" #"<<i; }
- S <<std::endl;
+ S <<'\n';
}
if (nbi < 0) { // on n affiche plus num:#id , on envoie un petit help
Standard_Integer nbl = 0, nbr = 0, nbr0 = 0, nbc = 0;
char unid[30];
// S <<" (proper ident): #num #ident"<<std::endl;
- S <<" (proper ident): num:#ident num:#ident ..."<<std::endl;
+ S <<" (proper ident): num:#ident num:#ident ..."<<'\n';
for (i = 1; i <= nb; i ++) {
if (ids.Value(i) <= 0 || ids.Value(i) == i) continue;
sprintf (unid,"%d:#%d",i,ids.Value(i));
nbc = (Standard_Integer) strlen (unid); nbr = ((80-nbc) %4) +2;
nbl += nbc;
- if (nbl+nbr0 > 79) { nbl = nbc; S <<std::endl; }
+ if (nbl+nbr0 > 79) { nbl = nbc; S <<'\n'; }
else { nbl += nbr0; for (; nbr0 > 0; nbr0 --) S << " "; }
S <<unid;
nbr0 = nbr;
// S<<" "<<i<<" ->#"<<ids.Value(i);
// nbl ++; if (nbl > 5) { nbl = nbr = 0; S<<std::endl; }
}
- if (nbl > 0) S <<std::endl;
+ if (nbl > 0) S <<'\n';
}
- if (nbi > 0) S <<"In dump, iii:#jjj means : entity rank iii has step ident #jjj"<<std::endl;
+ if (nbi > 0) S <<"In dump, iii:#jjj means : entity rank iii has step ident #jjj"<<'\n';
// S<<" -- Dumping data, entity "<<num<<" level "<<level<<" :"<<std::endl;
}
if (level > 0)
sout << " *** Incorrect record " << num << " (on " << NbRecords()
<< " -> " << num * 100 / NbRecords() << " % in File) ***";
if (prev > 0) sout << " Ident #" << theidents(prev);
- sout << "\n" << errm << std::endl;
+ sout << "\n" << errm << '\n';
thecheck->AddWarning(errm.ToCString(), "Complex Type incorrect : ");
}
break;
Standard_Integer numsub = FP.EntityNumber();
if (numsub > thelastn) {
Message::SendInfo()
- << "Bad Sub.N0, Record " << num << " Param " << na << ":$" << numsub << std::endl;
+ << "Bad Sub.N0, Record " << num << " Param " << na << ":$" << numsub << '\n';
continue;
}
FP.SetEntityNumber(subn(numsub));
// ... Et sortir message un peu plus complet
sout << "*** ERR StepReaderData *** Entite #" << ident
<< "\n Type:" << RecordType(num)
- << " Param.n0 " << na << ": #" << id << " Not found" << std::endl;
+ << " Param.n0 " << na << ": #" << id << " Not found" << '\n';
} // FIN Mapping
} // FIN Traitement Reference
} // FIN Boucle Parametres
char ligne[80];
sprintf(ligne, "Ident defined SEVERAL TIMES : #%d", ident);
thecheck->AddFail(ligne, "Ident defined SEVERAL TIMES : #%d");
- sout << "StepReaderData : SetEntityNumbers, " << ligne << std::endl;
+ sout << "StepReaderData : SetEntityNumbers, " << ligne << '\n';
}
if (indm(indmap) > 0) indm(indmap) = -indm(indmap); // Pas pour Map
// Cas Normal pour la Map
sout << "*** ERR StepReaderData *** Entite " << nument
<< ", a " << (nr * 100) / nbseq << "% de DATA : #" << ident
<< "\n Type:" << RecordType(num)
- << " Param.n0 " << na << ": #" << id << " Not found" << std::endl;
+ << " Param.n0 " << na << ": #" << id << " Not found" << '\n';
FP.SetEntityNumber(0); // -> Reference non resolue
}
Handle(Interface_Check) mch = model->GlobalCheck();
Standard_Integer nbmess = ach->NbWarnings();
sout<<nbmess<<" Warnings on Reading Header Entity N0."<<i<<":";
- if (!ent.IsNull()) sout << ent->DynamicType()->Name() << std::endl;
+ if (!ent.IsNull()) sout << ent->DynamicType()->Name() << '\n';
for (Standard_Integer nf = 1; nf <= nbmess; nf++)
{
sout << ach->CWarning(nf) << "\n";
Handle(Interface_Check) mch = model->GlobalCheck();
Standard_Integer nbmess = ach->NbFails();
sout << " Fails on Reading Header Entity N0." << i << ":";
- if (!ent.IsNull()) sout << ent->DynamicType()->Name() << std::endl;
+ if (!ent.IsNull()) sout << ent->DynamicType()->Name() << '\n';
for (Standard_Integer nf = 1; nf <= nbmess; nf++)
{
sout << ach->CFail(nf) << "\n";
return;
Message_Messenger::StreamBuffer sout = theIsFail ? Message::SendFail() : Message::SendTrace();
- sout << "**** ERR StepFile : " << theErrorMessage << " ****" << std::endl;
+ sout << "**** ERR StepFile : " << theErrorMessage << " ****" << '\n';
}
static Standard_Integer StepFile_Read (const char* theName,
case 1 : { // **** StepSchema
if (argc < 2) {
- std::cout<<"Identify an entity"<<std::endl;
+ std::cout<<"Identify an entity"<<'\n';
return IFSelect_RetError;
}
Standard_Integer num = pilot->Number(arg1);
if (num <= 0) {
- std::cout<<"Not an entity : "<<arg2<<std::endl;
+ std::cout<<"Not an entity : "<<arg2<<'\n';
return IFSelect_RetError;
}
Handle(Standard_Transient) ent = pilot->Session()->StartingEntity(num);
DeclareAndCast(StepData_UndefinedEntity,und,ent);
if (!und.IsNull()) {
- std::cout<<"Entity "<<arg2<<" : No Binding known"<<std::endl;
+ std::cout<<"Entity "<<arg2<<" : No Binding known"<<'\n';
return IFSelect_RetVoid;
}
DeclareAndCast(StepData_Simple,sim,ent);
if (!sim.IsNull()) {
- std::cout<<"Entity "<<arg2<<" : Late Binding"<<std::endl;
- std::cout<<"Simple Type : "<<sim->StepType()<<std::endl;
+ std::cout<<"Entity "<<arg2<<" : Late Binding"<<'\n';
+ std::cout<<"Simple Type : "<<sim->StepType()<<'\n';
return IFSelect_RetVoid;
}
DeclareAndCast(StepData_Plex,plx,ent);
if (!plx.IsNull()) {
- std::cout<<"Entity "<<arg2<<" : Late Binding"<<std::endl;
- std::cout<<"Complex Type"<<std::endl;
+ std::cout<<"Entity "<<arg2<<" : Late Binding"<<'\n';
+ std::cout<<"Complex Type"<<'\n';
}
// reste Early Binding
- std::cout<<"Entity "<<arg2<<" : Early Binding"<<std::endl;
- std::cout<<"CDL Type : "<<ent->DynamicType()->Name()<<std::endl;
+ std::cout<<"Entity "<<arg2<<" : Early Binding"<<'\n';
+ std::cout<<"CDL Type : "<<ent->DynamicType()->Name()<<'\n';
return IFSelect_RetVoid;
}
case 40 : { // **** FloatFormat
char prem = ' ';
if (argc < 2) prem = '?';
- else if (argc == 5) { std::cout<<"floatformat tout court donne les formes admises"<<std::endl; return IFSelect_RetError; }
+ else if (argc == 5) { std::cout<<"floatformat tout court donne les formes admises"<<'\n'; return IFSelect_RetError; }
else prem = arg1[0];
Standard_Boolean zerosup=Standard_False;
Standard_Integer digits = 0;
if (argc > 4) {
Rmin = Atof(pilot->Word(4).ToCString());
Rmax = Atof(pilot->Word(5).ToCString());
- if (Rmin <= 0 || Rmax <= 0) { std::cout<<"intervalle : donner reels > 0"<<std::endl; return IFSelect_RetError; }
+ if (Rmin <= 0 || Rmax <= 0) { std::cout<<"intervalle : donner reels > 0"<<'\n'; return IFSelect_RetError; }
}
Handle(StepSelect_FloatFormat) fm = new StepSelect_FloatFormat;
if (argc == 2) fm->SetDefault(digits);
if (aStream.get() == NULL) {
ctx.CCheck(0)->AddFail("Step File could not be created");
- sout<<" Step File could not be created : " << ctx.FileName() << std::endl; return 0;
+ sout<<" Step File could not be created : " << ctx.FileName() << '\n'; return 0;
}
sout << " Step File Name : "<<ctx.FileName();
StepData_StepWriter SW(stepmodel);
ctx.CCheck(chl.Number())->GetMessages(chl.Value());
sout<<" Write ";
Standard_Boolean isGood = SW.Print (*aStream);
- sout<<" Done"<<std::endl;
+ sout<<" Done"<<'\n';
errno = 0;
aStream->flush();
isGood = aStream->good() && isGood && !errno;
aStream.reset();
if(errno)
- sout << strerror(errno) << std::endl;
+ sout << strerror(errno) << '\n';
return isGood;
}
Handle(Standard_Transient) ent, con; ent = entity;
S <<" --- (STEP) Entity "; model->Print(entity, S);
if (iserr) con = model->ReportEntity(nument)->Content();
- if (entity.IsNull()) { S <<" Null"<<std::endl; return; }
+ if (entity.IsNull()) { S <<" Null"<<'\n'; return; }
// On attaque le dump : d abord cas de l Erreur
- S << " Type cdl : " << entity->DynamicType()->Name() << std::endl;
+ S << " Type cdl : " << entity->DynamicType()->Name() << '\n';
if (iserr)
- S <<" *** NOT WELL LOADED : CONTENT FROM FILE ***"<<std::endl;
+ S <<" *** NOT WELL LOADED : CONTENT FROM FILE ***"<<'\n';
else if (model->IsUnknownEntity(nument))
- S <<" *** UNKNOWN TYPE ***"<<std::endl;
+ S <<" *** UNKNOWN TYPE ***"<<'\n';
StepData_StepDumper dump(GetCasted(StepData_StepModel,model),
GetCasted(StepData_Protocol,protocol),thelabmode);
{
// WARNING : the field is redefined.
// field set up forbidden.
- std::cout << "Field is redefined, SetUp Forbidden" << std::endl;
+ std::cout << "Field is redefined, SetUp Forbidden" << '\n';
}
Handle(StepShape_HArray1OfFace) StepShape_OrientedClosedShell::CfsFaces() const
{
// WARNING : the field is redefined.
// field set up forbidden.
- std::cout << "Field is redefined, SetUp Forbidden" << std::endl;
+ std::cout << "Field is redefined, SetUp Forbidden" << '\n';
}
Handle(StepShape_Vertex) StepShape_OrientedEdge::EdgeStart() const
{
// WARNING : the field is redefined.
// field set up forbidden.
- std::cout << "Field is redefined, SetUp Forbidden" << std::endl;
+ std::cout << "Field is redefined, SetUp Forbidden" << '\n';
}
Handle(StepShape_Vertex) StepShape_OrientedEdge::EdgeEnd() const
{
// WARNING : the field is redefined.
// field set up forbidden.
- std::cout << "Field is redefined, SetUp Forbidden" << std::endl;
+ std::cout << "Field is redefined, SetUp Forbidden" << '\n';
}
Handle(StepShape_HArray1OfFaceBound) StepShape_OrientedFace::Bounds() const
{
// WARNING : the field is redefined.
// field set up forbidden.
- std::cout << "Field is redefined, SetUp Forbidden" << std::endl;
+ std::cout << "Field is redefined, SetUp Forbidden" << '\n';
}
Handle(StepShape_HArray1OfFace) StepShape_OrientedOpenShell::CfsFaces() const
{
// WARNING : the field is redefined.
// field set up forbidden.
- std::cout << "Field is redefined, SetUp Forbidden" << std::endl;
+ std::cout << "Field is redefined, SetUp Forbidden" << '\n';
}
Handle(StepShape_HArray1OfOrientedEdge) StepShape_OrientedPath::EdgeList() const
// Get Statistics :
if (theTP->TraceLevel() > 2)
{
- sout << "Geometric Statistics : " << std::endl;
- sout << " Surface Continuity : - C0 : " << aTool.C0Surf() << std::endl;
- sout << " - C1 : " << aTool.C1Surf() << std::endl;
- sout << " - C2 : " << aTool.C2Surf() << std::endl;
- sout << " Curve Continuity : - C0 : " << aTool.C0Cur3() << std::endl;
- sout << " - C1 : " << aTool.C1Cur3() << std::endl;
- sout << " - C2 : " << aTool.C2Cur3() << std::endl;
- sout << " PCurve Continuity : - C0 : " << aTool.C0Cur2() << std::endl;
- sout << " - C1 : " << aTool.C1Cur2() << std::endl;
- sout << " - C2 : " << aTool.C2Cur2() << std::endl;
+ sout << "Geometric Statistics : " << '\n';
+ sout << " Surface Continuity : - C0 : " << aTool.C0Surf() << '\n';
+ sout << " - C1 : " << aTool.C1Surf() << '\n';
+ sout << " - C2 : " << aTool.C2Surf() << '\n';
+ sout << " Curve Continuity : - C0 : " << aTool.C0Cur3() << '\n';
+ sout << " - C1 : " << aTool.C1Cur3() << '\n';
+ sout << " - C2 : " << aTool.C2Cur3() << '\n';
+ sout << " PCurve Continuity : - C0 : " << aTool.C0Cur2() << '\n';
+ sout << " - C1 : " << aTool.C1Cur2() << '\n';
+ sout << " - C2 : " << aTool.C2Cur2() << '\n';
}
ResetPreci (aStepModel, aSolid, MaxTol());
// Get Statistics :
if (theTP->TraceLevel() > 2)
{
- sout << "Geometric Statistics : " << std::endl;
- sout << " Surface Continuity : - C0 : " << aTool.C0Surf() << std::endl;
- sout << " - C1 : " << aTool.C1Surf() << std::endl;
- sout << " - C2 : " << aTool.C2Surf() << std::endl;
- sout << " Curve Continuity : - C0 : " << aTool.C0Cur3() << std::endl;
- sout << " - C1 : " << aTool.C1Cur3() << std::endl;
- sout << " - C2 : " << aTool.C2Cur3() << std::endl;
- sout << " PCurve Continuity : - C0 : " << aTool.C0Cur2() << std::endl;
- sout << " - C1 : " << aTool.C1Cur2() << std::endl;
- sout << " - C2 : " << aTool.C2Cur2() << std::endl;
+ sout << "Geometric Statistics : " << '\n';
+ sout << " Surface Continuity : - C0 : " << aTool.C0Surf() << '\n';
+ sout << " - C1 : " << aTool.C1Surf() << '\n';
+ sout << " - C2 : " << aTool.C2Surf() << '\n';
+ sout << " Curve Continuity : - C0 : " << aTool.C0Cur3() << '\n';
+ sout << " - C1 : " << aTool.C1Cur3() << '\n';
+ sout << " - C2 : " << aTool.C2Cur3() << '\n';
+ sout << " PCurve Continuity : - C0 : " << aTool.C0Cur2() << '\n';
+ sout << " - C1 : " << aTool.C1Cur2() << '\n';
+ sout << " - C2 : " << aTool.C2Cur2() << '\n';
}
//:S4136 ShapeFix::SameParameter (S,Standard_False);
if ( TP->TraceLevel() > 2 )
{
- sout << "Geometric Statistics : " << std::endl;
- sout << " Surface Continuity : - C0 : " << myTool.C0Surf() << std::endl;
- sout << " - C1 : " << myTool.C1Surf() << std::endl;
- sout << " - C2 : " << myTool.C2Surf() << std::endl;
- sout << " Curve Continuity : - C0 : " << myTool.C0Cur3() << std::endl;
- sout << " - C1 : " << myTool.C1Cur3() << std::endl;
- sout << " - C2 : " << myTool.C2Cur3() << std::endl;
- sout << " PCurve Continuity : - C0 : " << myTool.C0Cur2() << std::endl;
- sout << " - C1 : " << myTool.C1Cur2() << std::endl;
- sout << " - C2 : " << myTool.C2Cur2() << std::endl;
+ sout << "Geometric Statistics : " << '\n';
+ sout << " Surface Continuity : - C0 : " << myTool.C0Surf() << '\n';
+ sout << " - C1 : " << myTool.C1Surf() << '\n';
+ sout << " - C2 : " << myTool.C2Surf() << '\n';
+ sout << " Curve Continuity : - C0 : " << myTool.C0Cur3() << '\n';
+ sout << " - C1 : " << myTool.C1Cur3() << '\n';
+ sout << " - C2 : " << myTool.C2Cur3() << '\n';
+ sout << " PCurve Continuity : - C0 : " << myTool.C0Cur2() << '\n';
+ sout << " - C1 : " << myTool.C1Cur2() << '\n';
+ sout << " - C2 : " << myTool.C2Cur2() << '\n';
}
//:S4136 ShapeFix::SameParameter (S,Standard_False);
catch (Standard_Failure const& anException) {
Message_Messenger::StreamBuffer sout = TP->Messenger()->SendInfo();
sout << "StepToTopoDS, GeometricSet, elem " << i << " of " << nbElem << ": exception ";
- sout << anException.GetMessageString() << std::endl;
+ sout << anException.GetMessageString() << '\n';
}
if (!aGeomCrv.IsNull()) {
BRepBuilderAPI_MakeEdge anEdge(aGeomCrv, aGeomCrv->FirstParameter(), aGeomCrv->LastParameter());
//---------------------------------------------------------------------
void TCollection_HExtendedString::Print(Standard_OStream& S) const
{
- S << "begin class HExtendedString "<<std::endl;
+ S << "begin class HExtendedString "<<'\n';
myString.Print(S);
}
//
pStr=toto;
ID().ToCString(pStr);
- anOS<<";\tID = "<<toto<<std::endl;
+ anOS<<";\tID = "<<toto<<'\n';
return anOS;
}
Standard_OStream& TDF_Data::Dump(Standard_OStream& anOS) const
{
- anOS<<"Dump of a TDF_Data."<<std::endl;
+ anOS<<"Dump of a TDF_Data."<<'\n';
anOS<<"Current transaction: "<<myTransaction;
- anOS<<"; Current tick: "<<myTime<<";"<<std::endl;
+ anOS<<"; Current tick: "<<myTime<<";"<<'\n';
return anOS;
}
Standard_OStream& TDF_DataSet::Dump(Standard_OStream& anOS) const
{
- anOS<<"\t\t=====< TDF_DataSet dump >====="<<std::endl;
- anOS<<"Root Labels :"<<std::endl<<"============="<<std::endl;
+ anOS<<"\t\t=====< TDF_DataSet dump >====="<<'\n';
+ anOS<<"Root Labels :"<<'\n'<<"============="<<'\n';
for (TDF_ListIteratorOfLabelList itr1(myRootLabels);
itr1.More(); itr1.Next()) {
itr1.Value().EntryDump(anOS);
anOS<<" | ";
}
- anOS<<std::endl<<"Labels :"<<std::endl<<"========"<<std::endl;
+ anOS<<'\n'<<"Labels :"<<'\n'<<"========"<<'\n';
for (TDF_MapIteratorOfLabelMap itr2(myLabelMap);
itr2.More(); itr2.Next()) {
itr2.Key().EntryDump(anOS);
anOS<<" | ";
}
- anOS<<std::endl<<"Attributes :"<<std::endl<<"============"<<std::endl<<std::endl;
+ anOS<<'\n'<<"Attributes :"<<'\n'<<"============"<<'\n'<<'\n';
for (TDF_MapIteratorOfAttributeMap itr3(myAttributeMap);
itr3.More(); itr3.Next()) {
itr3.Key()->Label().EntryDump(anOS);
anOS<<" \t";
itr3.Key()->Dump(anOS);
- anOS<<std::endl;
+ anOS<<'\n';
}
- anOS<<std::endl;
+ anOS<<'\n';
return anOS;
}
void TDF_Delta::Dump(Standard_OStream& OS) const
{
- OS<<"DELTA available from time \t#"<<myBeginTime<<" to time \t#"<<myEndTime<<std::endl;
+ OS<<"DELTA available from time \t#"<<myBeginTime<<" to time \t#"<<myEndTime<<'\n';
Standard_Integer n = 0;
// for (TDF_ListIteratorOfAttributeDeltaList itr(myAttDeltaList);
TDF_ListIteratorOfAttributeDeltaList itr(myAttDeltaList) ;
for ( ; itr.More(); itr.Next()) ++n;
- OS<<"Nb Attribute Delta(s): "<<n<<std::endl;
+ OS<<"Nb Attribute Delta(s): "<<n<<'\n';
for (itr.Initialize(myAttDeltaList); itr.More(); itr.Next()) {
const Handle(TDF_AttributeDelta)& attDelta = itr.Value();
- OS<<"| "; attDelta->Dump(OS); OS<<std::endl;
+ OS<<"| "; attDelta->Dump(OS); OS<<'\n';
}
}
if (myIgnore) anOS<<"ignores"; else anOS<<"keeps "; anOS<<" all IDs";
TDF_MapIteratorOfIDMap itr(myIDMap);
if (itr.More()) {
- anOS<<" BUT:"<<std::endl;
+ anOS<<" BUT:"<<'\n';
for (; itr.More(); itr.Next()) {
const Standard_GUID& guid = itr.Key();
guid.ShallowDump(anOS);
- anOS<<std::endl;
+ anOS<<'\n';
}
}
}
if (AttributesModified()) anOS<<"HAS attributes"; else anOS<<"NO attribute"; anOS<<" modified; ";
if (HasAttribute()) {
Standard_Integer nba = NbAttributes();
- anOS<<"has "<<nba<<" attribute"; if (nba > 1) anOS<<"s"; anOS<<"."<<std::endl;
+ anOS<<"has "<<nba<<" attribute"; if (nba > 1) anOS<<"s"; anOS<<"."<<'\n';
for (TDF_AttributeIterator itr(myLabelNode); itr.More(); itr.Next()) {
// CLE
// const Handle(TDF_Attribute)& att = itr.Value();
}
}
else {
- anOS<<" has no attribute"<<std::endl;
+ anOS<<" has no attribute"<<'\n';
}
}
}
if (mySelfRelocate) anOS<<"IS"; else anOS<<"NOT";
anOS<<" self relocate ";
if (myAfterRelocate) anOS<<"WITH"; else anOS<<"WITHOUT";
- anOS<<" after relocate"<<std::endl;
+ anOS<<" after relocate"<<'\n';
anOS<<"Nb labels="<<myLabelTable.Extent();
anOS<<" Nb attributes="<<myAttributeTable.Extent();
- anOS<<" Nb transients="<<myTransientTable.Extent()<<std::endl;
+ anOS<<" Nb transients="<<myTransientTable.Extent()<<'\n';
Standard_Integer nb = 0;
if (dumpLabels) {
- anOS<<"Label Table:"<<std::endl;
+ anOS<<"Label Table:"<<'\n';
for (TDF_DataMapIteratorOfLabelDataMap itr(myLabelTable);
itr.More(); itr.Next()) {
++nb;
itr.Value().EntryDump(anOS);
anOS<<"| ";
}
- std::cout<<std::endl;
+ std::cout<<'\n';
}
nb = 0;
if (dumpAttributes) {
- anOS<<"Attribute Table:"<<std::endl;
+ anOS<<"Attribute Table:"<<'\n';
for (TDF_DataMapIteratorOfAttributeDataMap itr(myAttributeTable);
itr.More(); itr.Next()) {
++nb;
anOS<<"<=>";
itr.Value()->Dump(anOS);
anOS<<"| ";
- anOS<<std::endl;
+ anOS<<'\n';
}
}
if (dumpTransients) {
- anOS<<"Transient Table:"<<myTransientTable.Extent()<<" transient(s) in table."<<std::endl;
+ anOS<<"Transient Table:"<<myTransientTable.Extent()<<" transient(s) in table."<<'\n';
}
return anOS;
TDF_Tool_ExtendedDeepDump(anOS,aLabel,aFilter,map);
anOS<<map.Extent()<<" attribute"; if (map.Extent()>1) anOS<<"s";
- anOS<<" referenced by the label structure."<<std::endl;
+ anOS<<" referenced by the label structure."<<'\n';
- anOS<<std::endl<<"Extended dump of filtered attribute(s):"<<std::endl;
+ anOS<<'\n'<<"Extended dump of filtered attribute(s):"<<'\n';
Standard_Integer nba = 0;
TCollection_AsciiString entry;
Standard_Integer i ;
++nba;
anOS<<"# "<<i;
if (att->Label().IsNull()) {
- anOS<<" (no label)"<<std::endl;
+ anOS<<" (no label)"<<'\n';
}
else {
TDF_Tool::Entry(att->Label(),entry);
- anOS<<" (label: "<<entry<<")"<<std::endl;
+ anOS<<" (label: "<<entry<<")"<<'\n';
}
- att->ExtendedDump(anOS,aFilter,map); anOS<<std::endl;
+ att->ExtendedDump(anOS,aFilter,map); anOS<<'\n';
}
}
- anOS<<std::endl<<nba<<" attribute";
+ anOS<<'\n'<<nba<<" attribute";
if (nba>1) anOS<<"s";
- anOS<<" dumped between "<<--i<<std::endl;
+ anOS<<" dumped between "<<--i<<'\n';
}
anOS << " Name=|"<<myString<<"|";
Standard_Character sguid[Standard_GUID_SIZE_ALLOC];
myID.ToCString(sguid);
- anOS << sguid << "|" <<std::endl;
+ anOS << sguid << "|" <<'\n';
return anOS;
}
Standard_Character sguid[Standard_GUID_SIZE_ALLOC];
myID.ToCString(sguid);
anOS << sguid;
- anOS <<std::endl;
+ anOS <<'\n';
return anOS;
}
Standard_Character sguid[Standard_GUID_SIZE_ALLOC];
myID.ToCString(sguid);
anOS << sguid;
- anOS << std::endl;
+ anOS << '\n';
return anOS;
}
anOS << "\nByteArray: ";
Standard_Character sguid[Standard_GUID_SIZE_ALLOC];
myID.ToCString(sguid);
- anOS << sguid << std::endl;
+ anOS << sguid << '\n';
return anOS;
}
lower = myValue->Lower();
upper = myValue->Upper();
for(i = lower; i<=upper; i++)
- anOS << "\t" <<myValue->Value(i)<<std::endl;
+ anOS << "\t" <<myValue->Value(i)<<'\n';
}
anOS << " Delta is " << (myIsDelta ? "ON":"OFF");
Standard_Character sguid[Standard_GUID_SIZE_ALLOC];
myID.ToCString(sguid);
anOS << sguid;
- anOS << std::endl;
+ anOS << '\n';
return anOS;
}
Standard_Character sguid[Standard_GUID_SIZE_ALLOC];
myID.ToCString(sguid);
anOS << sguid;
- anOS << std::endl;
+ anOS << '\n';
return anOS;
}
Standard_OStream& anOS = TDF_Attribute::Dump( theOS );
anOS << "IntPackedMap size = " << Extent();
anOS << " Delta is " << (myIsDelta ? "ON":"OFF");
- anOS << std::endl;
+ anOS << '\n';
return anOS;
}
Standard_Character sguid[Standard_GUID_SIZE_ALLOC];
myID.ToCString(sguid);
anOS << sguid;
- anOS << std::endl;
+ anOS << '\n';
// anOS <<"\nAttribute fields: ";
// anOS << TDF_Attribute::Dump(anOS);
Standard_Character sguid[Standard_GUID_SIZE_ALLOC];
myID.ToCString(sguid);
anOS << sguid;
- anOS << std::endl;
+ anOS << '\n';
return anOS;
}
anOS << " Name=|"<<myString<<"|";
Standard_Character sguid[Standard_GUID_SIZE_ALLOC];
myID.ToCString(sguid);
- anOS << sguid << std::endl;
+ anOS << sguid << '\n';
return anOS;
}
Standard_Character sguid[Standard_GUID_SIZE_ALLOC];
myID.ToCString(sguid);
anOS << sguid;
- anOS << std::endl;
+ anOS << '\n';
return anOS;
}
Standard_Character sguid[Standard_GUID_SIZE_ALLOC];
myID.ToCString(sguid);
anOS << sguid;
- anOS << std::endl;
+ anOS << '\n';
return anOS;
}
anOS << "\nReferenceArray: ";
Standard_Character sguid[Standard_GUID_SIZE_ALLOC];
myID.ToCString(sguid);
- anOS << sguid << std::endl;
+ anOS << sguid << '\n';
return anOS;
}
Standard_Character sguid[Standard_GUID_SIZE_ALLOC];
myID.ToCString(sguid);
anOS << sguid;
- anOS << std::endl;
+ anOS << '\n';
return anOS;
}
anOS<<" Last=";
if (!myLast->Label().IsNull()) myLast->Label().EntryDump(anOS);
}
- anOS<<std::endl;
+ anOS<<'\n';
return anOS;
}
{
Standard_Integer i;
if(myDocuments.Length() == 0)
- anOS << "Manager is empty" << std::endl;
+ anOS << "Manager is empty" << '\n';
else {
if(myDocuments.Length() == 1)
anOS << "There is one document ( ";
anOS << "\"" << aDoc.get();
anOS << "\" ";
}
- anOS << ") in the manager " << std::endl;
+ anOS << ") in the manager " << '\n';
if(myIsNestedTransactionMode)
- anOS << "Nested transaction mode is on" << std::endl;
+ anOS << "Nested transaction mode is on" << '\n';
else
- anOS << "Nested transaction mode is off" << std::endl;
+ anOS << "Nested transaction mode is off" << '\n';
- anOS << " " << std::endl;
+ anOS << " " << '\n';
}
for (i = myUndos.Length(); i > 0; i--) {
anOS<<" Undo: ";
delta->Dump(anOS);
if (i == 1) {
- anOS<<" < Last action"<<std::endl;
+ anOS<<" < Last action"<<'\n';
} else {
- anOS<<std::endl;
+ anOS<<'\n';
}
}
for (i = 1; i <= myRedos.Length(); i++) {
Handle(TDocStd_ApplicationDelta) delta = myRedos.Value(i);
anOS<<" Redo: ";
delta->Dump(anOS);
- anOS<<std::endl;
+ anOS<<'\n';
}
}
//=======================================================================
Standard_OStream& TFunction_Iterator::Dump (Standard_OStream& anOS) const
{
- anOS << "Functions:" << std::endl ;
+ anOS << "Functions:" << '\n' ;
if (myCurrent.IsEmpty())
return anOS;
fIterator.Next();
- anOS << std::endl;
+ anOS << '\n';
}
// Recover the status of functions
TDF_MapIteratorOfLabelMap itr;
TCollection_AsciiString as;
- stream<<"Done = "<<isDone<<std::endl;
- stream<<"Touched labels: "<<std::endl;
+ stream<<"Done = "<<isDone<<'\n';
+ stream<<"Touched labels: "<<'\n';
for (itr.Initialize(myTouched); itr.More(); itr.Next())
{
TDF_Tool::Entry(itr.Key(), as);
- stream<<as<<std::endl;
+ stream<<as<<'\n';
}
- stream<<"Impacted labels: "<<std::endl;
+ stream<<"Impacted labels: "<<'\n';
for (itr.Initialize(myImpacted); itr.More(); itr.Next())
{
TDF_Tool::Entry(itr.Key(), as);
- stream<<as<<std::endl;
+ stream<<as<<'\n';
}
- stream<<"Valid labels: "<<std::endl;
+ stream<<"Valid labels: "<<'\n';
for (itr.Initialize(myValid); itr.More(); itr.Next())
{
TDF_Tool::Entry(itr.Key(), as);
- stream<<as<<std::endl;
+ stream<<as<<'\n';
}
return stream;
TNaming_DataMapOfShapePtrRefShape& amap)
{
if (oldShape.IsSame(newShape)) {
- std::cout <<"import_tool::Substitute : oldShape IsSame newShape"<<std::endl;
+ std::cout <<"import_tool::Substitute : oldShape IsSame newShape"<<'\n';
}
if (!amap.IsBound(oldShape)) {
theName.ContextLabel(aNamedShape->Label());
if (Geom) return aNamedShape;
if(aNamedShape.IsNull()) {
- std::cout <<" %%% WARNING: TNaming_Naming::Name: FAILED"<<std::endl;
+ std::cout <<" %%% WARNING: TNaming_Naming::Name: FAILED"<<'\n';
return BuildNS (F,S, TNaming_UNKNOWN);
}
if (!Geom && TestSolution(MDF, aNamedShape,S)) return aNamedShape;
- std::cout <<" %%% WARNING: TNaming_Naming::Name: FAILED"<<std::endl;
+ std::cout <<" %%% WARNING: TNaming_Naming::Name: FAILED"<<'\n';
// Naming n is unsatisfactory
return BuildNS (F,S, TNaming_UNKNOWN);
if (!Geom && TestSolution(MDF,NS,S)) return NS;
}
- std::cout <<" %%% WARNING: TNaming_Naming::Name: FAILED"<<std::endl;
+ std::cout <<" %%% WARNING: TNaming_Naming::Name: FAILED"<<'\n';
// Naming n is not satisfactory
return BuildNS (F,S, TNaming_UNKNOWN);
if (!myMap.Extent()) return;
else
- std::cout <<"TNaming_Translator:: IndexedDataMap Extent = "<< myMap.Extent() << std::endl;
+ std::cout <<"TNaming_Translator:: IndexedDataMap Extent = "<< myMap.Extent() << '\n';
for (Standard_Integer i=1; i <= myMap.Extent(); i++)
{
- std::cout <<"TNaming_Translator::DumpMap: Index = "<< i << " Type = "<< (myMap.FindKey(i))->DynamicType() << std::endl;
+ std::cout <<"TNaming_Translator::DumpMap: Index = "<< i << " Type = "<< (myMap.FindKey(i))->DynamicType() << '\n';
Handle(Standard_Type) T = (myMap.FindKey(i))->DynamicType();
if((T == STANDARD_TYPE (BRep_TVertex)) ||(T == STANDARD_TYPE (BRep_TEdge)) ||
T == STANDARD_TYPE (BRep_TFace)|| T == STANDARD_TYPE (TopoDS_TWire)||
if(isWrite) {
const Handle(TopLoc_Datum3D) key = Handle(TopLoc_Datum3D)::DownCast(myMap.FindKey(i));
const Handle(TopLoc_Datum3D) Item = Handle(TopLoc_Datum3D)::DownCast(myMap.FindFromIndex(i));
- std::cout << "TNaming_Translator::DumpMap: Location_Key_name = "<< keyname.Cat(i).ToCString()<< std::endl;
+ std::cout << "TNaming_Translator::DumpMap: Location_Key_name = "<< keyname.Cat(i).ToCString()<< '\n';
key->ShallowDump(std::cout);
- std::cout << "TNaming_Translator::DumpMap: Location_Item_name = "<< itemname.Cat(i).ToCString()<< std::endl;
+ std::cout << "TNaming_Translator::DumpMap: Location_Item_name = "<< itemname.Cat(i).ToCString()<< '\n';
Item->ShallowDump(std::cout);
}
}
else {
- std::cout <<"TNaming_Translator::DumpMap: Unexpected Type >> Idex = "<< i << " Type = "<<(myMap.FindKey(i))->DynamicType()<< std::endl;
+ std::cout <<"TNaming_Translator::DumpMap: Unexpected Type >> Idex = "<< i << " Type = "<<(myMap.FindKey(i))->DynamicType()<< '\n';
continue;
}
}
Standard_OStream& TNaming_UsedShapes::Dump(Standard_OStream& anOS) const
{
- anOS<<"The content of UsedShapes attribute:"<<std::endl;
+ anOS<<"The content of UsedShapes attribute:"<<'\n';
TNaming_DataMapIteratorOfDataMapOfShapePtrRefShape itr(myMap);
for (; itr.More(); itr.Next()) {
if (itr.Key().IsNull())
{
anOS << "Empty Shape at label =";
itr.Value()->Label().EntryDump(anOS);
- anOS << std::endl;
+ anOS << '\n';
continue;
}
anOS << " ";
itr.Value()->Label().EntryDump(anOS);
anOS << " Key_TShape = " <<itr.Key().TShape()->This();
anOS << " Value_TShape = " <<itr.Value()->Shape().TShape()->This();
- anOS<<std::endl;
+ anOS<<'\n';
}
return anOS;
}
TObj_DataMapOfStringPointer::Iterator it ( getMapOfTypes() );
for ( ; it.More(); it.Next() )
{
- theOs << it.Key() << std::endl;
+ theOs << it.Key() << '\n';
}
}
void TopLoc_Datum3D::ShallowDump(Standard_OStream& S) const
{
- S << " TopLoc_Datum3D " << (void*)this << std::endl;
+ S << " TopLoc_Datum3D " << (void*)this << '\n';
Standard_Integer i;
gp_Trsf T = myTrsf;
for (i = 1; i<=3; i++) {
S<<","<<std::setw(10)<<T.Value(i,4);
S<<")\n";
}
- S << std::endl;
+ S << '\n';
}
{
S << "TopLoc_Location : ";
TopLoc_SListOfItemLocation items = myItems;
- if (items.IsEmpty()) S << "Identity"<<std::endl;
+ if (items.IsEmpty()) S << "Identity"<<'\n';
while (items.More()) {
S<<"\n";
- S << " Exponent : " << items.Value().myPower <<std::endl;
+ S << " Exponent : " << items.Value().myPower <<'\n';
items.Value().myDatum->ShallowDump(S);
items.Next();
}
Standard_EXPORT Standard_Boolean GLOBAL_btcx = Standard_False;
Standard_EXPORT void debtcxmess(Standard_Integer f1,Standard_Integer f2,Standard_Integer il)
-{std::cout<<"f1,f2,il : "<<f1<<","<<f2<<","<<il<<std::endl;std::cout.flush();}
+{std::cout<<"f1,f2,il : "<<f1<<","<<f2<<","<<il<<'\n';std::cout.flush();}
//=======================================================================
//function : ProcessLine
if ( !More()) return;
TopAbs_State s1,s2; Current(s1,s2);
Standard_Boolean b = MYGTOPO.Value(s1,s2);
- TopOpeBRepBuild_GTopo::DumpSSB(OS,s1,s2,b); OS<<std::endl;
+ TopOpeBRepBuild_GTopo::DumpSSB(OS,s1,s2,b); OS<<'\n';
}
TopOpeBRepBuild_GTopo g;
g = TopOpeBRepBuild_GTool::GFusUnsh(TopAbs_FACE,TopAbs_FACE);
- g.Dump(OS); for (gi.Init(g); gi.More(); gi.Next()) gi.Dump(OS); OS<<std::endl;
+ g.Dump(OS); for (gi.Init(g); gi.More(); gi.Next()) gi.Dump(OS); OS<<'\n';
g = TopOpeBRepBuild_GTool::GFusSame(TopAbs_FACE,TopAbs_FACE);
- g.Dump(OS); for (gi.Init(g); gi.More(); gi.Next()) gi.Dump(OS); OS<<std::endl;
+ g.Dump(OS); for (gi.Init(g); gi.More(); gi.Next()) gi.Dump(OS); OS<<'\n';
g = TopOpeBRepBuild_GTool::GFusDiff(TopAbs_FACE,TopAbs_FACE);
- g.Dump(OS); for (gi.Init(g); gi.More(); gi.Next()) gi.Dump(OS); OS<<std::endl;
+ g.Dump(OS); for (gi.Init(g); gi.More(); gi.Next()) gi.Dump(OS); OS<<'\n';
g = TopOpeBRepBuild_GTool::GCutDiff(TopAbs_FACE,TopAbs_EDGE);
- g.Dump(OS); for (gi.Init(g); gi.More(); gi.Next()) gi.Dump(OS); OS<<std::endl;
+ g.Dump(OS); for (gi.Init(g); gi.More(); gi.Next()) gi.Dump(OS); OS<<'\n';
g = g.CopyPermuted();
- g.Dump(OS); for (gi.Init(g); gi.More(); gi.Next()) gi.Dump(OS); OS<<std::endl;
+ g.Dump(OS); for (gi.Init(g); gi.More(); gi.Next()) gi.Dump(OS); OS<<'\n';
}
DumpType(OS);
OS<<" "; TopOpeBRepDS::Print(myConfig1,OS);
OS<<" "; TopOpeBRepDS::Print(myConfig2,OS);
- OS<<std::endl;
+ OS<<'\n';
- if (myReverseForce) OS<<"reverse value : "<<myReverseValue<<std::endl;
+ if (myReverseForce) OS<<"reverse value : "<<myReverseValue<<'\n';
if(s) OS<<s;
OS<<"\\ I N O";
- OS<<std::endl;
+ OS<<'\n';
if(s) OS<<s;
OS<<"I ";
DumpVal(OS,TopAbs_IN,TopAbs_IN); OS<<" ";
DumpVal(OS,TopAbs_IN,TopAbs_ON); OS<<" ";
- DumpVal(OS,TopAbs_IN,TopAbs_OUT); OS<<std::endl;
+ DumpVal(OS,TopAbs_IN,TopAbs_OUT); OS<<'\n';
if(s) OS<<s;
OS<<"N ";
DumpVal(OS,TopAbs_ON,TopAbs_IN); OS<<" ";
DumpVal(OS,TopAbs_ON,TopAbs_ON); OS<<" ";
- DumpVal(OS,TopAbs_ON,TopAbs_OUT); OS<<std::endl;
+ DumpVal(OS,TopAbs_ON,TopAbs_OUT); OS<<'\n';
if(s) OS<<s;
OS<<"O ";
DumpVal(OS,TopAbs_OUT,TopAbs_IN); OS<<" ";
DumpVal(OS,TopAbs_OUT,TopAbs_ON); OS<<" ";
- DumpVal(OS,TopAbs_OUT,TopAbs_OUT); OS<<std::endl;
+ DumpVal(OS,TopAbs_OUT,TopAbs_OUT); OS<<'\n';
}
//=======================================================================
const Standard_Address astr) const
{
TopOpeBRepDS_Dumper Dumper(myDataStructure);
- std::cout<<Dumper.SPrintShapeRefOri(L,(char*)astr)<<std::endl;
+ std::cout<<Dumper.SPrintShapeRefOri(L,(char*)astr)<<'\n';
std::cout.flush();
}
break;
}
default: {
- std::cout << "Warning: given operation is unknown" << std::endl;
+ std::cout << "Warning: given operation is unknown" << '\n';
break;
}
} //end switch
Standard_Integer ires=RESUNDEF, icla1=SHEUNDEF, icla2=SHEUNDEF;
LocalKPisdisjanalyse(stsol1, stsol2, TopOpeBRepBuild_KPart_Operation_Fuse, ires, icla1, icla2);
if (ires == RESUNDEF || icla1 == SHEUNDEF || icla2 == SHEUNDEF || ires == RESNULL) {
- std::cout << "Warning: disjPerformFuse: can not determine solid's states" << std::endl;
+ std::cout << "Warning: disjPerformFuse: can not determine solid's states" << '\n';
continue;
}
if(ires == RESSHAPE12)
}
} //end while(j)
if(acheckiterator > aMaxNumberOfIterations) {
- std::cout << "disjPerformFuse: programming error" << std::endl;
+ std::cout << "disjPerformFuse: programming error" << '\n';
return Standard_False;
}
theMapOfResult.Add(acurrentsolid);
LocalKPisdisjanalyse(stsol1, stsol2, TopOpeBRepBuild_KPart_Operation_Common, ires, icla1, icla2);
if (ires == RESUNDEF || icla1 == SHEUNDEF || icla2 == SHEUNDEF) {
- std::cout << "Warning: disjPerformCommon: can not determine solid's states" << std::endl;
+ std::cout << "Warning: disjPerformCommon: can not determine solid's states" << '\n';
continue;
}
switch (ires) {
LocalKPisdisjanalyse(stsol1, stsol2, TopOpeBRepBuild_KPart_Operation_Cut12, ires, icla1, icla2);
if (ires == RESUNDEF || icla1 == SHEUNDEF || icla2 == SHEUNDEF) {
- std::cout << "Warning: disjPerformCut: can not determine solid's states" << std::endl;
+ std::cout << "Warning: disjPerformCut: can not determine solid's states" << '\n';
continue;
}
switch (ires) {
//=======================================================================
Standard_OStream& TopOpeBRepDS_Check::PrintIntg(Standard_OStream& OS)
{
- OS<<std::endl<<std::endl<<"************************************************"<<std::endl;
- OS<<"state of the DS : (only the tested elements)"<<std::endl<<std::endl;
+ OS<<'\n'<<'\n'<<"************************************************"<<'\n';
+ OS<<"state of the DS : (only the tested elements)"<<'\n'<<'\n';
//Display of the geometry
PrintMap(myMapSurfaceStatus, "Surface", OS);
PrintMap(MapFace, "Face", OS);
PrintMap(MapSolid, "Solid", OS);
- OS<<std::endl<<std::endl;
+ OS<<'\n'<<'\n';
return OS;
}
OS<<" "<<eltstr<<"\t(/"<<MapStat.Extent()<<")\tnumber ";
PrintElts(MapStat, TopOpeBRepDS_OK, b, OS);
- if(!b) OS<<" = OK"<<std::endl;
+ if(!b) OS<<" = OK"<<'\n';
PrintElts(MapStat, TopOpeBRepDS_NOK, b, OS);
- if(!b) OS<<" = NOK"<<std::endl;
+ if(!b) OS<<" = NOK"<<'\n';
}
return OS;
}
return OS;
}
if(!myMapShapeStatus.IsBound(index)) {
- OS<<"NO CHECK HAS PROCESSING"<<std::endl;
+ OS<<"NO CHECK HAS PROCESSING"<<'\n';
return OS;
}
OS<<" ";
{
std::cout<<"tsee f "<<BDS.Shape(ils.Value())<<";";
}
- std::cout<<"tsee e "<<is<<";### edge "<<is<<" connexity"<<std::endl;
+ std::cout<<"tsee e "<<is<<";### edge "<<is<<" connexity"<<'\n';
}
else if (ts == TopAbs_FACE)
{
{
std::cout<<"tsee f "<<BDS.Shape(ilf.Value())<<";";
}
- std::cout<<"tsee e "<<ie<<";### face "<<is<<" connexity"<<std::endl;
+ std::cout<<"tsee e "<<ie<<";### face "<<is<<" connexity"<<'\n';
}
}
}
}
Standard_EXPORT void FUN_tool_trace(const gp_Pnt2d p2d)
{
- std::cout<<" = ("<<p2d.X()<<" "<<p2d.Y()<<")"<<std::endl;
+ std::cout<<" = ("<<p2d.X()<<" "<<p2d.Y()<<")"<<'\n';
}
IS >> buffer;
if (strcmp(buffer,"Locations")) {
- std::cout << "Not a location table "<<std::endl;
+ std::cout << "Not a location table "<<'\n';
return;
}
} while (!IS.fail());
if (IS.fail()) {
- std::cout << "File was not written with this version of the topology"<<std::endl;
+ std::cout << "File was not written with this version of the topology"<<'\n';
IS.imbue (anOldLocale);
return;
}
myLocations.Read(IS, aPS.Next(10));
if (aPS.UserBreak()) {
- std::cout << "Interrupted by the user"<<std::endl;
+ std::cout << "Interrupted by the user"<<'\n';
// on remet le LC_NUMERIC a la precedente valeur
IS.imbue (anOldLocale);
return;
ReadGeometry(IS, aPS.Next(75));
if (aPS.UserBreak()) {
- std::cout << "Interrupted by the user"<<std::endl;
+ std::cout << "Interrupted by the user"<<'\n';
IS.imbue(anOldLocale);
return;
}
char buffer[255];
IS >> buffer;
if (strcmp(buffer,"TShapes")) {
- std::cout << "Not a TShape table"<<std::endl;
+ std::cout << "Not a TShape table"<<'\n';
// on remet le LC_NUMERIC a la precedente valeur
IS.imbue (anOldLocale);
return;
IS.imbue (anOldLocale);
if (aPS.UserBreak())
- std::cout << "Interrupted by the user" << std::endl;
+ std::cout << "Interrupted by the user" << '\n';
}
//=======================================================================
{
S<<"\n*******************************************************************\n";
if (mode == 1) { // Statistiques de base
- S<< "******** Basic Statistics ********"<<std::endl;
+ S<< "******** Basic Statistics ********"<<'\n';
Standard_Integer nbr = 0, nbe = 0, nbw = 0;
Standard_Integer i, max = NbMapped(), nbroots = NbRoots();
- S<< "**** Nb Final Results : "<< nbroots <<std::endl;
+ S<< "**** Nb Final Results : "<< nbroots <<'\n';
for (i = 1; i <= max; i ++) {
const Handle(Transfer_Binder)& binder = MapItem(i);
S<<"**** Warnings on : "<<Interface_MSG::Blanks(nbw,4)<<nbw<<" Entities\n";
S<<"*******************************************************************";
}
- S<<std::endl;
+ S<<'\n';
}
aSender << amsg.Value();
if (amsg.IsEdited() && thetrace > 2)
aSender << " [from: " << amsg.Original() << "]";
- aSender << std::endl;
+ aSender << '\n';
}
}
Message_Messenger::StreamBuffer aSender = themessenger->SendFail();
aSender << " --> Fail : " << mess;
if (orig[0] != '\0' && thetrace > 2) aSender << " [from: " << orig << "]";
- aSender << std::endl;
+ aSender << '\n';
}
}
Message_Messenger::StreamBuffer aSender = themessenger->SendWarning();
aSender << " --> Warning : " << mess;
if (orig[0] != '\0' && thetrace > 2) aSender << " [from: " << orig << "]";
- aSender << std::endl;
+ aSender << '\n';
}
}
case Transfer_StatusInitial:
break;
case Transfer_StatusDone:
- aSender << " .. and Transfer done" << std::endl;
+ aSender << " .. and Transfer done" << '\n';
return former;
case Transfer_StatusRun:
former->SetStatusExec(Transfer_StatusLoop);
case Transfer_StatusError:
if (thetrace)
{
- aSender << " *** Transfer in Error Status :" << std::endl;
+ aSender << " *** Transfer in Error Status :" << '\n';
StartTrace(former, start, thelevel, 0);
}
else StartTrace(former, start, thelevel, 4);
case Transfer_StatusLoop:
if (thetrace)
{
- aSender << " *** Transfer Head of Dead Loop :" << std::endl;
+ aSender << " *** Transfer Head of Dead Loop :" << '\n';
StartTrace(former, start, thelevel, 0);
}
else StartTrace(former, start, thelevel, 4);
{
if (binder.IsNull())
{
- aSender << " *** Dead Loop with no Result" << std::endl;
+ aSender << " *** Dead Loop with no Result" << '\n';
if (thetrace) StartTrace(binder, start, thelevel - 1, 0);
binder = new Transfer_VoidBinder;
Bind(start, binder); newbind = Standard_True;
{
if (thetrace)
{
- aSender << " *** Dead Loop : Finding head of Loop :" << std::endl;
+ aSender << " *** Dead Loop : Finding head of Loop :" << '\n';
StartTrace(binder, start, thelevel - 1, 0);
}
else StartTrace(binder, start, thelevel - 1, 4);
{
if (thetrace)
{
- aSender << " *** Dead Loop : Actor in Loop :" << std::endl;
+ aSender << " *** Dead Loop : Actor in Loop :" << '\n';
StartTrace(binder, start, thelevel - 1, 0);
}
}
{
if (binder.IsNull())
{
- aSender << " *** Exception Raised with no Result" << std::endl;
+ aSender << " *** Exception Raised with no Result" << '\n';
binder = new Transfer_VoidBinder;
Bind(start, binder); newbind = Standard_True;
}
binder->AddFail("Transfer stopped by exception raising");
if (thetrace)
{
- aSender << " *** Raised : " << anException.GetMessageString() << std::endl;
+ aSender << " *** Raised : " << anException.GetMessageString() << '\n';
StartTrace(binder, start, thelevel - 1, 4);
}
thelevel = oldlev;
aSender << "\n --- No Result recorded";
}
}
- aSender << std::endl;
+ aSender << '\n';
}
//=======================================================================
aSender << amsg.Value();
if (amsg.IsEdited() && thetrace > 2)
aSender << " [from: " << amsg.Original() << "]";
- aSender << std::endl;
+ aSender << '\n';
}
}
Message_Messenger::StreamBuffer aSender = themessenger->SendFail();
aSender << " --> Fail : " << mess;
if (orig[0] != '\0' && thetrace > 2) aSender << " [from: " << orig << "]";
- aSender << std::endl;
+ aSender << '\n';
}
}
Message_Messenger::StreamBuffer aSender = themessenger->SendWarning();
aSender << " --> Warning : " << mess;
if (orig[0] != '\0' && thetrace > 2) aSender << " [from: " << orig << "]";
- aSender << std::endl;
+ aSender << '\n';
}
}
case Transfer_StatusInitial:
break;
case Transfer_StatusDone:
- aSender << " .. and Transfer done" << std::endl;
+ aSender << " .. and Transfer done" << '\n';
return former;
case Transfer_StatusRun:
former->SetStatusExec(Transfer_StatusLoop);
case Transfer_StatusError:
if (thetrace)
{
- aSender << " *** Transfer in Error Status :" << std::endl;
+ aSender << " *** Transfer in Error Status :" << '\n';
StartTrace(former, start, thelevel, 0);
}
else StartTrace(former, start, thelevel, 4);
case Transfer_StatusLoop:
if (thetrace)
{
- aSender << " *** Transfer Head of Dead Loop :" << std::endl;
+ aSender << " *** Transfer Head of Dead Loop :" << '\n';
StartTrace(former, start, thelevel, 0);
}
else StartTrace(former, start, thelevel, 4);
{
if (binder.IsNull())
{
- aSender << " *** Dead Loop with no Result" << std::endl;
+ aSender << " *** Dead Loop with no Result" << '\n';
if (thetrace) StartTrace(binder, start, thelevel - 1, 0);
binder = new Transfer_VoidBinder;
Bind(start, binder); newbind = Standard_True;
{
if (thetrace)
{
- aSender << " *** Dead Loop : Finding head of Loop :" << std::endl;
+ aSender << " *** Dead Loop : Finding head of Loop :" << '\n';
StartTrace(binder, start, thelevel - 1, 0);
}
else StartTrace(binder, start, thelevel - 1, 4);
{
if (thetrace)
{
- aSender << " *** Dead Loop : Actor in Loop :" << std::endl;
+ aSender << " *** Dead Loop : Actor in Loop :" << '\n';
StartTrace(binder, start, thelevel - 1, 0);
}
}
{
if (binder.IsNull())
{
- aSender << " *** Exception Raised with no Result" << std::endl;
+ aSender << " *** Exception Raised with no Result" << '\n';
binder = new Transfer_VoidBinder;
Bind(start, binder); newbind = Standard_True;
}
binder->AddFail("Transfer stopped by exception raising");
if (thetrace)
{
- aSender << " *** Raised : " << anException.GetMessageString() << std::endl;
+ aSender << " *** Raised : " << anException.GetMessageString() << '\n';
StartTrace(binder, start, thelevel - 1, 4);
}
thelevel = oldlev;
aSender << "\n --- No Result recorded";
}
}
- aSender << std::endl;
+ aSender << '\n';
}
//=======================================================================
{
S<<"\n*******************************************************************\n";
// if (mode == 1) { // Statistiques de base
- S<< "******** Basic Statistics ********"<<std::endl;
+ S<< "******** Basic Statistics ********"<<'\n';
Handle(Interface_InterfaceModel) model = Model();
- if (model.IsNull()) S<<"**** Model unknown"<<std::endl;
+ if (model.IsNull()) S<<"**** Model unknown"<<'\n';
else
- S<<"**** Nb Entities : "<<model->NbEntities()<<std::endl;
+ S<<"**** Nb Entities : "<<model->NbEntities()<<'\n';
Standard_Integer nbr = 0, nbe = 0, nbw = 0;
Standard_Integer i, max = NbMapped(), nbroots = NbRoots();
- S<< "**** Nb Final Results : "<<nbroots<<std::endl;
+ S<< "**** Nb Final Results : "<<nbroots<<'\n';
for (i = 1; i <= max; i ++) {
const Handle(Transfer_Binder)& binder = MapItem(i);
S<<"**** Warnings on : "<<Interface_MSG::Blanks(nbw,4)<<nbw<<" Entities\n";
S<<"*******************************************************************";
// }
- S<<std::endl;
+ S<<'\n';
}
Message_Messenger::StreamBuffer sout = theProc->Messenger()->SendInfo();
sout<<"-- Transfer(Read) : ";
theModel->Print (ent, sout);
- sout<<std::endl;
+ sout<<'\n';
}
TP.Transfer(ent, theProgress);
theProc->SetRoot(ent);
Message_Messenger::StreamBuffer sout = theProc->Messenger()->SendInfo();
if (theProc->TraceLevel() > 1)
- sout<<"-- Transfer(Read-List) : "<<nb<<" Items"<<std::endl;
+ sout<<"-- Transfer(Read-List) : "<<nb<<" Items"<<'\n';
Message_ProgressScope aPS(theProgress, NULL, nb);
for (i = 1; i <= nb && aPS.More(); i++) {
Message_ProgressRange aRange = aPS.Next();
{
sout<<"-- Transfer(Read-List), Item "<<i<<" : ";
theModel->Print (ent, sout);
- sout<<std::endl;
+ sout<<'\n';
}
TP.Transfer (ent, aRange);
theProc->SetRoot(ent);
{
int i;
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" with the physical dimensions : "<<std::endl;
+ std::cout<<" with the physical dimensions : "<<'\n';
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" mass : "<<themass<<std::endl;
+ std::cout<<" mass : "<<themass<<'\n';
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" length : "<<thelength<<std::endl;
+ std::cout<<" length : "<<thelength<<'\n';
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" time : "<<thetime<<std::endl;
+ std::cout<<" time : "<<thetime<<'\n';
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" electric current : "<<theelectriccurrent<<std::endl;
+ std::cout<<" electric current : "<<theelectriccurrent<<'\n';
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" thermodynamic temperature : "<<thethermodynamictemperature<<std::endl;
+ std::cout<<" thermodynamic temperature : "<<thethermodynamictemperature<<'\n';
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" amount of substance : "<<theamountofsubstance<<std::endl;
+ std::cout<<" amount of substance : "<<theamountofsubstance<<'\n';
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" luminous intensity : "<<theluminousintensity<<std::endl;
+ std::cout<<" luminous intensity : "<<theluminousintensity<<'\n';
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" plane angle : "<<theplaneangle<<std::endl;
+ std::cout<<" plane angle : "<<theplaneangle<<'\n';
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" solid angle : "<<thesolidangle<<std::endl;
+ std::cout<<" solid angle : "<<thesolidangle<<'\n';
}
//=======================================================================
Handle(Units_Token) oldtoken = thetoken;
Units_UnitSentence newunit(aunit);
if(!newunit.IsDone()) {
- std::cout<<"Units_Measurement: can not convert - incorrect unit => result is not correct"<<std::endl;
+ std::cout<<"Units_Measurement: can not convert - incorrect unit => result is not correct"<<'\n';
return;
}
Handle(Units_Token) newtoken=newunit.Evaluate();
void Units_Measurement::Dump() const
{
- std::cout<<" Measurement : "<<themeasurement<<std::endl;
+ std::cout<<" Measurement : "<<themeasurement<<'\n';
thetoken->Dump(1,1);
}
const Standard_Integer alevel) const
{
Standard_Integer index;
- std::cout<<std::endl;
+ std::cout<<'\n';
for(int i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<Name()<<std::endl;
+ std::cout<<Name()<<'\n';
// thedimensions->Dump(ashift+1);
if(alevel > 0)
{
{
Units_Token::Dump(ashift,alevel);
for(int i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" move : "<<themove<<std::endl;
+ std::cout<<" move : "<<themove<<'\n';
}
if(index != 1) std::cout << " or " ;
std::cout<<"\""<<string.ToCString()<<"\"";
}
- std::cout<< " Name: " <<Name().ToCString()<<" (= *" << thevalue << " SI + " << themove << ")"<<std::endl;
+ std::cout<< " Name: " <<Name().ToCString()<<" (= *" << thevalue << " SI + " << themove << ")"<<'\n';
}
{
TCollection_AsciiString string = Mean();
if(string.Search(amean) != -1)
- std::cout<<Word()<<" encountered twice with the same signification : "<<amean<<std::endl;
+ std::cout<<Word()<<" encountered twice with the same signification : "<<amean<<'\n';
string = string + amean;
themean = string;
}
TCollection_AsciiString mean = Mean();
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout << "Units_Token::Dump of " << this << std::endl;
+ std::cout << "Units_Token::Dump of " << this << '\n';
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<word.ToCString()<<std::endl;
+ std::cout<<word.ToCString()<<'\n';
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" value : "<<thevalue<<std::endl;
+ std::cout<<" value : "<<thevalue<<'\n';
for(i=0; i<ashift; i++)std::cout<<" ";
- std::cout<<" mean : "<<mean.ToCString()<<std::endl;
+ std::cout<<" mean : "<<mean.ToCString()<<'\n';
if(alevel)thedimensions->Dump(ashift);
}
if(index != 1) std::cout << " or " ;
std::cout<<"\""<<string.ToCString()<<"\"";
}
- std::cout<< " Name: " <<Name().ToCString()<<" (= " << thevalue << " SI)" <<std::endl;
+ std::cout<< " Name: " <<Name().ToCString()<<" (= " << thevalue << " SI)" <<'\n';
}
//=======================================================================
}
}
- std::cout<<" La grandeur physique "<<aquantity<<" n'existe pas."<<std::endl;
+ std::cout<<" La grandeur physique "<<aquantity<<" n'existe pas."<<'\n';
return "";
}
Units_UnitSentence unitsentence(aunit);
if(!unitsentence.IsDone()) {
- std::cout<<"Units_UnitsSystem::Specify : incorrect unit"<<std::endl;
+ std::cout<<"Units_UnitsSystem::Specify : incorrect unit"<<'\n';
return;
}
Handle(Units_Token) token = unitsentence.Evaluate();
// Units_NoSuchType_Raise_if(quantity.IsNull(),aquantity);
if( quantity.IsNull() ) {
- std::cout<<"Warning: in Units_UnitsSystem : Units_NoSuchType '" << aquantity << "'" << std::endl;
+ std::cout<<"Warning: in Units_UnitsSystem : Units_NoSuchType '" << aquantity << "'" << '\n';
return;
}
{
Units_UnitSentence unitsentence(aunit);
if(!unitsentence.IsDone()) {
- std::cout<<"Units_UnitsSystem::ConvertValueToUserSystem : incorrect unit => return 0"<<std::endl;
+ std::cout<<"Units_UnitsSystem::ConvertValueToUserSystem : incorrect unit => return 0"<<'\n';
return 0.;
}
return ConvertSIValueToUserSystem(aquantity,avalue*(unitsentence.Evaluate())->Value());
Handle(Standard_Transient) transient = This();
Handle(Units_UnitsSystem) unitssystem = Handle(Units_UnitsSystem)::DownCast (transient);
Units_Explorer explorer(unitssystem);
- std::cout<<" UNITSSYSTEM : "<<std::endl;
+ std::cout<<" UNITSSYSTEM : "<<'\n';
for(; explorer.MoreQuantity(); explorer.NextQuantity()) {
- std::cout<<explorer.Quantity()<<std::endl;
+ std::cout<<explorer.Quantity()<<'\n';
for(; explorer.MoreUnit(); explorer.NextUnit())
- std::cout<<" "<<explorer.Unit()<<std::endl;
+ std::cout<<" "<<explorer.Unit()<<'\n';
}
}
//===============================================================================================
void ViewerTest_CmdParser::PrintHelp() const
{
- std::cout << myDescription << std::endl;
+ std::cout << myDescription << '\n';
std::vector<CommandOption>::const_iterator anIt = myOptionStorage.begin();
for (++anIt; anIt != myOptionStorage.end(); ++anIt)
{
}
std::cout << " : " << aCommandOption.Description;
}
- std::cout << std::endl;
+ std::cout << '\n';
}
//===============================================================================================
{
std::cout << " connected to " << aMap.Find1 (aConnected->ConnectedTo());
}
- std::cout << std::endl;
+ std::cout << '\n';
++aCounter;
}
if (anInterObj->HasPolygonOffsets())
{
anInterObj->PolygonOffsets(aMode, aFactor, aUnits);
- std::cout << "Current polygon offset parameters for " << argv[1] << ":" << std::endl;
- std::cout << "\tMode: " << aMode << std::endl;
- std::cout << "\tFactor: " << aFactor << std::endl;
- std::cout << "\tUnits: " << aUnits << std::endl;
+ std::cout << "Current polygon offset parameters for " << argv[1] << ":" << '\n';
+ std::cout << "\tMode: " << aMode << '\n';
+ std::cout << "\tFactor: " << aFactor << '\n';
+ std::cout << "\tUnits: " << aUnits << '\n';
return 0;
}
else
{
- std::cout << "Specific polygon offset parameters are not set for " << argv[1] << std::endl;
+ std::cout << "Specific polygon offset parameters are not set for " << argv[1] << '\n';
}
}
- std::cout << "Default polygon offset parameters:" << std::endl;
+ std::cout << "Default polygon offset parameters:" << '\n';
aContext->DefaultDrawer()->ShadingAspect()->Aspect()->PolygonOffsets(aMode, aFactor, aUnits);
- std::cout << "\tMode: " << aMode << std::endl;
- std::cout << "\tFactor: " << aFactor << std::endl;
- std::cout << "\tUnits: " << aUnits << std::endl;
+ std::cout << "\tMode: " << aMode << '\n';
+ std::cout << "\tFactor: " << aFactor << '\n';
+ std::cout << "\tUnits: " << aUnits << '\n';
return 0;
}
Standard_CString aWarnLog = theDI.Result();
if (aWarnLog != NULL && aWarnLog[0] != '\0')
{
- std::cout << aWarnLog << std::endl;
+ std::cout << aWarnLog << '\n';
}
theDI.Reset();
{
if (theNbArgs != 7)
{
- std::cerr << "Error: command syntax is incorrect, see help" << std::endl;
+ std::cerr << "Error: command syntax is incorrect, see help" << '\n';
return 1;
}
}
}
else {
- std::cout << "Cannot evaluate curve on surface"<<std::endl;
+ std::cout << "Cannot evaluate curve on surface"<<'\n';
}
}
else {
for (; i <= NbFathers(); i++) {
if ( !myFathers(i)->Label().IsNull() )
myFathers(i)->Label().EntryDump(anOS);
- anOS<<std::endl;
+ anOS<<'\n';
}
}
i = 1;
for (; i <= NbChildren(); i++) {
if ( !myChildren(i)->Label().IsNull() )
myChildren(i)->Label().EntryDump(anOS);
- anOS<<std::endl;
+ anOS<<'\n';
}
}
// anOS<<std::endl;
anOS << " UnitScaleValue=|" << myUnitScaleValue << "|";
Standard_Character aSGUID[Standard_GUID_SIZE_ALLOC];
ID().ToCString(aSGUID);
- anOS << aSGUID << "|" << std::endl;
+ anOS << aSGUID << "|" << '\n';
return anOS;
}
theDumpLog<<", "<< *(void**)&S.Location();
theDumpLog<<") ";
}
- theDumpLog<<std::endl;
+ theDumpLog<<'\n';
Handle(TDataStd_TreeNode) Node;
TDF_ChildIterator NodeIterator(L);
DumpAssembly(theDumpLog, NodeIterator.Value(), level+1, deep);
}
if(level == 0)
- theDumpLog<<std::endl;
+ theDumpLog<<'\n';
}
//=======================================================================
TDF_LabelSequence SeqLabels;
GetShapes( SeqLabels);
- if (SeqLabels.Length()>0) theDumpLog<<std::endl;
+ if (SeqLabels.Length()>0) theDumpLog<<'\n';
Standard_Integer i;
for (i=1; i<=SeqLabels.Length(); i++) {
DumpAssembly(theDumpLog, SeqLabels.Value(i), level, deep);
SeqLabels.Clear();
GetFreeShapes(SeqLabels);
- theDumpLog<<std::endl<<"Free Shapes: "<<SeqLabels.Length()<<std::endl;
+ theDumpLog<<'\n'<<"Free Shapes: "<<SeqLabels.Length()<<'\n';
for (i = 1; i<=SeqLabels.Length(); i++) {
DumpShape(theDumpLog, SeqLabels.Value(i), level, deep);
- theDumpLog<<std::endl;
+ theDumpLog<<'\n';
}
return theDumpLog;
}
}
aSS << anIt.Value();
}
- aSS << std::endl;
+ aSS << '\n';
}
else
{
- aSS << theItem.ToString() << std::endl;
+ aSS << theItem.ToString() << '\n';
}
return Standard_True;
});
aSS << " " << anIt1.Key();
}
}
- aSS << std::endl;
+ aSS << '\n';
return Standard_True;
}
}
aSS << theNode << " " << graphNodeTypename(aNodeType) << " " << aNodeEntry << " "
- << theGraph->NbOccurrences(theNode) << std::endl;
+ << theGraph->NbOccurrences(theNode) << '\n';
return Standard_True;
}
{
if( argc < 2 )
{
- std::cout<<"Invalid numbers of arguments should be: XTestDoc shape"<<std::endl;
+ std::cout<<"Invalid numbers of arguments should be: XTestDoc shape"<<'\n';
return 1;
}
TopoDS_Shape shape = DBRep::Get(argv[1]);
gp_Pln aPlane;
Handle(Geom_Plane) aSurf = Handle(Geom_Plane)::DownCast(DrawTrSurf::GetSurface(argv[2]));
if (aSurf.IsNull()) {
- std::cout << argv[2] << " is not a plane" << std::endl;
+ std::cout << argv[2] << " is not a plane" << '\n';
return 1;
}
aPlane = aSurf->Pln();
const Standard_CString arg3 = pilot->Arg(3);
const Handle(Transfer_TransientProcess) &TP = XSControl::Session(pilot)->TransferReader()->TransientProcess();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (TP.IsNull()) { sout<<"No Transfer Read"<<std::endl; return IFSelect_RetError;}
+ if (TP.IsNull()) { sout<<"No Transfer Read"<<'\n'; return IFSelect_RetError;}
// **** tpdraw ****
if (argc < 2) {
- sout<<"Donner [mode facultatif : item ou root] , NUMERO , nom DRAW facultatif"<<std::endl;
- sout<<" mode si present : item ou root, sinon n0 d entite modele"<<std::endl;
+ sout<<"Donner [mode facultatif : item ou root] , NUMERO , nom DRAW facultatif"<<'\n';
+ sout<<" mode si present : item ou root, sinon n0 d entite modele"<<'\n';
sout<<" NUMERO entier : d entite, d item transfert ou de root transfert\n"
- << " ou * pour dire tous"<<std::endl;
+ << " ou * pour dire tous"<<'\n';
return IFSelect_RetError;
}
Standard_Integer mode = 0, num=0;
else if (arg1[0] == 'r') mode = 2;
Standard_Boolean tout = Standard_False;
if (mode == 0) {
- if (argc < 2) { sout<<"Donner au moins un NUMERO ou *"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Donner au moins un NUMERO ou *"<<'\n'; return IFSelect_RetError; }
if (arg1[0] == '*') tout = Standard_True;
else num = IFSelect_Functions::GiveEntityNumber(XSControl::Session(pilot),arg1);
} else {
Handle(Interface_InterfaceModel) model = TP->Model();
if (model.IsNull()) {
if (mode == 0) {
- sout<<"Pas de modele, preciser n0 d item de transfert"<<std::endl;
+ sout<<"Pas de modele, preciser n0 d item de transfert"<<'\n';
return IFSelect_RetError;
}
}
if (mode == 2) { sout<<"Racine de transfert"; max = TP->NbRoots(); }
if (tout) {
n1 = 1; n2 = max;
- sout<<", listage de 1 a "<<max<<std::endl;
+ sout<<", listage de 1 a "<<max<<'\n';
}
else if (num <= 0 || num > max) {
- sout<<" - Num="<<num<<" hors limite (de 1 a "<<max<<")"<<std::endl;
+ sout<<" - Num="<<num<<" hors limite (de 1 a "<<max<<")"<<'\n';
return IFSelect_RetError;
} else {
n1 = n2 = num; nbvar = -1; // nbvar : 1ere shape simple = pas de n0
- sout<<", n0 "<<num<<std::endl;
+ sout<<", n0 "<<num<<'\n';
}
for (i = n1; i <= n2; i ++) {
if (index > 0) binder = TP->MapItem (index);
if (binder.IsNull()) index = 0;
if (index == 0) {
- if (!tout) sout<<"Entite n0 "<<num<<" : non repertoriee"<<std::endl;
+ if (!tout) sout<<"Entite n0 "<<num<<" : non repertoriee"<<'\n';
continue;
}
if (!binder->HasResult()) {
- if (!tout) sout<<"Entite n0 "<<num<<" : pas de resultat"<<std::endl;
+ if (!tout) sout<<"Entite n0 "<<num<<" : pas de resultat"<<'\n';
continue;
}
sh = TransferBRep::ShapeResult (binder);
if (!sh.IsNull()) {
//sh = shb->Result();
nbvar ++;
- if (sh.IsNull()) { sout<<" (no Shape recorded)"<<std::endl; continue; }
+ if (sh.IsNull()) { sout<<" (no Shape recorded)"<<'\n'; continue; }
if (tout) sout<<"[ "<<i<<" ]:";
if (num == 0) sout<<" pas dans le modele";
else sout<<" ent.n0 "<<num;
else if (argc > 2 && mode == 0) sprintf (nomvar,"%s_%d",arg2,nbvar);
else sprintf (nomvar,"tp_%d",i);
}
- sout<<" -> 1 DRAW Shape: "<<nomvar<<std::endl;
+ sout<<" -> 1 DRAW Shape: "<<nomvar<<'\n';
XSControl::Vars(pilot)->SetShape(nomvar,sh);
continue;
}
sout<<" -> "<<nbs<<" DRAW Shapes :";
for (Standard_Integer j = 1; j <= nbs; j ++) {
sh = slb->Shape(j); if (nbvar < 0) nbvar = 0; nbvar ++;
- if (sh.IsNull()) { sout<<" (no Shape recorded)"<<std::endl; continue; }
+ if (sh.IsNull()) { sout<<" (no Shape recorded)"<<'\n'; continue; }
if (argc > 3 && mode > 0) sprintf (nomvar,"%s_%d",arg3,nbvar);
else if (argc > 2 && mode == 0) sprintf (nomvar,"%s_%d",arg2,nbvar);
else sprintf (nomvar,"tp_%d_%d",i,nbvar);
sout<<" "<<nomvar;
XSControl::Vars(pilot)->SetShape(nomvar,sh);
}
- sout<<std::endl;
+ sout<<'\n';
continue;
}
DeclareAndCast(Transfer_SimpleBinderOfTransient,trb,binder);
if (!trb.IsNull()) {
Handle(Standard_Transient) resu = trb->Result();
if (resu.IsNull()) {
- sout<<"Entite n0 "<<num<<" : pas de resultat"<<std::endl;
+ sout<<"Entite n0 "<<num<<" : pas de resultat"<<'\n';
continue;
}
DeclareAndCast(Geom_Geometry,geom,resu);
sout<<"Entite n0 "<<num<<" : resultat "<<resu->DynamicType()->Name();
- if (geom.IsNull()) { sout<<std::endl; continue; }
+ if (geom.IsNull()) { sout<<'\n'; continue; }
nbvar ++;
if (nbvar == 0) {
if (argc > 3 && mode > 0) sprintf (nomvar,"%s",arg3);
}
char* nomv = nomvar;
XSControl::Vars(pilot)->Set (nomv,geom);
- sout<<" -> DRAW Geom : "<<nomvar<<std::endl;
+ sout<<" -> DRAW Geom : "<<nomvar<<'\n';
continue;
}
if (sh.IsNull() && trb.IsNull())
- if (!tout) sout<<"Entite n0 "<<num<<" : resultat pas une Shape mais "<<binder->ResultTypeName()<<std::endl;
+ if (!tout) sout<<"Entite n0 "<<num<<" : resultat pas une Shape mais "<<binder->ResultTypeName()<<'\n';
}
- if (sh.IsNull()) sout<<" (No Shape)"<<std::endl;
+ if (sh.IsNull()) sout<<" (No Shape)"<<'\n';
return IFSelect_RetDone;
}
const Standard_CString arg1 = pilot->Arg(1);
const Handle(Transfer_TransientProcess) &TP = XSControl::Session(pilot)->TransferReader()->TransientProcess();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (TP.IsNull()) { sout<<"No Transfer Read"<<std::endl; return IFSelect_RetError;}
+ if (TP.IsNull()) { sout<<"No Transfer Read"<<'\n'; return IFSelect_RetError;}
// **** tpcompound ****
- if (argc < 2) { sout<<"Give a NAME for the Compound + optional givelist, else roots are taken"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Give a NAME for the Compound + optional givelist, else roots are taken"<<'\n'; return IFSelect_RetError; }
Handle(TopTools_HSequenceOfShape) list;
if (argc == 2) list = TransferBRep::Shapes(TP);
else {
Handle(TColStd_HSequenceOfTransient) lise = IFSelect_Functions::GiveList(pilot->Session(),pilot->CommandPart(2));
- if (lise.IsNull()) { sout<<"Not a valid entity list : "<<pilot->CommandPart(2)<<std::endl; return IFSelect_RetError; }
+ if (lise.IsNull()) { sout<<"Not a valid entity list : "<<pilot->CommandPart(2)<<'\n'; return IFSelect_RetError; }
list = TransferBRep::Shapes (TP,lise);
sout<<lise->Length()<<" Entities, ";
}
- if (list.IsNull()) { sout<<"No Shape listed"<<std::endl; return IFSelect_RetError; }
+ if (list.IsNull()) { sout<<"No Shape listed"<<'\n'; return IFSelect_RetError; }
Standard_Integer nb = list->Length();
- sout<<nb<<" Shape(s) listed"<<std::endl;
+ sout<<nb<<" Shape(s) listed"<<'\n';
TopoDS_Compound C;
BRep_Builder B;
B.MakeCompound(C);
TCollection_AsciiString nomsh, noms;
const Handle(XSControl_TransferReader) &TR = XSControl::Session(pilot)->TransferReader();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (TR.IsNull()) { sout<<" manque init"<<std::endl; return IFSelect_RetError; }
+ if (TR.IsNull()) { sout<<" manque init"<<'\n'; return IFSelect_RetError; }
const Handle(Interface_InterfaceModel) &mdl = TR->Model();
- if (mdl.IsNull()) { sout<<" modele absent"<<std::endl; return IFSelect_RetError; }
+ if (mdl.IsNull()) { sout<<" modele absent"<<'\n'; return IFSelect_RetError; }
Standard_Integer num = (argc > 1 ? IFSelect_Functions::GiveEntityNumber(XSControl::Session(pilot),arg1) : 0);
if (argc > 1) nomsh = arg1;
else nomsh = cascomp ? "TREAD_COMP" : "TREAD_LIST";
- if (cassave) sout<<" save shapes -> current directory"<<std::endl;
+ if (cassave) sout<<" save shapes -> current directory"<<'\n';
if (num == 0 || cascomp) {
TopoDS_Compound C; // pour cas compound
B.MakeCompound(C);
const Handle(TopTools_HSequenceOfShape) &list = TR->ShapeResultList(Standard_True);
- sout<<" TOUS RESULTATS par ShapeResultList, soit "<<list->Length()<<std::endl;
+ sout<<" TOUS RESULTATS par ShapeResultList, soit "<<list->Length()<<'\n';
for (Standard_Integer i = 1, nb = list->Length(); i <= nb; ++i)
{
noms = nomsh + "_" + i;
- if ( (i%1000) == 0) sout<<"("<<i<<")"<<std::endl;
+ if ( (i%1000) == 0) sout<<"("<<i<<")"<<'\n';
else if ( (i%100) == 0) sout<<"*";
else if ( (i%10) == 0) sout<<"0";
else sout<<".";
else if (!cascomp && cassave) BRepTools::Write (list->Value(i), noms.ToCString());
else if (cascomp) B.Add (C,list->Value(i));
}
- sout<<std::endl;
+ sout<<'\n';
if (cascomp && !cassave) XSControl::Vars(pilot)->SetShape (nomsh.ToCString(), C);
else if (cascomp && cassave) BRepTools::Write (C, nomsh.ToCString());
} else {
- if (num < 1 || num > mdl->NbEntities()) { sout<<" incorrect:"<<arg1<<std::endl; return IFSelect_RetError; }
+ if (num < 1 || num > mdl->NbEntities()) { sout<<" incorrect:"<<arg1<<'\n'; return IFSelect_RetError; }
TopoDS_Shape sh = TR->ShapeResult(mdl->Value(num));
- if (sh.IsNull()) { sout<<" Pas de resultat pour "<<arg1<<std::endl; return IFSelect_RetError; }
+ if (sh.IsNull()) { sout<<" Pas de resultat pour "<<arg1<<'\n'; return IFSelect_RetError; }
if (argc > 2) nomsh = arg2;
else nomsh = TCollection_AsciiString ("TREAD_") + num;
if (!cascomp && !cassave) XSControl::Vars(pilot)->SetShape (nomsh.ToCString(), sh);
else if (!cascomp && cassave) BRepTools::Write (sh, nomsh.ToCString());
- else sout<<"Option non comprise"<<std::endl;
+ else sout<<"Option non comprise"<<'\n';
}
return IFSelect_RetDone;
}
// **** fromshape (tread) ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc < 2) {
- sout<<"Give name of a DRAW Shape"<<std::endl;
+ sout<<"Give name of a DRAW Shape"<<'\n';
return IFSelect_RetError;
}
const char* a1 = (char *)arg1;
TopoDS_Shape Shape = XSControl::Vars(pilot)->GetShape(a1);
if (Shape.IsNull()) {
- sout<<"Not a DRAW Shape:"<<arg1<<std::endl;
+ sout<<"Not a DRAW Shape:"<<arg1<<'\n';
return IFSelect_RetError;
}
Standard_Boolean yena = Standard_False;
if (TP.IsNull()) {
if ( silent )
sout << "Shape "<<arg1<<" : ";
- sout<<"no map"<<std::endl;
+ sout<<"no map"<<'\n';
}
else {
TopoDS_Shape S0 = Shape;
// skl 11.05.2004
// if Shape is a compound try to make "fromshape" for its subshapes
if(Shape.ShapeType()==TopAbs_COMPOUND) {
- sout<<std::endl<<"Subshapes imported from entities:";
+ sout<<'\n'<<"Subshapes imported from entities:";
TopoDS_Iterator Iter(Shape);
for (; Iter.More(); Iter.Next()) {
const TopoDS_Shape& subsh = Iter.Value();
else {
sout<<"imported from entity ";
XSControl::Session(pilot)->Model()->Print (ent, sout);
- if ( silent ) sout << " in file " << XSControl::Session(pilot)->LoadedFile() << std::endl;
+ if ( silent ) sout << " in file " << XSControl::Session(pilot)->LoadedFile() << '\n';
}
- if ( ! silent ) sout<<std::endl;
+ if ( ! silent ) sout<<'\n';
}
// ET EN EXPORT ?
sout<<"Shape "<<arg1<<": exported to entity ";
XSControl::Session(pilot)->Model()->Print (ent, sout);
if ( silent ) sout << " in file " << XSControl::Session(pilot)->LoadedFile();
- sout<<std::endl;
+ sout<<'\n';
}
// abv 31.08.00: treat case of split shape (several results)
// it is supposed that results are of the same type and lie in one-level comp
}
if (nb > 0) {
if ( silent ) sout << " in file " << XSControl::Session(pilot)->LoadedFile();
- sout<<std::endl;
+ sout<<'\n';
}
}
/* else {
}
}
}
- if (!yena) sout<<"No transfer (either import or export) recorded"<<std::endl;
+ if (!yena) sout<<"No transfer (either import or export) recorded"<<'\n';
return IFSelect_RetVoid;
}
Handle(Transfer_TransientProcess) TP;
if (!TR.IsNull()) TP = TR->TransientProcess();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (TP.IsNull()) { sout<<"no transfer map"<<std::endl; return IFSelect_RetVoid; }
+ if (TP.IsNull()) { sout<<"no transfer map"<<'\n'; return IFSelect_RetVoid; }
if (argc < 2) {
- sout<<"Give name of a DRAW Shape + optional shape type v-e-w-f(D)-s"<<std::endl;
+ sout<<"Give name of a DRAW Shape + optional shape type v-e-w-f(D)-s"<<'\n';
return IFSelect_RetError;
}
const char* a1 = (const char *)arg1;
TopoDS_Shape Shape = XSControl::Vars(pilot)->GetShape(a1);
- if (Shape.IsNull()) { sout<<"Not a DRAW Shape:"<<arg1<<std::endl; return IFSelect_RetError; }
+ if (Shape.IsNull()) { sout<<"Not a DRAW Shape:"<<arg1<<'\n'; return IFSelect_RetError; }
sout<<"Shape "<<arg1<<" : ";
Handle(TColStd_HSequenceOfTransient) list =
XSControl_ConnectedShapes::AdjacentEntities (Shape,TP,TopAbs_FACE);
Standard_Integer i, nb = list->Length();
- sout<<nb<<" Entities produced Connected Shapes :"<<std::endl;
+ sout<<nb<<" Entities produced Connected Shapes :"<<'\n';
const Handle(Interface_InterfaceModel) &model = XSControl::Session(pilot)->Model();
sout<<"(";
for (i = 1; i <= nb; i ++) {
if (i > 1) sout<<",";
sout<<model->Number(list->Value(i));
}
- sout<<")"<<std::endl;
+ sout<<")"<<'\n';
return IFSelect_RetDone;
}
Standard_Integer argc = pilot->NbWords();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc < 4) {
- sout<<"Give : filename or . for current model; varname or . to take fileroot\n GiveList, * for all transferrable roots"<<std::endl;
+ sout<<"Give : filename or . for current model; varname or . to take fileroot\n GiveList, * for all transferrable roots"<<'\n';
return IFSelect_RetError;
}
const Standard_CString arg1 = pilot->Arg(1);
TCollection_AsciiString fnom,rnom;
Standard_Boolean modfic = XSControl_FuncShape::FileAndVar
(WS,arg1,arg2,"IMPORT",fnom,rnom);
- if (modfic) sout<<" File to read : "<<fnom<<std::endl;
- else sout<<" Model taken from the session : "<<fnom<<std::endl;
- sout<<" -- Names of variables BREP-DRAW prefixed by : "<<rnom<<std::endl;
+ if (modfic) sout<<" File to read : "<<fnom<<'\n';
+ else sout<<" Model taken from the session : "<<fnom<<'\n';
+ sout<<" -- Names of variables BREP-DRAW prefixed by : "<<rnom<<'\n';
// keep the current command, because sub-commands will be called
TCollection_AsciiString compart = pilot->CommandPart (3);
comload.AssignCat(arg1);
IFSelect_ReturnStatus status = pilot->Execute(comload);
if (status != IFSelect_RetDone)
- { sout<<"Abandon import"<<std::endl; return status; }
+ { sout<<"Abandon import"<<'\n'; return status; }
} else {
- sout<<"Currently Loaded Model"<<std::endl;
+ sout<<"Currently Loaded Model"<<'\n';
}
// Selecting Entities
sout<<"List given by "<<compart.ToCString()<<" : ";
list = WS->GiveList (compart.ToCString());
}
- if (list.IsNull()) { sout<<"No list defined. Abandon"<<std::endl; return IFSelect_RetError; }
+ if (list.IsNull()) { sout<<"No list defined. Abandon"<<'\n'; return IFSelect_RetError; }
Standard_Integer nbl = list->Length();
- sout<<"Nb entities selected : "<<nbl<<std::endl;
+ sout<<"Nb entities selected : "<<nbl<<'\n';
// Starting Transfer
WS->InitTransferReader (0);
const Handle(XSControl_TransferReader) &TR = WS->TransferReader();
- if (TR.IsNull()) { sout<<" init not done or failed"<<std::endl; return IFSelect_RetError; }
+ if (TR.IsNull()) { sout<<" init not done or failed"<<'\n'; return IFSelect_RetError; }
TR->BeginTransfer();
// Transferring
Standard_Integer nbt = TR->TransferList(list);
- sout<<"Nb Entities Selected : "<<nbl<<" have given "<<nbt<<" results"<<std::endl;
+ sout<<"Nb Entities Selected : "<<nbl<<" have given "<<nbt<<" results"<<'\n';
// Filling VARS. one compound (trimpcomp) or one shape per ent (trimport)
Standard_Boolean iscomp = (pilot->Arg(0)[5] == 'c');
BRep_Builder B;
B.MakeCompound (C);
Handle(Interface_InterfaceModel) mdl = TR->Model();
- if (mdl.IsNull()) { sout<<" modele absent"<<std::endl; return IFSelect_RetError; }
+ if (mdl.IsNull()) { sout<<" modele absent"<<'\n'; return IFSelect_RetError; }
for (Standard_Integer il= 1; il <= nbl; il ++) {
Handle(Standard_Transient) ent = list->Value(il);
sh = TR->ShapeResult(ent);
XSControl::Vars(pilot)->SetShape(nomsh,sh);
}
}
- if (nbs == 0) sout<<"No Shape produced"<<std::endl;
+ if (nbs == 0) sout<<"No Shape produced"<<'\n';
else if (nbs == 1) {
- sout<<"One Shape produced, named "<<rnom.ToCString()<<std::endl;
+ sout<<"One Shape produced, named "<<rnom.ToCString()<<'\n';
XSControl::Vars(pilot)->SetShape(rnom.ToCString(),sh);
} else if (iscomp) {
- sout<<"One compound made of "<<nbs<<" Shapes, named "<<rnom.ToCString()<<std::endl;
+ sout<<"One compound made of "<<nbs<<" Shapes, named "<<rnom.ToCString()<<'\n';
XSControl::Vars(pilot)->SetShape(rnom.ToCString(),C);
} else { // several individual shapes
- sout<<nbs<<" Shapes, named "<<rnom.ToCString()<<"_1 to "<<rnom.ToCString()<<"_"<<nbs<<std::endl;
+ sout<<nbs<<" Shapes, named "<<rnom.ToCString()<<"_1 to "<<rnom.ToCString()<<"_"<<nbs<<'\n';
}
return IFSelect_RetDone;
// **** twrite ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
Handle(XSControl_TransferWriter) TW = XSControl::Session(pilot)->TransferWriter();
- if (argc < 2) { sout<<" donner nom de shape draw"<<std::endl; return IFSelect_RetError; }
- sout<<"Attention, on alimente le modele courant ..."<<std::endl;
+ if (argc < 2) { sout<<" donner nom de shape draw"<<'\n'; return IFSelect_RetError; }
+ sout<<"Attention, on alimente le modele courant ..."<<'\n';
// Shape
for (Standard_Integer i = 1; i < argc; i ++) {
const char* ai = (const char *)pilot->Arg(i);
TopoDS_Shape Shape = XSControl::Vars(pilot)->GetShape(ai);
- if (Shape.IsNull()) { sout<<"pas un nom de shape draw:"<<arg1<<std::endl; continue; }
+ if (Shape.IsNull()) { sout<<"pas un nom de shape draw:"<<arg1<<'\n'; continue; }
sout<<"Pour Shape : "<<ai;
Standard_Integer stat = TW->TransferWriteShape (XSControl::Session(pilot)->Model(),Shape);
- sout<<" Transfer Write Status = "<<stat<<std::endl;
+ sout<<" Transfer Write Status = "<<stat<<'\n';
}
pilot->Session()->ComputeGraph();
// Transient ? (Geom) : ignore
if (list.IsNull()) list = new TopTools_HSequenceOfShape();
if (name[0] == '*' && (name[1] == '\0' || (name[1] == '*' && name[2] == '\0'))) {
const Handle(Transfer_TransientProcess) &TP = session->TransferReader()->TransientProcess();
- if (TP.IsNull()) { sout<<"last transfer : unknown"<<std::endl;return 0; }
+ if (TP.IsNull()) { sout<<"last transfer : unknown"<<'\n';return 0; }
Handle(TopTools_HSequenceOfShape) li = TransferBRep::Shapes(TP,(name[1] == '\0'));
if (li.IsNull()) return 0;
list->Append (li);
list->Append(Shape);
nbsh ++;
}
- sout<<" -> taken "<<nbsh<<" Shapes"<<std::endl;
+ sout<<" -> taken "<<nbsh<<" Shapes"<<'\n';
return nbsh;
}
const char* a1 = (const char *)name;
TopoDS_Shape Shape = session->Vars()->GetShape(a1);
- if (Shape.IsNull()) { sout<<"not a shape draw:"<<a1<<std::endl; return 0; }
+ if (Shape.IsNull()) { sout<<"not a shape draw:"<<a1<<'\n'; return 0; }
list->Append(Shape);
return 1;
}
if (argc > 1) return (XSControl::Session(pilot)->SelectNorm(arg1) ?
IFSelect_RetDone : IFSelect_RetFail);
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- sout<<"Selected Norm:"<<XSControl::Session(pilot)->SelectedNorm()<<std::endl;
+ sout<<"Selected Norm:"<<XSControl::Session(pilot)->SelectedNorm()<<'\n';
return IFSelect_RetVoid;
}
Handle(XSControl_Controller) control = WS->NormAdaptor();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (argc == 1)
- sout<<"Current Norm. xnorm newnorm to change"<<std::endl;
- else sout<<"Current Norm :"<<std::endl;
- if (control.IsNull()) sout<<"no norm currently defined"<<std::endl;
+ sout<<"Current Norm. xnorm newnorm to change"<<'\n';
+ else sout<<"Current Norm :"<<'\n';
+ if (control.IsNull()) sout<<"no norm currently defined"<<'\n';
else
- sout<<" Long Name (complete) : "<<control->Name(Standard_False)<<std::endl
- << " Short name (resource) : "<<control->Name(Standard_True)<<std::endl;
+ sout<<" Long Name (complete) : "<<control->Name(Standard_False)<<'\n'
+ << " Short name (resource) : "<<control->Name(Standard_True)<<'\n';
if (argc == 1) return IFSelect_RetVoid;
control = XSControl_Controller::Recorded(arg1);
if (control.IsNull()) {
- sout<<" No norm named : "<<arg1<<std::endl;
+ sout<<" No norm named : "<<arg1<<'\n';
return IFSelect_RetError;
}
WS->SetController(control);
- sout<<"new norm : "<<control->Name()<<std::endl;
+ sout<<"new norm : "<<control->Name()<<'\n';
return IFSelect_RetDone;
}
// **** newmodel ****
if (!XSControl::Session(pilot)->NewModel().IsNull()) return IFSelect_RetDone;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- sout<<"No new Model produced"<<std::endl;
+ sout<<"No new Model produced"<<'\n';
return IFSelect_RetDone;
}
const Handle(Transfer_FinderProcess) &FP = XSControl::Session(pilot)->TransferWriter()->FinderProcess();
const Handle(Transfer_TransientProcess) &TP = XSControl::Session(pilot)->TransferReader()->TransientProcess();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (modew) { if(!FP.IsNull()) FP->Clear(); else sout<<"No Transfer Write"<<std::endl; }
- else { if(!TP.IsNull()) TP->Clear(); else sout<<"No Transfer Read"<<std::endl; }
+ if (modew) { if(!FP.IsNull()) FP->Clear(); else sout<<"No Transfer Write"<<'\n'; }
+ else { if(!TP.IsNull()) TP->Clear(); else sout<<"No Transfer Read"<<'\n'; }
return IFSelect_RetDone;
}
//const Standard_CString arg2 = pilot->Arg(2);
const Handle(Transfer_TransientProcess) &TP = XSControl::Session(pilot)->TransferReader()->TransientProcess();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (TP.IsNull()) { sout<<"No Transfer Read"<<std::endl; return IFSelect_RetError;}
+ if (TP.IsNull()) { sout<<"No Transfer Read"<<'\n'; return IFSelect_RetError;}
// **** tpstat ****
Standard_Integer mod1 = -1;
}
}
// A present help eventuel
- if (mod1 < -1) sout<<"Unknown Mode"<<std::endl;
+ if (mod1 < -1) sout<<"Unknown Mode"<<'\n';
if (mod1 < 0) {
sout<<"Modes available :\n"
<<"g : general c : checks (count) C (list)\n"
<<" L : list per couple type entity/result\n"
<<" *n *s *b *t *r *l *L : idem on ALL recorded items\n"
<<" ?n ?s ?b ?t ... : idem on abnormal items\n"
- <<" n select : n applied on a selection idem for s b t r l"<<std::endl;
+ <<" n select : n applied on a selection idem for s b t r l"<<'\n';
if (mod1 < -1) return IFSelect_RetError;
return IFSelect_RetVoid;
}
XSControl_TransferReader::PrintStatsOnList (TP,list,mod1,mod2);
// TP->PrintStats (1,sout);
}
- else sout<<"TransferRead : not defined"<<std::endl;
+ else sout<<"TransferRead : not defined"<<'\n';
return IFSelect_RetVoid;
}
const Handle(Transfer_TransientProcess) &TP = XSControl::Session(pilot)->TransferReader()->TransientProcess();
// **** tpent ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (TP.IsNull()) { sout<<"No Transfer Read"<<std::endl; return IFSelect_RetError;}
+ if (TP.IsNull()) { sout<<"No Transfer Read"<<'\n'; return IFSelect_RetError;}
Handle(Interface_InterfaceModel) model = TP->Model();
if (model.IsNull()) return IFSelect_RetFail;
- if (argc < 2) { sout<<"Give ENTITY NUMBER (IN MODEL TransferProcess)"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Give ENTITY NUMBER (IN MODEL TransferProcess)"<<'\n'; return IFSelect_RetError; }
Standard_Integer num = atoi(arg1);
- if (num <= 0 || num > model->NbEntities()) { sout<<"Number not in [1 - "<<model->NbEntities()<<"]"<<std::endl; return IFSelect_RetError; }
+ if (num <= 0 || num > model->NbEntities()) { sout<<"Number not in [1 - "<<model->NbEntities()<<"]"<<'\n'; return IFSelect_RetError; }
Handle(Standard_Transient) ent = model->Value(num);
Standard_Integer index = TP->MapIndex (ent);
- if (index == 0) sout<<"Entity "<<num<<" not recorded in transfer"<<std::endl;
+ if (index == 0) sout<<"Entity "<<num<<" not recorded in transfer"<<'\n';
else XSControl::Session(pilot)->PrintTransferStatus (index,Standard_False,sout);
return IFSelect_RetVoid;
}
const Standard_CString arg1 = pilot->Arg(1);
// **** tpitem/tproot/twitem/twroot ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (argc < 2) { sout<<"Give ITEM NUMBER (in TransferProcess)"<<std::endl; return IFSelect_RetError; }
+ if (argc < 2) { sout<<"Give ITEM NUMBER (in TransferProcess)"<<'\n'; return IFSelect_RetError; }
Standard_Integer num = atoi(arg1);
if (pilot->Word(0).Value(3) == 'r') num = -num;
Standard_Boolean modew = Standard_False;
Handle(Standard_Transient) ent;
if (!XSControl::Session(pilot)->PrintTransferStatus(num,modew,sout))
{
- sout<<" - Num="<<num<<" incorrect"<<std::endl;
+ sout<<" - Num="<<num<<" incorrect"<<'\n';
}
return IFSelect_RetVoid;
}
Handle(Standard_Transient) ent;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (mdl.IsNull() || TR.IsNull() || TP.IsNull())
- { sout<<" init not done"<<std::endl; return IFSelect_RetError; }
+ { sout<<" init not done"<<'\n'; return IFSelect_RetError; }
if (!tous) num = atoi(arg1);
// Enregistrer les racines
if (tous) {
Standard_Integer nb = TP->NbRoots();
- sout<<" Recording "<<nb<<" Roots"<<std::endl;
+ sout<<" Recording "<<nb<<" Roots"<<'\n';
for (Standard_Integer i = 1; i <= nb; i ++) {
ent = TP->Root(i);
- if (TR->RecordResult (ent)) sout<<" Root n0."<<i<<std::endl;
- else sout<<" Root n0."<<i<<" not recorded"<<std::endl;
+ if (TR->RecordResult (ent)) sout<<" Root n0."<<i<<'\n';
+ else sout<<" Root n0."<<i<<" not recorded"<<'\n';
}
} else {
- if (num < 1 || num > mdl->NbEntities()) sout<<"incorrect number:"<<num<<std::endl;
- else if (TR->RecordResult(mdl->Value(num))) sout<<" Entity n0."<<num<<std::endl;
- else sout<<" Entity n0."<<num<<" not recorded"<<std::endl;
+ if (num < 1 || num > mdl->NbEntities()) sout<<"incorrect number:"<<num<<'\n';
+ else if (TR->RecordResult(mdl->Value(num))) sout<<" Entity n0."<<num<<'\n';
+ else sout<<" Entity n0."<<num<<" not recorded"<<'\n';
}
return IFSelect_RetDone;
}
Message_Messenger::StreamBuffer sout = Message::SendInfo();
// **** trstat : TransferReader ****
const Handle(XSControl_TransferReader) &TR = XSControl::Session(pilot)->TransferReader();
- if (TR.IsNull()) { sout<<" init not done"<<std::endl; return IFSelect_RetError; }
+ if (TR.IsNull()) { sout<<" init not done"<<'\n'; return IFSelect_RetError; }
Handle(Interface_InterfaceModel) mdl = TR->Model();
- if (mdl.IsNull()) { sout<<" No model"<<std::endl; return IFSelect_RetError; }
- sout<<" Statistics : FileName : "<<TR->FileName()<<std::endl;
+ if (mdl.IsNull()) { sout<<" No model"<<'\n'; return IFSelect_RetError; }
+ sout<<" Statistics : FileName : "<<TR->FileName()<<'\n';
if (argc == 1) {
// stats generales
TR->PrintStats (sout, 10, 0);
} else {
// stats unitaires
Standard_Integer num = atoi(arg1);
- if (num < 1 || num > mdl->NbEntities()) { sout<<" incorrect number:"<<arg1<<std::endl; return IFSelect_RetError; }
+ if (num < 1 || num > mdl->NbEntities()) { sout<<" incorrect number:"<<arg1<<'\n'; return IFSelect_RetError; }
Handle(Standard_Transient) ent = mdl->Value(num);
- if (!TR->IsRecorded(ent)) { sout<<" Entity "<<num<<" not recorded"<<std::endl; return IFSelect_RetError; }
+ if (!TR->IsRecorded(ent)) { sout<<" Entity "<<num<<" not recorded"<<'\n'; return IFSelect_RetError; }
Handle(Transfer_ResultFromModel) RM = TR->FinalResult(ent);
Handle(TColStd_HSequenceOfTransient) list = TR->CheckedList(ent);
Standard_Integer i, nb = list->Length();
if (nb > 0) sout<<" Entities implied by Check/Result :"<<nb<<" i.e.:";
for (i = 1; i <= nb; i ++) { sout<<" "; mdl->Print(list->Value(i), sout); }
- sout<<std::endl;
- if (RM.IsNull()) { sout<<" no other info"<<std::endl; return IFSelect_RetVoid; }
+ sout<<'\n';
+ if (RM.IsNull()) { sout<<" no other info"<<'\n'; return IFSelect_RetVoid; }
Interface_CheckIterator chl = RM->CheckList(Standard_False);
pilot->Session()->PrintCheckList (sout, chl, Standard_False, IFSelect_EntitiesByItem);
}
TR = XSControl::Session(pilot)->TransferReader();
if (TR.IsNull()) {
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- sout<<" init not done or failed"<<std::endl;
+ sout<<" init not done or failed"<<'\n';
return IFSelect_RetError;
}
}
// **** tread : TransferReader ****
Message_Messenger::StreamBuffer sout = Message::SendInfo();
const Handle(XSControl_TransferReader) &TR = XSControl::Session(pilot)->TransferReader();
- if (TR.IsNull()) { sout<<" init not done"<<std::endl; return IFSelect_RetError; }
+ if (TR.IsNull()) { sout<<" init not done"<<'\n'; return IFSelect_RetError; }
const Handle(Interface_InterfaceModel) &mdl = TR->Model();
- if (mdl.IsNull()) { sout<<" No model"<<std::endl; return IFSelect_RetError; }
+ if (mdl.IsNull()) { sout<<" No model"<<'\n'; return IFSelect_RetError; }
if (argc < 2) {
// DeclareAndCast(IFSelect_Selection,sel,pilot->Session()->NamedItem("xst-model-roots"));
Handle(Standard_Transient) sel = pilot->Session()->NamedItem("xst-model-roots");
- if (sel.IsNull()) { sout<<"Select Roots absent"<<std::endl; return IFSelect_RetError; }
+ if (sel.IsNull()) { sout<<"Select Roots absent"<<'\n'; return IFSelect_RetError; }
Handle(TColStd_HSequenceOfTransient) list = pilot->Session()->GiveList(sel);
- sout<<" Transferring all roots i.e. : "<<TR->TransferList(list)<<std::endl;
+ sout<<" Transferring all roots i.e. : "<<TR->TransferList(list)<<'\n';
} else {
Handle(TColStd_HSequenceOfTransient) list =
IFSelect_Functions::GiveList(pilot->Session(),pilot->CommandPart(1));
- sout<<" Transfer of "<<list->Length()<<" entities"<<std::endl;
+ sout<<" Transfer of "<<list->Length()<<" entities"<<'\n';
Standard_Integer nb = TR->TransferList(list);
- sout<<" Gives "<<nb<<" results"<<std::endl;
+ sout<<" Gives "<<nb<<" results"<<'\n';
}
return IFSelect_RetDone;
}
// **** TReader -> TProcess ****
const Handle(XSControl_TransferReader) &TR = XSControl::Session(pilot)->TransferReader();
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- if (TR.IsNull()) sout<<" No TransferReader"<<std::endl;
- else if (TR->TransientProcess().IsNull()) sout<<" Transfer Reader without Process"<<std::endl;
+ if (TR.IsNull()) sout<<" No TransferReader"<<'\n';
+ else if (TR->TransientProcess().IsNull()) sout<<" Transfer Reader without Process"<<'\n';
return IFSelect_RetVoid;
}
Standard_Integer modemin,modemax;
Message_Messenger::StreamBuffer sout = Message::SendInfo();
if (control->ModeWriteBounds (modemin,modemax)) {
- sout<<"Write Mode : allowed values "<<modemin<<" to "<<modemax<<std::endl;
+ sout<<"Write Mode : allowed values "<<modemin<<" to "<<modemax<<'\n';
for (Standard_Integer modd = modemin; modd <= modemax; modd ++) {
- sout<<modd<<" : "<<control->ModeWriteHelp (modd)<<std::endl;
+ sout<<modd<<" : "<<control->ModeWriteHelp (modd)<<'\n';
}
}
- sout<<"Write Mode : actual = "<<TW->TransferMode()<<std::endl;
+ sout<<"Write Mode : actual = "<<TW->TransferMode()<<'\n';
if (argc <= 1) return IFSelect_RetVoid;
Standard_Integer mod = atoi(arg1);
- sout<<"New value -> "<<arg1<<std::endl;
+ sout<<"New value -> "<<arg1<<'\n';
TW->SetTransferMode(mod);
- if (!control->IsModeWrite (mod)) sout<<"Warning : this new value is not supported"<<std::endl;
+ if (!control->IsModeWrite (mod)) sout<<"Warning : this new value is not supported"<<'\n';
return IFSelect_RetDone;
}
// XSControl_TransferWriter::PrintStatsProcess (FP,mod1,mod2);
FP->PrintStats (1,sout);
}
- else sout<<"TransferWrite: not defined"<<std::endl;
+ else sout<<"TransferWrite: not defined"<<'\n';
return IFSelect_RetVoid;
}
Standard_Integer num = myModel->Number(ent);
Handle(TCollection_HAsciiString) lab = myModel->StringLabel(ent);
sout<<"\n*******************************************************************\n";
- sout << "****** Transferring one Entity ******"<<std::endl;
+ sout << "****** Transferring one Entity ******"<<'\n';
if (!lab.IsNull())
sout<<"****** N0 in file : "<<Interface_MSG::Blanks(num,5)<<num
<<" Ident : "<<lab->ToCString()
if (level > 0) {
Message_Messenger::StreamBuffer sout = myTP->Messenger()->SendInfo();
sout<<"\n*******************************************************************\n";
- sout << "****** Transferring a list of "<<Interface_MSG::Blanks(nb,5)<<" Entities ******"<<std::endl;
+ sout << "****** Transferring a list of "<<Interface_MSG::Blanks(nb,5)<<" Entities ******"<<'\n';
sout<<"\n*******************************************************************\n";
Handle(IFSelect_SignatureList) sl = new IFSelect_SignatureList;
Standard_Integer nb = roots.NbEntities();
Message_Messenger::StreamBuffer sout = myTP->Messenger()->SendInfo();
sout<<"\n*******************************************************************\n";
- sout << "****** Transferring the "<<Interface_MSG::Blanks(nb,5)<<" Root Entities ******"<<std::endl;
+ sout << "****** Transferring the "<<Interface_MSG::Blanks(nb,5)<<" Root Entities ******"<<'\n';
sout<<"\n*******************************************************************\n";
Handle(IFSelect_SignatureList) sl = new IFSelect_SignatureList;
for (roots.Start(); roots.More(); roots.Next())
{
// A ameliorer ... !
sout<<"\n*******************************************************************\n";
- sout << "****** Statistics on Transfer (Read) ******"<<std::endl;
+ sout << "****** Statistics on Transfer (Read) ******"<<'\n';
sout<<"\n*******************************************************************\n";
- if (what > 10) { sout<<" *** Not yet implemented"<<std::endl; return; }
+ if (what > 10) { sout<<" *** Not yet implemented"<<'\n'; return; }
if (what < 10) {
- sout << "****** Data recorded on Last Transfer ******"<<std::endl;
+ sout << "****** Data recorded on Last Transfer ******"<<'\n';
PrintStatsProcess (myTP,what,mode);
}
// reste what = 10 : on liste les racines des final results
- sout << "****** Final Results ******"<<std::endl;
- if (myModel.IsNull()) { sout<<"**** Model unknown"<<std::endl; return; }
+ sout << "****** Final Results ******"<<'\n';
+ if (myModel.IsNull()) { sout<<"**** Model unknown"<<'\n'; return; }
Handle(TColStd_HSequenceOfTransient) list = RecordedList();
Standard_Integer i, nb = list->Length();
Handle(IFSelect_SignatureList) counter;
}
if (!counter.IsNull()) counter->PrintList (sout, myModel, pcm);
- sout<<std::endl;
+ sout<<'\n';
}
if (nb <= 0 || nl == 0) return;
Message_Messenger::StreamBuffer aSender = sout->SendInfo();
aSender<<"****** "<<mess<<": ";
- if (nb == nl) aSender<<"100 %"<<std::endl;
- else if (nb*100/nl == 0) aSender<<"< 1 %"<<std::endl;
- else aSender<<(nb*100/nl < 10 ? " " : " ")<<nb*100/nl<<" %"<<std::endl;
+ if (nb == nl) aSender<<"100 %"<<'\n';
+ else if (nb*100/nl == 0) aSender<<"< 1 %"<<'\n';
+ else aSender<<(nb*100/nl < 10 ? " " : " ")<<nb*100/nl<<" %"<<'\n';
}
if (what == 0) { TP->PrintStats(0,sout); return; }
sout<<"\n*******************************************************************\n";
- sout << "****** Statistics on Transfer Process (Read) ******"<<std::endl;
+ sout << "****** Statistics on Transfer Process (Read) ******"<<'\n';
if (what == 1) sout << "****** Individual Transfers (Roots) ******\n";
if (what == 2) sout << "****** All recorded data about Transfer ******\n";
if (what == 3) sout << "****** Abnormal records ******\n";
IFSelect_PrintCount pcm = IFSelect_CountByItem;
if (mode == 6) pcm = IFSelect_ListByItem;
- sout <<"**** Entities in Model : "<<model->NbEntities()<<std::endl;
- sout <<"**** Nb Items (Transfer) : "<<nb<<std::endl;
+ sout <<"**** Entities in Model : "<<model->NbEntities()<<'\n';
+ sout <<"**** Nb Items (Transfer) : "<<nb<<'\n';
if (!nolist)
- sout<<"**** Nb Items (Listed) : "<<nl<<std::endl;
+ sout<<"**** Nb Items (Listed) : "<<nl<<'\n';
for (itrp.Start(); itrp.More(); itrp.Next()) {
nbi ++;
else if (mode == 1 || mode == 2) {
sout<<"["<<Interface_MSG::Blanks (nbi,4)<<nbi<<" ]:";
model->Print (ent, sout);
- sout<<" "<<model->TypeName(ent,Standard_False)<<" (not recorded)"<<std::endl;
+ sout<<" "<<model->TypeName(ent,Standard_False)<<" (not recorded)"<<'\n';
continue;
}
}
sout<<"["<<Interface_MSG::Blanks (i,4)<<i<<" ]:";
model->Print (ent, sout);
sout<<" "<<model->TypeName(ent,Standard_False);
- sout<<" Result:"<<mess<<std::endl;
+ sout<<" Result:"<<mess<<'\n';
if (mode == 1) continue;
const Handle(Interface_Check)& ch = binder->Check();
if (newnbw > 0) {
sout<<" - Warnings : "<<newnbw<<":\n";
- for (newi = 1; newi <= newnbw; newi ++) sout<<ch->CWarning(newi)<<std::endl;
+ for (newi = 1; newi <= newnbw; newi ++) sout<<ch->CWarning(newi)<<'\n';
}
if (newnbf > 0) {
sout<<" - Fails : "<<newnbf<<":\n";
- for (newi = 1; newi <= newnbf; newi ++) sout<<ch->CFail(newi)<<std::endl;
+ for (newi = 1; newi <= newnbf; newi ++) sout<<ch->CFail(newi)<<'\n';
}
continue;
}
// Fin de l iteration
}
if (!counter.IsNull()) counter->PrintList (sout, model, pcm);
- else sout<<std::endl;
+ else sout<<'\n';
// Pourcentages
if (mode != 3 && nbi > 0) {
- sout << "****** Percentages according Transfer Status ******"<<std::endl;
+ sout << "****** Percentages according Transfer Status ******"<<'\n';
PrintPercent (TP->Messenger(),"Result ",nbr+nbrw,nl);
PrintPercent (TP->Messenger(),"Result + FAIL ",nbrf,nl);
PrintPercent (TP->Messenger(),"FAIL, no Result ",nbf,nl);
Message_Messenger::StreamBuffer sout = myTransferWriter->Messenger()->SendInfo();
// A ameliorer ... !
sout<<"\n*******************************************************************\n";
- sout << "****** Statistics on Transfer (Write) ******"<<std::endl;
+ sout << "****** Statistics on Transfer (Write) ******"<<'\n';
sout<<"\n*******************************************************************\n";
sout << "****** Transfer Mode = "<<myTransferMode;
Standard_CString modehelp = myController->ModeWriteHelp (myTransferMode);
if (modehelp && modehelp[0] != 0) sout<<" I.E. "<<modehelp;
- sout<<" ******"<<std::endl;
+ sout<<" ******"<<'\n';
}
OCC_CATCH_SIGNALS
PrintStats(myTransferMode);
sout << "****** Transferring Transient, CDL Type = ";
- sout<<obj->DynamicType()->Name()<<" ******"<<std::endl;
+ sout<<obj->DynamicType()->Name()<<" ******"<<'\n';
status = myController->TransferWriteTransient
(obj,myTransferWriter,model, myTransferMode, theProgress);
}
catch(Standard_Failure const& anException) {
sout<<"**** **** TransferWriteShape, EXCEPTION : ";
sout<<anException.GetMessageString();
- sout<<std::endl;
+ sout<<'\n';
status = IFSelect_RetFail;
}
return status;
OCC_CATCH_SIGNALS
PrintStats(myTransferMode);
sout << "****** Transferring Shape, ShapeType = " << aShape.ShapeType();
- sout<<" ******"<<std::endl;
+ sout<<" ******"<<'\n';
status = myController->TransferWriteShape
(aShape,myTransferWriter, theModel, myTransferMode, theProgress);
}
catch(Standard_Failure const& anException) {
sout<<"**** **** TransferWriteShape, EXCEPTION : ";
sout<<anException.GetMessageString();
- sout<<std::endl;
+ sout<<'\n';
status = IFSelect_RetFail;
}
return status;
void XSControl_Utils::TraceLine (const Standard_CString line) const
{
Message_Messenger::StreamBuffer sout = Message::SendInfo();
- sout<<line<<std::endl;
+ sout<<line<<'\n';
}
void XSControl_Utils::TraceLines (const Handle(Standard_Transient)& lines) const
if (!linha.IsNull()) {
nb = linha->Length();
for (i = 1; i <= nb; i ++)
- if (!linha->Value(i).IsNull()) sout<<linha->Value(i)->ToCString()<<std::endl;
+ if (!linha->Value(i).IsNull()) sout<<linha->Value(i)->ToCString()<<'\n';
return;
}
DeclareAndCast(TColStd_HSequenceOfAsciiString,lina,lines);
if (!lina.IsNull()) {
nb = lina->Length();
for (i = 1; i <= nb; i ++)
- sout<<lina->Value(i).ToCString()<<std::endl;
+ sout<<lina->Value(i).ToCString()<<'\n';
return;
}
DeclareAndCast(TColStd_HSequenceOfHExtendedString,linhe,lines);
nb = linhe->Length();
for (i = 1; i <= nb; i ++)
if (!linhe->Value(i).IsNull())
- sout << linhe->Value(i)->String() << std::endl;
+ sout << linhe->Value(i)->String() << '\n';
return;
}
DeclareAndCast(TColStd_HSequenceOfExtendedString,linee,lines);
if (!linee.IsNull()) {
nb = linee->Length();
for (i = 1; i <= nb; i ++)
- sout << linee->Value(i) << std::endl;
+ sout << linee->Value(i) << '\n';
return;
}
DeclareAndCast(TCollection_HAsciiString,lin1a,lines);
{
S<<" ** Transfer Root n0."<<ne;
}
- S<<std::endl;
+ S<<'\n';
ent = FP->FindTransient(finder);
- S<<" -> Type "<<finder->DynamicType()->Name()<<std::endl;
+ S<<" -> Type "<<finder->DynamicType()->Name()<<'\n';
FP->StartTrace (binder,finder,0,0); // pb sout/S
if (!ent.IsNull()) {
S<<" ** Resultat Transient, type "<<ent->DynamicType()->Name();
const Handle(Interface_InterfaceModel) &model = Model();
if (!model.IsNull())
{ S<<" In output Model, Entity "; model->Print(ent, S); }
- S<<std::endl;
+ S<<'\n';
}
}
else {
if (TP.IsNull()) return Standard_False;
Handle(Interface_InterfaceModel) model = TP->Model();
- if (model.IsNull()) std::cout<<"No Model"<<std::endl;
- else if (model != Model()) std::cout<<"Model different from the session"<<std::endl;
+ if (model.IsNull()) std::cout<<"No Model"<<'\n';
+ else if (model != Model()) std::cout<<"Model different from the session"<<'\n';
if (num == 0) return Standard_False;
Standard_Integer ne=0, nr=0, max = TP->NbMapped() ,maxr = TP->NbRoots();
{
S<<" ** Transfer Root n0."<<ne;
}
- S<<std::endl;
+ S<<'\n';
if (!model.IsNull()) { S<<" In Model, Entity "; model->Print(ent, S); }
binder = TP->MapItem (ne);
- S<<std::endl;
+ S<<'\n';
TP->StartTrace (binder,ent,0,0);
}
Standard_Integer i,nbw = ch->NbWarnings(), nbf = ch->NbFails();
if (nbw > 0) {
S<<" - Warnings : "<<nbw<<" :\n";
- for (i = 1; i <= nbw; i ++) S<<ch->CWarning(i)<<std::endl;
+ for (i = 1; i <= nbw; i ++) S<<ch->CWarning(i)<<'\n';
}
if (nbf > 0) {
S<<" - Fails : "<<nbf<<" :\n";
- for (i = 1; i <= nbf; i ++) S<<ch->CFail(i)<<std::endl;
+ for (i = 1; i <= nbf; i ++) S<<ch->CFail(i)<<'\n';
}
}
return Standard_True;
void XSDRAW::SetController (const Handle(XSControl_Controller)& control)
{
if (thepilot.IsNull()) XSDRAW::LoadSession();
- if (control.IsNull()) std::cout<<"XSTEP Controller not defined"<<std::endl;
+ if (control.IsNull()) std::cout<<"XSTEP Controller not defined"<<'\n';
else if (!Session().IsNull()) Session()->SetController (control);
- else std::cout<<"XSTEP Session badly or not defined"<<std::endl;
+ else std::cout<<"XSTEP Session badly or not defined"<<'\n';
}
char fname[110];
sprintf(fname, "Shape_%d", number);
std::ofstream f(fname, std::ios::out | std::ios::binary);
- std::cout << "Output file name : " << fname << std::endl;
+ std::cout << "Output file name : " << fname << '\n';
f << "DBRep_DrawableShape\n";
BRepTools::Write(shape, f);
else if (modepri == 3)
{ // One Entity
- std::cout << "Only One Entity" << std::endl;
- std::cout << "spline_continuity (read) : " << Interface_Static::IVal("read.iges.bspline.continuity") << " (0 : no modif, 1 : C1, 2 : C2)" << std::endl;
- std::cout << " To modify : command param read.iges.bspline.continuity" << std::endl;
+ std::cout << "Only One Entity" << '\n';
+ std::cout << "spline_continuity (read) : " << Interface_Static::IVal("read.iges.bspline.continuity") << " (0 : no modif, 1 : C1, 2 : C2)" << '\n';
+ std::cout << " To modify : command param read.iges.bspline.continuity" << '\n';
std::cout << " give the number of the Entity : " << std::flush;
nent = GiveEntityNumber(aWS, "");
{
std::cout << "Name of Selection :" << std::flush;
list = XSDRAW::Session()->GiveList("");
- if (list.IsNull()) { std::cout << "No list defined" << std::endl; continue; }
+ if (list.IsNull()) { std::cout << "No list defined" << '\n'; continue; }
}
Standard_Integer nbl = list->Length();
{
const Standard_Integer aNbNodes = myMesh->NbNodes();
myNodeCoords = new TColStd_HArray2OfReal (1, aNbNodes, 1, 3);
- std::cout << "Nodes : " << aNbNodes << std::endl;
+ std::cout << "Nodes : " << aNbNodes << '\n';
for (Standard_Integer i = 1; i <= aNbNodes; i++)
{
myElemNormals = new TColStd_HArray2OfReal(1, aNbTris, 1, 3);
myElemNodes = new TColStd_HArray2OfInteger(1, aNbTris, 1, 3);
- std::cout << "Elements : " << aNbTris << std::endl;
+ std::cout << "Elements : " << aNbTris << '\n';
for (Standard_Integer i = 1; i <= aNbTris; i++)
{
myElemNormals->SetValue (i, 3, aN.Z());
}
}
- std::cout << "Construction is finished" << std::endl;
+ std::cout << "Construction is finished" << '\n';
}
//================================================================
if (aParser.parse(theIStream, Standard_False, aWithoutRoot))
{
TCollection_AsciiString aData;
- std::cout << aParser.GetError(aData) << ": " << aData << std::endl;
+ std::cout << aParser.GetError(aData) << ": " << aData << '\n';
myReaderStatus = PCDM_RS_FormatFailure;
return;
}
o << "math_BissecNewton ";
if(Done) {
o << " Status = Done \n";
- o << " The Root is: " << x << std::endl;
- o << " The value at this Root is: " << f << std::endl;
+ o << " The Root is: " << x << '\n';
+ o << " The value at this Root is: " << f << '\n';
}
else {
o << " Status = not Done \n";
o << "math_BracketMinimum ";
if(Done) {
o << " Status = Done \n";
- o << " The bracketed triplet is: " << std::endl;
- o << Ax << ", " << Bx << ", " << Cx << std::endl;
- o << " The corresponding function values are: "<< std::endl;
- o << FAx << ", " << FBx << ", " << FCx << std::endl;
+ o << " The bracketed triplet is: " << '\n';
+ o << Ax << ", " << Bx << ", " << Cx << '\n';
+ o << " The corresponding function values are: "<< '\n';
+ o << FAx << ", " << FBx << ", " << FCx << '\n';
}
else {
o << " Status = not Done \n";
o << "math_BracketedRoot ";
if(Done) {
o << " Status = Done \n";
- o << " Number of iterations = " << NbIter << std::endl;
- o << " The Root is: " << TheRoot << std::endl;
- o << " The value at the root is: " << TheError << std::endl;
+ o << " Number of iterations = " << NbIter << '\n';
+ o << " The Root is: " << TheRoot << '\n';
+ o << " The value at the root is: " << TheError << '\n';
}
else {
o << " Status = not Done \n";
o<< "math_FunctionAllRoots ";
if(done) {
o<< " Status = Done \n";
- o << " Number of null intervals = " << pdeb.Length() << std::endl;
- o << " Number of points where the function is null: " << piso.Length() << std::endl;
+ o << " Number of null intervals = " << pdeb.Length() << '\n';
+ o << " Number of points where the function is null: " << piso.Length() << '\n';
}
else {
o<< " Status = not Done \n";
o<< "math_FunctionRoot ";
if(Done) {
o<< " Status = Done \n";
- o << " Number of iterations = " << NbIter << std::endl;
- o << " The Root is: " << TheRoot << std::endl;
- o << "The value at the root is: " << TheError << std::endl;
+ o << " Number of iterations = " << NbIter << '\n';
+ o << " The Root is: " << TheRoot << '\n';
+ o << "The value at the root is: " << TheError << '\n';
}
else {
o<< " Status = not Done \n";
o << "math_FunctionRoots ";
if(Done) {
o << " Status = Done \n";
- o << " Number of solutions = " << Sol.Length() << std::endl;
+ o << " Number of solutions = " << Sol.Length() << '\n';
for (Standard_Integer i = 1; i <= Sol.Length(); i++) {
- o << " Solution Number " << i << "= " << Sol.Value(i) << std::endl;
+ o << " Solution Number " << i << "= " << Sol.Value(i) << '\n';
}
}
else {
o << "math_Gauss ";
if(Done) {
o<< " Status = Done \n";
- o << " Determinant of A = " << D << std::endl;
+ o << " Determinant of A = " << D << '\n';
}
else {
o << " Status = not Done \n";
o <<"math_Jacobi ";
if (Done) {
o << " Status = Done \n";
- o << " The eigenvalues vector is: " << EigenValues << std::endl;
+ o << " The eigenvalues vector is: " << EigenValues << '\n';
}
else {
o << "Status = not Done \n";
void math_NewtonMinimum::Dump(Standard_OStream& o) const
{
o<< "math_Newton Optimisation: ";
- o << " Done =" << Done << std::endl;
- o << " Status = " << (Standard_Integer)TheStatus << std::endl;
- o << " Location Vector = " << Location() << std::endl;
- o << " Minimum value = "<< Minimum()<< std::endl;
- o << " Previous value = "<< PreviousMinimum << std::endl;
- o << " Number of iterations = " <<NbIterations() << std::endl;
- o << " Convexity = " << Convex << std::endl;
- o << " Eigen Value = " << MinEigenValue << std::endl;
+ o << " Done =" << Done << '\n';
+ o << " Status = " << (Standard_Integer)TheStatus << '\n';
+ o << " Location Vector = " << Location() << '\n';
+ o << " Minimum value = "<< Minimum()<< '\n';
+ o << " Previous value = "<< PreviousMinimum << '\n';
+ o << " Number of iterations = " <<NbIterations() << '\n';
+ o << " Convexity = " << Convex << '\n';
+ o << " Eigen Value = " << MinEigenValue << '\n';
}
o << "math_Uzawa";
if(Done) {
o << " Status = Done \n";
- o << " Number of iterations = " << NbIter << std::endl;
- o << " The solution vector is: " << Resul << std::endl;
+ o << " Number of iterations = " << NbIter << '\n';
+ o << " The solution vector is: " << Resul << '\n';
}
else {
o << " Status = not Done \n";