#include "mbconfig.h"
#include "mbpar.h"
#include "dataman.h"
#include "shape_impl.h"
Go to the source code of this file.
Definition at line 298 of file shape.cc.
References ASSERT, ASSERTMSG, DEBUGCOUTFNAME, DEBUGLCOUT, HighParser::GetInt(), IncludeParser::GetLineData(), HighParser::GetReal(), HighParser::IsKeyWord(), LASTKEYWORD, MBDYN_EXCEPT_ARGS, MYDEBUG_INPUT, SAFEDELETEARR, SAFENEWARR, and SAFENEWWITHCONSTRUCTOR.
Referenced by ReadAeroData().
302 const char* sKeyWords[] = {
306 "piecewise" "linear",
328 CurrKeyWord = SHAPECONST;
332 if (CurrKeyWord >= 0) {
333 std::cout <<
"shape type: " << sKeyWords[CurrKeyWord] << std::endl;
339 switch (CurrKeyWord) {
368 << da0 <<
", " << da1 << std::endl);
378 case PIECEWISELINEAR: {
379 const char *sType = 0;
380 switch (CurrKeyWord) {
382 sType =
"piecewise const";
385 case PIECEWISELINEAR:
386 sType =
"piecewise linear";
396 silent_cerr(
"Illegal number of points " << np
397 <<
" for " << sType <<
" shape at line "
409 if (px[0] < -1. || px[0] > 1.) {
410 silent_cerr(
"Illegal value " << px[0]
411 <<
" for first point abscissa (must be -1. < x < 1.) "
412 "in " << sType <<
" shape at line "
420 for (
int i = 1; i < np; i++) {
422 if (px[i] <= px[i-1] || px[i] > 1.) {
423 silent_cerr(
"Illegal value " << px[i]
424 <<
" for point " << i + 1 <<
" abscissa "
425 "(must be " << px[i - 1] <<
" < x < 1.) "
426 "in " << sType <<
" shape at line "
436 switch (CurrKeyWord) {
443 case PIECEWISELINEAR:
465 << da0 <<
", " << da1 <<
", " << da2 << std::endl);
476 ASSERTMSG(0,
"You shouldn't have reached this point");
#define MBDYN_EXCEPT_ARGS
#define DEBUGCOUTFNAME(fname)
virtual integer GetInt(integer iDefval=0)
#define SAFEDELETEARR(pnt)
#define ASSERTMSG(expr, msg)
virtual bool IsKeyWord(const char *sKeyWord)
#define ASSERT(expression)
#define SAFENEWWITHCONSTRUCTOR(pnt, item, constructor)
#define SAFENEWARR(pnt, item, sz)
virtual HighParser::ErrOut GetLineData(void) const
#define DEBUGLCOUT(level, msg)
virtual doublereal GetReal(const doublereal &dDefval=0.0)