FEDEM Solver  R8.0
Source code of the dynamics solver
Functions | Variables
FFrExtractor_F.C File Reference

Fortran wrapper for the FFrExtractor methods. More...

#include "FFrLib/FFrExtractor.H"
#include "FFaLib/FFaCmdLineArg/FFaCmdLineArg.H"
#include "FFaLib/FFaString/FFaTokenizer.H"
#include "FFaLib/FFaDefinitions/FFaResultDescription.H"
#include "FFaLib/FFaDefinitions/FFaMsg.H"
#include "FFaLib/FFaOS/FFaFilePath.H"
#include "FFaLib/FFaOS/FFaFortran.H"
Include dependency graph for FFrExtractor_F.C:

Functions

 SUBROUTINE (ffr_init, FFR_INIT) const
 Opens the results database and reads file headers. More...
 
 SUBROUTINE (ffr_done, FFR_DONE)()
 Releases the FFrExtractor object. More...
 
static FFrEntryBasefindPtr (const std::string &path, const std::string &ogType, int baseId, const char *=NULL)
 Static helper for finding file position of a result variable. More...
 
 SUBROUTINE (ffr_findptr, FFR_FINDPTR) const
 Finds file position of the specified result variable. More...
 
 SUBROUTINE (ffr_realdata, FFR_REALDATA) const
 Locates results data within current time step for specified variable. More...
 
 SUBROUTINE (ffr_intdata, FFR_INTDATA) const
 Locates results data within current time step for specified variable. More...
 
 SUBROUTINE (ffr_setposition, FFR_SETPOSITION) const
 Positions the results file(s) for the specified time step. More...
 
 SUBROUTINE (ffr_increment, FFR_INCREMENT)
 Positions the results file(s) for the next time step. More...
 
 SUBROUTINE (ffr_getdata, FFR_GETDATA) const
 Reads the contents of the variable or item group. More...
 

Variables

static FFrExtractorourRdb = NULL
 Pointer to the extractor object. More...
 
static FFrEntryBasestepPtr = NULL
 Pointer to the step number variable. More...
 

Detailed Description

Fortran wrapper for the FFrExtractor methods.

This file contains some global-scope functions callable from Fortran. It only wraps the functionality needed by the solvers for accessing the RDB, e.g., during recovery and/or restart operations.

Author
Knut Morten Okstad
Date
9 Oct 2000

Function Documentation

◆ findPtr()

static FFrEntryBase* findPtr ( const std::string &  path,
const std::string &  ogType,
int  baseId,
const char *  = NULL 
)
static

Static helper for finding file position of a result variable.

Parameters
[in]pathVariable description
[in]ogTypeType name of the object we are searching results for
[in]baseIdUnique identifier of the object we are searching for

This function computes the relative file position pointer within a time step for the data pertaining to the specified variable or item group, within the specified owner group identified by ogType and baseId.

The variable- or item group specification string path contains the full path of the wanted object in the result database hierarchy using the '|' character to separate between the different levels.

Author
Knut Morten Okstad
Date
14 Nov 2000

◆ SUBROUTINE() [1/8]

SUBROUTINE ( ffr_done  ,
FFR_DONE   
)

Releases the FFrExtractor object.

◆ SUBROUTINE() [2/8]

SUBROUTINE ( ffr_findptr  ,
FFR_FINDPTR   
) const

Finds file position of the specified result variable.

See also
findPtr()
Author
Knut Morten Okstad
Date
14 Nov 2000

◆ SUBROUTINE() [3/8]

SUBROUTINE ( ffr_getdata  ,
FFR_GETDATA   
) const

Reads the contents of the variable or item group.

Reads the data pointed to by varPtr within current time step, as set by ffr_setposition() from the results database.

Author
Knut Morten Okstad
Date
14 Nov 2000

◆ SUBROUTINE() [4/8]

SUBROUTINE ( ffr_increment  ,
FFR_INCREMENT   
)

Positions the results file(s) for the next time step.

Increment sll result containers of the extractor such that the next ffr_getdata() operations read result data from the next time step, if any. The physical time of the time step that is found is returned through the variable btime.

Author
Knut Morten Okstad
Date
21 May 2001

◆ SUBROUTINE() [5/8]

SUBROUTINE ( ffr_init  ,
FFR_INIT   
) const

Opens the results database and reads file headers.

◆ SUBROUTINE() [6/8]

SUBROUTINE ( ffr_intdata  ,
FFR_INTDATA   
) const

Locates results data within current time step for specified variable.

Finds the data pertaining to the specified integer variable within the owner group identified by objectType and baseId.

The variable specification string pathName contains the full path of the wanted object in the result database hierarchy using the '|' character to separate between the different levels.

Author
Knut Morten Okstad
Date
24 Jun 2002

◆ SUBROUTINE() [7/8]

SUBROUTINE ( ffr_realdata  ,
FFR_REALDATA   
) const

Locates results data within current time step for specified variable.

Finds the data pertaining to the specified variable or item group within the owner group identified by objectType and baseId.

The variable- or item group specification string pathName contains the full path of the wanted object in the result database hierarchy using the '|' character to separate between the different levels.

Author
Knut Morten Okstad
Date
24 Jun 2002

◆ SUBROUTINE() [8/8]

SUBROUTINE ( ffr_setposition  ,
FFR_SETPOSITION   
) const

Positions the results file(s) for the specified time step.

Position all result containers of the extractor such that the next ffr_getdata() operations read result data from the time step corresponding to the physical time atime (or the step that is closest to this time). The physical time of the time step that is found is returned through the variable btime.

Note
Current implementation finds the next larger position through use of the boolean flag getNextHigh.
Author
Knut Morten Okstad
Date
14 Nov 2000

Variable Documentation

◆ ourRdb

FFrExtractor* ourRdb = NULL
static

Pointer to the extractor object.

◆ stepPtr

FFrEntryBase* stepPtr = NULL
static

Pointer to the step number variable.