MURE
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros
Public Member Functions | Private Member Functions | Private Attributes | List of all members
XSDIRLine Class Reference

Extract all parameters from an XSDIR line. More...

#include <XSDIRLine.hxx>

Inheritance diagram for XSDIRLine:
StringLine

Public Member Functions

 XSDIRLine (string *line, int n)
 
 XSDIRLine (string line)
 
double GetMass ()
 returns the nucleide weight in Atomic Mass Unit More...
 
double GetTemperature ()
 returns the temperature at which XS are processed More...
 
double GetTemperatureInMeV ()
 returns the temperature at which XS are processed More...
 
int GetDataType ()
 returns data type storage (1=ascii, 2=binary) More...
 
int GetStartRecord ()
 returns the starting record of data More...
 
int GetTableLength ()
 returns the length of the 2nd block More...
 
int GetRecordLength ()
 returns the record length More...
 
int GetEntriesPerRecord ()
 returns entries per record More...
 
int GetZA ()
 returns the ZA=Z*1000+A More...
 
int Z ()
 returns proton number More...
 
int A ()
 returns nucleon number More...
 
int I ()
 returns isomeric state (0=ground state, 1= 1st excited,...) More...
 
void SetZ (int Z)
 set proton number More...
 
void SetA (int A)
 set nucleon number More...
 
void SetI (int I)
 Set isomeric state to I. More...
 
string GetPtable ()
 returns the "ptable" string when exists in xsdir line More...
 
string GetExtension ()
 returns in ZA.id name, the ".id" string More...
 
char GetExtensionType ()
 returns the extension type (e.g. in 92238.60c returns "c") More...
 
string GetXSFileName ()
 returns the XS file name (path/filename) More...
 
string GetIsotopeName ()
 returns Isotope name (e.g. in 92238.60c returns "92238") More...
 
string GetDirLine ()
 returns the xsdir line More...
 
string GetPath ()
 returns the path if exist else 0 More...
 
void PrintFormatted (string BaseName, string BaseVersion, string Builder, ostream &Out=cout)
 Print XSDIRLine in a special format for BaseSummary.dat file. More...
 
void AddNewPathInDirLine (string path)
 modify rhe path in the xsdir line (for futher building of xsdir) More...
 

Private Member Functions

void ClearDoubleSpace (string &Line)
 clear double space in a line More...
 
void ReadLine ()
 extracts data from the xsdir line More...
 
void SpecialMTCase ()
 special MT code of ENDB6 More...
 
void ContinuationSymbol (string *Line, int N)
 find the continuation symbol ("+" or "&") and its position More...
 

Private Attributes

char fContinuationSymbol
 Continuation symbol in xsdir (a "+" or "&") More...
 
int fContinuationPosition
 Position of Continuation symbol in the Current fLine. More...
 
double fMass
 Mass of an isotope in neutron mass unit (MCNP convention) More...
 
double fTemperature
 Temperature of the Cross-section. More...
 
int fDataType
 Data Type (1=ascii, 2=binary) More...
 
string fXSFileName
 File Name of the Original ENDF Library. More...
 
string fIsotopeName
 Isotope Name of the Original ENDF Library. More...
 
string fExtension
 Isotope extension (e.g. ".60c") More...
 
int fStartRecord
 First Start Record for the Isotope. More...
 
int fTableLength
 Length of the second block (XS table) More...
 
int fRecordLength
 Length of a record. More...
 
int fEntriesPerRecord
 Number of entries per record. More...
 
string fPath
 the path where to find library if given else 0 More...
 
string fPtable
 ptable card (if exists) More...
 
string fDirLine
 the whole Line More...
 
int fZ
 number of protons More...
 
int fA
 number of nucleons (A=0 means natural isotopes) More...
 
int fI
 Isomeric state (Ground State, ith excited) More...
 

Additional Inherited Members

- Static Public Member Functions inherited from StringLine
static string NextWord (string Line, int &start, char sep=' ', char alt_sep='\0')
 Find the next word in a line. More...
 
static string PreviousWord (string Line, int &start, char sep=' ', char alt_sep='\0')
 Find the previous word in a line. More...
 
static void ToLower (string &Line)
 convert a string to Lower case More...
 
static void ToUpper (string &Line)
 convert a string to Upper case More...
 
static int Find (const char *search, string Line)
 Find search in Line from the begining. More...
 
static int rFind (const char *search, string Line)
 Find search in Line from the end. More...
 
template<class out_T , class in_T >
static out_T convert (const in_T &t)
 convert a input type (in_T) to another (out_T). More...
 
template<class T >
static bool ToNumber (T &t, const std::string &s, std::ios_base &(*f)(std::ios_base &))
 try to convert a string to a number. More...
 
static int GetStartWord (string Line, int CurrentPosition, char sep=' ', char alt_sep='\0')
 Find the start of a word in a line. More...
 
static int GetEndWord (string Line, int CurrentPosition, char sep=' ', char alt_sep='\0')
 Find the end of a word in a line. More...
 
static string ReplaceAll (string InLine, string ToReplace, string By)
 Replace a sub-string by an other in a string. More...
 
