SIVIC API  0.9.26
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Member Functions | Static Public Member Functions | Static Public Attributes | Protected Member Functions | List of all members
svkUCSFUtils Class Reference

#include <svkUCSFUtils.h>

Inheritance diagram for svkUCSFUtils:

Public Member Functions

 vtkTypeMacro (svkUCSFUtils, vtkObject)
 

Static Public Member Functions

static svkUCSFUtilsNew ()
 
static void CreateMap ()
 Create the map from metabolite proper names to filenames. More...
 
static string GetMetaboliteName (string fileName)
 Gets the name of a metabolite fore a given filename. More...
 
static string GetMetaboliteDirectoryName (string spectraFileName)
 Gets the directory in which a metabolite file should reside. More...
 
static string GetMetaboliteRoot (string spectraFileName)
 Gets the root name for a metabolite file. More...
 
static string GetMetaboliteFileName (string spectraFileName, string metaboliteName, bool includePath=false)
 Get the filename for a given metabolite. More...
 
static string GetMetabolitePostfix (string metaboliteName)
 Get the postfix for a given metabolite. More...
 
static string GetMetaboliteFromPostfix (string postfixName)
 Get the metabolite name for a given postfix. More...
 
static vector< string > GetAllMetaboliteNames ()
 Returns a liste of all metabolites in our hash. More...
 
static string GetDICOMFileName (string fileName, svkDcmHeader *header)
 
static int ReidentifyImages (string directory)
 Reidentify images in a given directory. More...
 

Static Public Attributes

static bool mapCreated = false
 
static map< string, string > metaboliteMap
 Maps metabolite names to file extentions. More...
 

Protected Member Functions

 svkUCSFUtils ()
 Constructor. More...
 
 ~svkUCSFUtils ()
 Destructor. More...
 

Detailed Description

UCSF specific utilities.

Constructor & Destructor Documentation

svkUCSFUtils ( )
protected

Constructor.

~svkUCSFUtils ( )
protected

Destructor.

Member Function Documentation

void CreateMap ( )
static

Create the map from metabolite proper names to filenames.

Creates our hash.

TODO: Consider making the hash read from a text file so we don't have to recompile to add mappings

References svkUCSFUtils::mapCreated, and svkUCSFUtils::metaboliteMap.

Referenced by svkUCSFUtils::GetAllMetaboliteNames(), svkUCSFUtils::GetMetaboliteFromPostfix(), and svkUCSFUtils::GetMetabolitePostfix().

vector< string > GetAllMetaboliteNames ( )
static

Returns a liste of all metabolites in our hash.

Gets the names of all the metabolites in the current hash.

Returns
all the names in a vector of strings

References svkUCSFUtils::CreateMap(), svkUCSFUtils::mapCreated, and svkUCSFUtils::metaboliteMap.

string GetDICOMFileName ( string  fileName,
svkDcmHeader header 
)
static
string GetMetaboliteDirectoryName ( string  spectraFileName)
static

Gets the directory in which a metabolite file should reside.

Method takes a spectra file name and determines the name of the directory in which it should reside.

Parameters
spectraFileNamethe name of the spectra file that you want to find the metabolite

References svkUCSFUtils::GetMetaboliteRoot().

Referenced by svkUCSFUtils::GetMetaboliteFileName().

string GetMetaboliteFileName ( string  spectraFileName,
string  metaboliteName,
bool  includePath = false 
)
static

Get the filename for a given metabolite.

Method takes a spectra file name and determines the filename of a given metabolite for that spectra.

Parameters
spectraFileNamethe name of the spectra file that you want to find the metabolite
metaboliteNamethe metabolite name you are looking for
incluePathshould we include the name of the path in which the file should exist

References svkUCSFUtils::GetMetaboliteDirectoryName(), svkUCSFUtils::GetMetabolitePostfix(), and svkUCSFUtils::GetMetaboliteRoot().

string GetMetaboliteFromPostfix ( string  postfixName)
static

Get the metabolite name for a given postfix.

Get the metabolite name for a given postfix.

Parameters
postfixfor the name of the metabolite you are looking for

References svkUCSFUtils::CreateMap(), svkUCSFUtils::mapCreated, and svkUCSFUtils::metaboliteMap.

Referenced by svkUCSFUtils::GetMetaboliteName().

string GetMetaboliteName ( string  fileName)
static

Gets the name of a metabolite fore a given filename.

Gets the metabolite name for a given metabolite file

References svkUCSFUtils::GetMetaboliteFromPostfix().

string GetMetabolitePostfix ( string  metaboliteName)
static

Get the postfix for a given metabolite.

Get the file name postfix for a given metabolite.

Parameters
metaboliteNamethe name of the metabolite you are looking for

References svkUCSFUtils::CreateMap(), svkUCSFUtils::mapCreated, and svkUCSFUtils::metaboliteMap.

Referenced by svkUCSFUtils::GetMetaboliteFileName().

string GetMetaboliteRoot ( string  spectraFileName)
static

Gets the root name for a metabolite file.

Method takes a spectra file name and determines the name of the root for the metabolites

Parameters
spectraFileNamethe name of the spectra file that you want to find the metabolite root

Referenced by svkUCSFUtils::GetMetaboliteDirectoryName(), and svkUCSFUtils::GetMetaboliteFileName().

static svkUCSFUtils* New ( )
static
int ReidentifyImages ( string  directory)
static

Reidentify images in a given directory.

vtkTypeMacro ( svkUCSFUtils  ,
vtkObject   
)

Member Data Documentation

bool mapCreated = false
static
map< string, string > metaboliteMap
static

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