lib/test/EBAMRTools/restart.cpp
/** InputParams are the things in restart.inputs.
 *  This is the only place we use ParmParse.
*/
InputParams are the things in restart.inputs.
This is the only place we use ParmParse.
InputParams are the things in restart . inputs . This is the only place we use ParmParse .
EBRestart::InputParams::InputParams(
    int argc, char** argv, const char* a_infilename )
  : n_cell(SpaceDim),
    prob_lo(SpaceDim, 1.0),
    ncomps(0),
    ghosts(0),
    first_step(0),
    test_mode(0),
    test_pass(1),
    verbose(0)
{
  ParmParse pp(argc-1, argv+1, 0, a_infilename);
  pp.getarr("n_cell",n_cell,0,SpaceDim);
  CH_assert(n_cell.size() == SpaceDim);
  pp.getarr("prob_lo",prob_lo,0,SpaceDim);
  pp.get("prob_hi",prob_hi);
  Vector<Real> vcenter;
  pp.getarr("center",vcenter,0,SpaceDim);
  center = RealVect( D_DECL(vcenter[0],vcenter[1],vcenter[2]) );
  pp.get("radius",radius);
  pp.get("nlevs",nlevs);
  pp.get("ncomps",ncomps);
  pp.query("ghosts",ghosts);
  pp.get("refratio",refratio);
  pp.get("nsteps",nsteps);
  pp.get("first_step",first_step);
  CH_assert( first_step < nsteps );
  pp.get("blocking_factor",blocking_factor);
  pp.get("buffer_size",buffer_size);
  pp.get("max_size",max_size);
  pp.get("test_mode",test_mode);
  pp.query("test_pass",test_pass);
  CH_assert( (test_pass == 1) || (test_pass == 2) );
  pp.query("verbose", verbose);
}
EBRestart :: InputParams :: InputParams ( int argc , char * * argv , const char * a_infilename ) : n_cell ( SpaceDim ) , prob_lo ( SpaceDim , 1.0 ) , ncomps ( 0 ) , ghosts ( 0 ) , first_step ( 0 ) , test_mode ( 0 ) , test_pass ( 1 ) , verbose ( 0 ) { ParmParse pp ( argc - 1 , argv + 1 , 0 , a_infilename ) ; pp . getarr ( " " , n_cell , 0 , SpaceDim ) ; CH_assert ( n_cell . size ( ) == SpaceDim ) ; pp . getarr ( " " , prob_lo , 0 , SpaceDim ) ; pp . get ( " " , prob_hi ) ; Vector < Real > vcenter ; pp . getarr ( " " , vcenter , 0 , SpaceDim ) ; center = RealVect ( D_DECL ( vcenter [ 0 ] , vcenter [ 1 ] , vcenter [ 2 ] ) ) ; pp . get ( " " , radius ) ; pp . get ( " " , nlevs ) ; pp . get ( " " , ncomps ) ; pp . query ( " " , ghosts ) ; pp . get ( " " , refratio ) ; pp . get ( " " , nsteps ) ; pp . get ( " " , first_step ) ; CH_assert ( first_step < nsteps ) ; pp . get ( " " , blocking_factor ) ; pp . get ( " " , buffer_size ) ; pp . get ( " " , max_size ) ; pp . get ( " " , test_mode ) ; pp . query ( " " , test_pass ) ; CH_assert ( ( test_pass == 1 ) || ( test_pass == 2 ) ) ; pp . query ( " " , verbose ) ; }
InputParams are the things in restart.inputs.
InputParams are the things in restart . inputs .