MURE
Loading...
Searching...
No Matches
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 ()
 
double GetTemperature ()
 
double GetTemperatureInMeV ()
 
int GetDataType ()
 
int GetStartRecord ()
 
int GetTableLength ()
 
int GetRecordLength ()
 
int GetEntriesPerRecord ()
 
int GetZA ()
 
int Z ()
 
int A ()
 
int I ()
 
void SetZ (int aZ)
 
void SetA (int aA)
 
void SetI (int aI)
 
string GetPtable ()
 
string GetExtension ()
 
char GetExtensionType ()
 
string GetXSFileName ()
 
string GetIsotopeName ()
 
string GetDirLine ()
 
string GetPath ()
 
void PrintFormatted (string BaseName, string BaseVersion, string Builder, ostream &Out=cout)
 Print XSDIRLine in a special format for BaseSummary.dat file.
 
void AddNewPathInDirLine (string path)
 modify rhe path in the xsdir line (for futher building of xsdir)
 

Private Member Functions

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

Private Attributes

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

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.
 
static string PreviousWord (string Line, int &start, char sep=' ', char alt_sep='\0')
 Find the previous word in a line.
 
static int GetStartWord (string Line, int CurrentPosition, char sep=' ')
 Find the start of a word in a line.
 
static int GetEndWord (string Line, int CurrentPosition, char sep=' ')
 Find the end of a word in a line.
 
static string ReplaceAll (string InLine, string ToReplace, string By)
 Replace a sub-string by an other in a string.
 
static void ltrim (std::string &s)
 Remove starting spaces (trim) a string.
 
static void rtrim (std::string &s)
 Remove ending spaces (trim) of a string.
 
static void trim (std::string &s)
 Remove spaces (trim) of the begining and the end of a string.
 
static int Find (const char *search, string Line)
 Find search in Line from the begining.
 
static int rFind (const char *search, string Line)
 Find search in Line from the end.
 
static void ToLower (string &Line)
 convert a string to Lower case
 
static void ToUpper (string &Line)
 convert a string to Upper case
 
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).
 
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.
 
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() [1/2]

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() [2/2]

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

◆ A()

int XSDIRLine::A ( )
inline

< returns nucleon number

◆ AddNewPathInDirLine()

void XSDIRLine::AddNewPathInDirLine ( string  path)

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

◆ ClearDoubleSpace()

void XSDIRLine::ClearDoubleSpace ( string &  Line)
private

clear double space in a line

◆ ContinuationSymbol()

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

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

◆ GetDataType()

int XSDIRLine::GetDataType ( )
inline

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

◆ GetDirLine()

string XSDIRLine::GetDirLine ( )
inline

< returns the xsdir line

◆ GetEntriesPerRecord()

int XSDIRLine::GetEntriesPerRecord ( )
inline

< returns entries per record

◆ GetExtension()

string XSDIRLine::GetExtension ( )
inline

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

◆ GetExtensionType()

char XSDIRLine::GetExtensionType ( )
inline

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

◆ GetIsotopeName()

string XSDIRLine::GetIsotopeName ( )
inline

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

◆ GetMass()

double XSDIRLine::GetMass ( )
inline

< returns the nucleide weight in Atomic Mass Unit

◆ GetPath()

string XSDIRLine::GetPath ( )
inline

< returns the path if exist else 0

◆ GetPtable()

string XSDIRLine::GetPtable ( )
inline

< returns the "ptable" string when exists in xsdir line

◆ GetRecordLength()

int XSDIRLine::GetRecordLength ( )
inline

< returns the record length

◆ GetStartRecord()

int XSDIRLine::GetStartRecord ( )
inline

< returns the starting record of data

◆ GetTableLength()

int XSDIRLine::GetTableLength ( )
inline

< returns the length of the 2nd block

◆ GetTemperature()

double XSDIRLine::GetTemperature ( )
inline

< returns the temperature at which XS are processed

◆ GetTemperatureInMeV()

double XSDIRLine::GetTemperatureInMeV ( )
inline

< returns the temperature at which XS are processed

◆ GetXSFileName()

string XSDIRLine::GetXSFileName ( )
inline

< returns the XS file name (path/filename)

◆ GetZA()

int XSDIRLine::GetZA ( )
inline

< returns the ZA=Z*1000+A

◆ I()

int XSDIRLine::I ( )
inline

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

◆ PrintFormatted()

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

◆ ReadLine()

void XSDIRLine::ReadLine ( )
private

extracts data from the xsdir line

◆ SetA()

void XSDIRLine::SetA ( int  aA)
inline

< set nucleon number

◆ SetI()

void XSDIRLine::SetI ( int  aI)
inline

< Set isomeric state to I

◆ SetZ()

void XSDIRLine::SetZ ( int  aZ)
inline

< set proton number

◆ SpecialMTCase()

void XSDIRLine::SpecialMTCase ( )
private

special MT code of ENDB6

◆ Z()

int XSDIRLine::Z ( )
inline

< returns proton number

Member Data Documentation

◆ fA

int XSDIRLine::fA
private

number of nucleons (A=0 means natural isotopes)

◆ fContinuationPosition

int XSDIRLine::fContinuationPosition
private

Position of Continuation symbol in the Current fLine.

◆ fContinuationSymbol

char XSDIRLine::fContinuationSymbol
private

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

◆ fDataType

int XSDIRLine::fDataType
private

Data Type (1=ascii, 2=binary)

◆ fDirLine

string XSDIRLine::fDirLine
private

the whole Line

◆ fEntriesPerRecord

int XSDIRLine::fEntriesPerRecord
private

Number of entries per record.

◆ fExtension

string XSDIRLine::fExtension
private

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

◆ fI

int XSDIRLine::fI
private

Isomeric state (Ground State, ith excited)

◆ fIsotopeName

string XSDIRLine::fIsotopeName
private

Isotope Name of the Original ENDF Library.

◆ fMass

double XSDIRLine::fMass
private

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

◆ fPath

string XSDIRLine::fPath
private

the path where to find library if given else 0

◆ fPtable

string XSDIRLine::fPtable
private

ptable card (if exists)

◆ fRecordLength

int XSDIRLine::fRecordLength
private

Length of a record.

◆ fStartRecord

int XSDIRLine::fStartRecord
private

First Start Record for the Isotope.

◆ fTableLength

int XSDIRLine::fTableLength
private

Length of the second block (XS table)

◆ fTemperature

double XSDIRLine::fTemperature
private

Temperature of the Cross-section.

◆ fXSFileName

string XSDIRLine::fXSFileName
private

File Name of the Original ENDF Library.

◆ fZ

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.9.7 - Fri Jan 19 2024