Loading [MathJax]/extensions/tex2jax.js
AngleType.hpp
1 #pragma once
2 
3 //OPALS
4 #include "opals/config.hpp"
5 #include "opals/String.hpp"
6 #include "opals/CustomOptionType.hpp"
7 
8 namespace opals
9 {
10  /// \brief AngleType provides defining angular values in different units (deg, rad, grad and percentage)
11  ///
12  ///
13  /// \author JO
14  /// \date 19.05.2023
15  class OPALS_API AngleType : public CustomOptionType<AngleType>
16  {
17  public:
18  AngleType();
19  AngleType(const opals::String &rep);
20  AngleType(double vale); ///< set angle in degrees (default)
21  virtual ~AngleType();
22 
23  bool isEmpty() const;
24 
25  double getRad() const; ///< get angle in radiates (0-2*Pi)
26  double getDeg() const; ///< get angle in degres (0-360)
27  double getGrad() const; ///< get angle in grads (0-400)
28  double getPerc() const; ///< get a slope angle in percent (0-infinite)
29 
30  operator double() const;
31 
32  void reset();
33 
34  void setRad(const double& value);
35  void setDeg(const double& value);
36  void setGrad(const double& value);
37  void setPerc(const double& value);
38 
39  bool operator==(const AngleType &ref) const;
40  bool operator!=(const AngleType &ref) const;
41 
42  static const char* help(bool);
43  static const char* syntax();
44  static bool exportsPythonType();
45 
46  private:
47  double angleDeg; ///< internally stores angle value in degrees
48  };
49 }
def fprjdir(prjdir)
analyzes input parameter and returns filelist, pairs
Definition: analyzeInput.py:194
Base class for all custom parameter types.
Definition: CustomOptionType.hpp:39
Reflects Python's built-in class exceptions.SyntaxError.
Definition: c++_api/inc/opals/Exception.hpp:382
def ftemp(temp, prjdir, outdir, scriptname)
analyzes temp parameter and returns tempdir
Definition: analyzeInput.py:370
def fcfgP(cfg, prjdir, allscripts, scriptname, fullscriptpath)
"analyzes cfg parameter and returns the cfgs for each subscript
Definition: analyzeInput.py:497
def fsettingsP(txtfile, prjdir, allscripts)
reads settings-textfile and returns the settings for each subscript
Definition: analyzeInput.py:419
Process opals jobs using the ipyparallel (ipp) framework.
Definition: processor.py:460
thrown if the provided filename doesn't exist.
Definition: c++_api/inc/opals/Exception.hpp:238
def standardinput(inp)
analyzes non-textfile inputs including wildcards; returns filelist
Definition: analyzeInput.py:331
Interface of a processor in the opals framework of which the others are derived.
Definition: processor.py:18
programming error which appears if the opals framework wasn't used correctly;
Definition: c++_api/inc/opals/Exception.hpp:200
def foutP(out, temp, prjdir, allscripts, scriptname)
analyzes out parameter and returns the outdirs for each subscript
Definition: analyzeInput.py:449
AngleType provides defining angular values in different units (deg, rad, grad and percentage)
Definition: AngleType.hpp:15
def fcfg(cfg, prjdir, scriptname, fullscriptpath)
analyzes cfg parameter and returns the path of the cfg-file
Definition: analyzeInput.py:385
def finp(inp, prjdir, supportFilter=False)
analyzes the input parameters and returns filelist, pairs
Definition: analyzeInput.py:212
Process opals jobs on the local machine in current process (no parallelization)
Definition: processor.py:34
Definition: analyzeInput.py:28
Reflects Python's built-in class exceptions.TypeError.
Definition: c++_api/inc/opals/Exception.hpp:390
def fout(out, prjdir, scriptname)
analyzes out parameter and returns outdir
Definition: analyzeInput.py:356
Reflects Python's built-in class exceptions.ValueError.
Definition: c++_api/inc/opals/Exception.hpp:398
def textfileinput(inp, filedir, supportFilter)
reads textfile and returns filelist, pairs
Definition: analyzeInput.py:254
Contains the public interface of OPALS.
Definition: AbsValueOrQuantile.hpp:8
def findfile(f, fdir)
"searches filedir for a certain strip file or odm file, returns boolean
Definition: analyzeInput.py:317
def argumentSplit(obj, separator=';', old_type=str)
splitting a string or a list of strings by a given separator into a list
Definition: analyzeInput.py:80
def ftempP(temp, prjdir, outdirs, allscripts, scriptname)
analyzes temp parameter and returns the tempdirs for each subscript
Definition: analyzeInput.py:482
Definition: analyzeInput.py:559
Process opals jobs using multiple processes.
Definition: processor.py:391
def analyzeInputPackages(fullscriptpath, pairboolean, allscripts, inp=None, out=None, temp=None, cfg=None, prjdir=None, distribute=None, subScriptList=None, subScriptString=None, skipIfExists=None)
analyzes the parser arguments (inp, out, temp, cfg) and returns script parameters (filelist,...
Definition: analyzeInput.py:143
a general parameter error (usually comes from boost::program_options)
Definition: c++_api/inc/opals/Exception.hpp:206
def analyzeInput(fullscriptpath, pairboolean, inp=None, out=None, temp=None, cfg=None, prjdir=None, distribute=None, skipIfExists=None)
analyzes the parser arguments (inp, out, temp, cfg, prjdir, distribute) and returns script parameters...
Definition: analyzeInput.py:107
A dynamic character string whose interface conforms to STL's std::string.
Definition: String.hpp:35