ITK  4.1.0
Insight Segmentation and Registration Toolkit
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes
itk::ArchetypeSeriesFileNames Class Reference

#include <itkArchetypeSeriesFileNames.h>

+ Inheritance diagram for itk::ArchetypeSeriesFileNames:
+ Collaboration diagram for itk::ArchetypeSeriesFileNames:

List of all members.

Public Types

typedef std::vector< int > IntVectorType
typedef SmartPointer< SelfPointer
typedef ArchetypeSeriesFileNames Self
typedef std::vector< std::string > StringVectorType
typedef Object Superclass
typedef vcl_size_t VectorSizeType

Public Member Functions

virtual ::itk::LightObject::Pointer CreateAnother (void) const
virtual const char * GetArchetype () const
const StringVectorTypeGetFileNames (VectorSizeType group=0)
virtual const char * GetNameOfClass () const
VectorSizeType GetNumberOfGroupings ()
void SetArchetype (const std::string &archetype)

Static Public Member Functions

static Pointer New ()

Protected Member Functions

 ArchetypeSeriesFileNames ()
void PrintSelf (std::ostream &os, Indent indent) const
void Scan ()
 ~ArchetypeSeriesFileNames ()

Private Member Functions

 ArchetypeSeriesFileNames (const Self &)
void operator= (const Self &)

Private Attributes

std::string m_Archetype
TimeStamp m_ArchetypeMTime
StringVectorType m_FileNames
std::vector< StringVectorTypem_Groupings
TimeStamp m_ScanTime

Detailed Description

Generate an ordered sequence of filenames.

This class generates an ordered sequence of files based on an archetypical filename. From the archetypical filename, a set of regular expressions is created to group filenames based on numeric substrings. There can be multiple numeric substrings in the archetype. When this occurs, ArchetypeSeriesFileNames can not determine which numeric substring refers to the "image number" and which numeric substring refers to the "series" or "study". By default, the ArchetypeSeriesFileNames assumes the rightmost numeric substring refers to the image number, and this is the group of filenames returned by default. However, the other groupings of filenames can also be queried by passing in a group number to the GetFileNames() method. Groups are numbered by the numeric substrings from right to left in the archetype.

For example, if a directory contains the files

foo_5_1.png foo_5_2.png foo_5_3.png foo_6_1.png foo_6_2.png foo_6_3.png

and specifying an archetypical file foo_5_1.png, the filename list will contain

foo_5_1.png foo_5_2.png foo_5_3.png

Definition at line 67 of file itkArchetypeSeriesFileNames.h.


Member Typedef Documentation

Helper types for managing the groups of filenames and their sizes

Definition at line 95 of file itkArchetypeSeriesFileNames.h.

Reimplemented from itk::Object.

Definition at line 73 of file itkArchetypeSeriesFileNames.h.

Standard class typedefs.

Reimplemented from itk::Object.

Definition at line 71 of file itkArchetypeSeriesFileNames.h.

typedef std::vector< std::string > itk::ArchetypeSeriesFileNames::StringVectorType

Definition at line 96 of file itkArchetypeSeriesFileNames.h.

Reimplemented from itk::Object.

Definition at line 72 of file itkArchetypeSeriesFileNames.h.

Definition at line 87 of file itkArchetypeSeriesFileNames.h.


Constructor & Destructor Documentation

Definition at line 105 of file itkArchetypeSeriesFileNames.h.


Member Function Documentation

virtual::itk::LightObject::Pointer itk::ArchetypeSeriesFileNames::CreateAnother ( void  ) const [virtual]

Create an object from an instance, potentially deferring to a factory. This method allows you to create an instance of an object that is exactly the same type as the referring object. This is useful in cases where an object has been cast back to a base class.

Reimplemented from itk::Object.

virtual const char* itk::ArchetypeSeriesFileNames::GetArchetype ( ) const [virtual]

Returns a vector containing the series' file names. The file names are ordered by Index. Defaults to returning the filenames to the rightmost grouping.

virtual const char* itk::ArchetypeSeriesFileNames::GetNameOfClass ( ) const [virtual]

Run-time type information (and related methods).

Reimplemented from itk::Object.

Get the number of groupings that match the Archetype

Method for creation through the object factory.

Reimplemented from itk::Object.

void itk::ArchetypeSeriesFileNames::operator= ( const Self ) [private]

Mutex lock to protect modification to the reference count

Reimplemented from itk::Object.

void itk::ArchetypeSeriesFileNames::PrintSelf ( std::ostream &  os,
Indent  indent 
) const [protected, virtual]

Methods invoked by Print() to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.

Reimplemented from itk::Object.

Method that actually does the archetype matching/grouping

void itk::ArchetypeSeriesFileNames::SetArchetype ( const std::string &  archetype)

Member Data Documentation

A string for formatting the names of files in the series.

Definition at line 116 of file itkArchetypeSeriesFileNames.h.

Definition at line 122 of file itkArchetypeSeriesFileNames.h.

Definition at line 119 of file itkArchetypeSeriesFileNames.h.

Definition at line 118 of file itkArchetypeSeriesFileNames.h.

Definition at line 123 of file itkArchetypeSeriesFileNames.h.


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