static bool IsDouble (const std::string &s)
 

Detailed Description

Extract all parameters from an XSDIR line.

Author
PTO
Version
0.1

Constructor & Destructor Documentation

XSDIRLine::XSDIRLine ( string *  line,
int  n 
)

Normal Constructor. Extraction of parameters of an XSDIR line

Parameters
line: a string array ([n]) of XSDIR line for a given isotope
n: dimension of the array line
XSDIRLine::XSDIRLine ( string  line)

Normal Constructor. Extraction of parameters of an XSDIR line

Parameters
line: the XSDIR line for a given isotope (1 line)

Member Function Documentation

int XSDIRLine::A ( )
inline

returns nucleon number

void XSDIRLine::AddNewPathInDirLine ( string  path)

modify rhe path in the xsdir line (for futher building of xsdir)

void XSDIRLine::ClearDoubleSpace ( string &  Line)
private

clear double space in a line

void XSDIRLine::ContinuationSymbol ( string *  Line,
int  N 
)
private

find the continuation symbol ("+" or "&") and its position

int XSDIRLine::GetDataType ( )
inline

returns data type storage (1=ascii, 2=binary)

string XSDIRLine::GetDirLine ( )
inline

returns the xsdir line

int XSDIRLine::GetEntriesPerRecord ( )
inline

returns entries per record

string XSDIRLine::GetExtension ( )
inline

returns in ZA.id name, the ".id" string

char XSDIRLine::GetExtensionType ( )
inline

returns the extension type (e.g. in 92238.60c returns "c")

string XSDIRLine::GetIsotopeName ( )
inline

returns Isotope name (e.g. in 92238.60c returns "92238")

double XSDIRLine::GetMass ( )
inline

returns the nucleide weight in Atomic Mass Unit

string XSDIRLine::GetPath ( )
inline

returns the path if exist else 0

string XSDIRLine::GetPtable ( )
inline

returns the "ptable" string when exists in xsdir line

int XSDIRLine::GetRecordLength ( )
inline

returns the record length

int XSDIRLine::GetStartRecord ( )
inline

returns the starting record of data

int XSDIRLine::GetTableLength ( )
inline

returns the length of the 2nd block

double XSDIRLine::GetTemperature ( )
inline

returns the temperature at which XS are processed

double XSDIRLine::GetTemperatureInMeV ( )
inline

returns the temperature at which XS are processed

string XSDIRLine::GetXSFileName ( )
inline

returns the XS file name (path/filename)

int XSDIRLine::GetZA ( )
inline

returns the ZA=Z*1000+A

int XSDIRLine::I ( )
inline

returns isomeric state (0=ground state, 1= 1st excited,...)

void XSDIRLine::PrintFormatted ( string  BaseName,
string  BaseVersion,
string  Builder,
ostream &  Out = cout 
)

Print XSDIRLine in a special format for BaseSummary.dat file.

Parameters
BaseName: the name of the base (e.g. ENDFB, JEFF, ...)
BaseVersion: the version of the base (e.g. 6.1, 3.2, ...)
Builder: the base builder (one of STD, JOY, MOD)
Out: Output stream
void XSDIRLine::ReadLine ( )
private

extracts data from the xsdir line

void XSDIRLine::SetA ( int  A)
inline

set nucleon number

void XSDIRLine::SetI ( int  I)
inline

Set isomeric state to I.

void XSDIRLine::SetZ ( int  Z)
inline

set proton number

void XSDIRLine::SpecialMTCase ( )
private

special MT code of ENDB6

int XSDIRLine::Z ( )
inline

returns proton number

Member Data Documentation

int XSDIRLine::fA
private

number of nucleons (A=0 means natural isotopes)

int XSDIRLine::fContinuationPosition
private

Position of Continuation symbol in the Current fLine.

char XSDIRLine::fContinuationSymbol
private

Continuation symbol in xsdir (a "+" or "&")

int XSDIRLine::fDataType
private

Data Type (1=ascii, 2=binary)

string XSDIRLine::fDirLine
private

the whole Line

int XSDIRLine::fEntriesPerRecord
private

Number of entries per record.

string XSDIRLine::fExtension
private

Isotope extension (e.g. ".60c")

int XSDIRLine::fI
private

Isomeric state (Ground State, ith excited)

string XSDIRLine::fIsotopeName
private

Isotope Name of the Original ENDF Library.

double XSDIRLine::fMass
private

Mass of an isotope in neutron mass unit (MCNP convention)

string XSDIRLine::fPath
private

the path where to find library if given else 0

string XSDIRLine::fPtable
private

ptable card (if exists)

int XSDIRLine::fRecordLength
private

Length of a record.

int XSDIRLine::fStartRecord
private

First Start Record for the Isotope.

int XSDIRLine::fTableLength
private

Length of the second block (XS table)

double XSDIRLine::fTemperature
private

Temperature of the Cross-section.

string XSDIRLine::fXSFileName
private

File Name of the Original ENDF Library.

int XSDIRLine::fZ
private

number of protons


The documentation for this class was generated from the following files:

MURE Project, documentation generated by Doxygen 1.8.5 - Mon Nov 17 2014