Main Page   Modules   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

OSCAR::Repository Class Reference
[PerformanceCriteria]

Repository is a base repository class from which all repository types will derive. These repositories store data computed by the criteria in order to prevent repeat calculations. All computational ability is in the performance criteria - repositories store data only. Repository contains the functionality to keep track of whether the repository has been updated. The methods to get and set the data members inside the repository were placed in the derived template class TypeRepository so the same methods could be used for several repository types. The reason this base class is necessary is because RepositoryList cannot point to a template class. More...

#include <Repository.h>

Inheritance diagram for OSCAR::Repository:

Inheritance graph
[legend]
List of all members.

Public Methods

 Repository (unsigned int maxNoSolutions, const String &objectName=String(""))
bool GetUpdatedStatus (unsigned int solutionNum) const
void SetUpdatedStatus (bool newStatus)
void SetUpdatedStatus (unsigned int solutionNum, bool newStatus)
 Repository (const Repository &repo)
Repository & operator= (const Repository &repo)
virtual ~Repository ()

Protected Attributes

unsigned int maxNoSolutions
BoolArrayupdateStatus

Detailed Description

Author:
Chetan Kapoor and Mark Tisius


Constructor & Destructor Documentation

OSCAR::Repository::Repository unsigned int    maxNoSolutions,
const String   objectName = String("")
 

Constructor for Repository This constructor creates a repository object Repository that holds manipulator specific data needed to calculate certain criteria. This is a storage class only all computational ability is relegated to the criteria.

Parameters:
maxNoSolutions Unsigned int that specifies the maximum number of solutions for memory allocation.
objectName String which specifies the name of the Repository object.

OSCAR::Repository::Repository const Repository &    repo
 

Copy Constructor for Repository Use this to create a Repository object whose defaults are set via the constructor argument.

Parameters:
repo A Repository object that is used to create the new object

virtual OSCAR::Repository::~Repository   [virtual]
 

Destructor for Repository();.


Member Function Documentation

bool OSCAR::Repository::GetUpdatedStatus unsigned int    solutionNum const
 

Use this method to return if the individual repository member has been updated. Criteria will test this to avoid using old data. It should be set to false after new a new set of joint solutions has been entered and set to true after a criteria updates the data based on the new solutions set.

Returns:
true if updated and false not updated
Parameters:
solutionNum The solution number of the update flag to be returned.

Repository& OSCAR::Repository::operator= const Repository &    repo
 

Copy operator for Repository Use this to copy one Repository object into another. If the maxNoSolutions are different then an error will be given and then the original will be resized.

Returns:
A reference to itself
Parameters:
repo A Repository object that is copied into the calling object.

void OSCAR::Repository::SetUpdatedStatus unsigned int    solutionNum,
bool    newStatus
 

Use this method to reset individual repository members. When the configuration of the manipulator changes the previously computed data is no longer valid so criteria will call reset. Reset will change updated to false.

Parameters:
solutionNum The solution number of the update flag to be changed.
newStatus The new status to set updated to.

void OSCAR::Repository::SetUpdatedStatus bool    newStatus
 

Use this method to reset the repositories. When the configuration of the manipulator changes the previously computed data is no longer valid so criteria will call reset. Reset will change updated to false.

Parameters:
newStatus The new status to set updated to.


Member Data Documentation

unsigned int OSCAR::Repository::maxNoSolutions [protected]
 

BoolArray* OSCAR::Repository::updateStatus [protected]
 


The documentation for this class was generated from the following file:
RRG Homepage OSCAR Overview OSCAR Tutorials Simulations