Matrix Science header
Public Member Functions

ms_quant_component Class Reference
[Mascot configuration files module]

An object of this class represent a single component element in quantitation.xml. More...

#include <ms_quant_component.hpp>

Collaboration diagram for ms_quant_component:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 ms_quant_component ()
 Default constructor.
 ms_quant_component (const ms_quant_component &src)
 Copying constructor.
virtual ~ms_quant_component ()
 Destructor.
void appendCorrection (const ms_quant_correction *correction)
 Adds a new correction element at the end of the list.
void appendIsotope (const ms_quant_isotope *isotope)
 Adds a new isotope element at the end of the list.
void appendModificationGroup (const ms_quant_modgroup *item)
 Adds a new modification group at the end of the list.
void clearCorrections ()
 Deletes all correction elements from the list.
void clearIsotopes ()
 Deletes all isotope elements from the list.
void clearModificationGroups ()
 Deletes all modification groups from the list.
void copyFrom (const ms_quant_component *right)
 Copies all content from another instance.
void defaultValues ()
 Call this member if you want to start again.
bool deleteCorrection (const int idx)
 Remove a correction element from the list.
bool deleteIsotope (const int idx)
 Remove a isotope element from the list.
bool deleteModificationGroupByName (const char *name)
 Remove a modification group from the list in memory by its unique name.
bool deleteModificationGroupByNumber (const int idx)
 Remove a modification group from the list in memory by its index.
void dropFileIndex ()
 Delete the file_index element.
void dropMoverz ()
 Delete the moverz element.
void dropName ()
 Delete the name attribute.
void dropSatellite ()
 Delete the satellite element.
const ms_quant_correctiongetCorrection (const int idx) const
 Returns a correction element object by its number.
std::string getCorrectionSchemaType () const
 Obtain a symbolic name for the correction element schema type.
int getFileIndex () const
 Returns the value of the file_index element.
std::string getFileIndexSchemaType () const
 Obtain a symbolic name for the file_index element schema type.
const ms_quant_isotopegetIsotope (const int idx) const
 Returns a isotope element object by its number.
std::string getIsotopeSchemaType () const
 Obtain a symbolic name for the isotope element schema type.
const ms_quant_modgroupgetModificationGroupByName (const char *name) const
 Returns a modification group object by its name or a null value in case it is not found.
const ms_quant_modgroupgetModificationGroupByNumber (const int idx) const
 Returns a modification group object by its number.
std::string getModificationGroupSchemaType () const
 Obtain a symbolic name for the modification_group element schema type.
const ms_quant_moverzgetMoverz () const
 Returns the value of the moverz element.
std::string getMoverzSchemaType () const
 Obtain a symbolic name for the moverz element schema type.
std::string getName () const
 Returns the value of the name attribute.
std::string getNameSchemaType () const
 Obtain a symbolic name for the name attribute schema type.
int getNumberOfCorrections () const
 Returns the number of correction elements held.
int getNumberOfIsotopes () const
 Returns the number of isotope elements held.
int getNumberOfModificationGroups () const
 Returns the number of nested modification groups.
const ms_quant_satellitegetSatellite () const
 Returns the value of the satellite element.
std::string getSatelliteSchemaType () const
 Obtain a symbolic name for the satellite element schema type.
virtual std::string getSchemaType () const
 Returns name of the schema type that can be used to validate this element.
bool haveFileIndex () const
 Check for presence of the file_index element.
bool haveMoverz () const
 Check for presence of the moverz element.
bool haveName () const
 Check for presence of the name attribute.
bool haveSatellite () const
 Check for presence of the satellite element.
ms_quant_componentoperator= (const ms_quant_component &right)
 C++ style assignment operator.
void setFileIndex (const int file_index)
 Supply a custom content for the file_index element.
void setMoverz (const ms_quant_moverz *moverz)
 Supply a custom content for the moverz element.
void setName (const char *value)
 Set a custom value for the name attribute.
void setSatellite (const ms_quant_satellite *satellite)
 Supply a custom content for the satellite element.
bool updateCorrection (const int idx, const ms_quant_correction *isotope)
 Update the information for a specific correction element.
bool updateIsotope (const int idx, const ms_quant_isotope *isotope)
 Update the information for a specific isotope element.
bool updateModificationGroupByName (const char *name, const ms_quant_modgroup *modgroup)
 Update the information for a specific modification group refering to it by its unique name.
bool updateModificationGroupByNumber (const int idx, const ms_quant_modgroup *modgroup)
 Update the information for a specific modification group refering to it by its index.
virtual std::string validateDeep (const ms_xml_schema *pSchemaFileObj) const
 Performs validation of all child elements in addition to 'shallow' validation.
virtual std::string validateShallow (const ms_xml_schema *pSchemaFileObj) const
 Performs simple validation of the top-level elements only.

Detailed Description

An object of this class represent a single component element in quantitation.xml.

Identifies a component used to calculate a ratio.


Constructor & Destructor Documentation

Default constructor.

Assigns reasonable default values to all internal members.

Copying constructor.

Parameters:
srcanother instance of this class to copy the content from.

Member Function Documentation

void appendCorrection ( const ms_quant_correction correction )

Adds a new correction element at the end of the list.

Parameters:
correctionan instance to copy the content into the newly added element from.
void appendIsotope ( const ms_quant_isotope isotope )

Adds a new isotope element at the end of the list.

Parameters:
isotopean instance to copy the content into the newly added element from.
void appendModificationGroup ( const ms_quant_modgroup item )

Adds a new modification group at the end of the list.

Creates a new modification group object, copies all content from the object supplied as a parameter and adds it at the end of the methods list.

Parameters:
iteman instance of modification group object to copy content from.
void clearCorrections (  )

Deletes all correction elements from the list.

Deletes all nested correction elements.

void copyFrom ( const ms_quant_component right )

Copies all content from another instance.

Parameters:
rightanother instance of this class to copy the content from.
void defaultValues (  )

Call this member if you want to start again.

All internal values are reset to their defaults, as if the object had been freshly created with the default constructor.

bool deleteCorrection ( const int  idx )

Remove a correction element from the list.

Parameters:
idxa zero-based index of the element to delete.
Returns:
TRUE if the element has been successfully deleted and FALSE otherwise.
bool deleteIsotope ( const int  idx )

Remove a isotope element from the list.

Parameters:
idxa zero-based index of the element to delete.
Returns:
TRUE if the element has been successfully deleted and FALSE otherwise.
bool deleteModificationGroupByName ( const char *  name )

Remove a modification group from the list in memory by its unique name.

Parameters:
namename of the modification group for deletion.
Returns:
TRUE if the modification group has been found and successfully deleted and FALSE otherwise.
bool deleteModificationGroupByNumber ( const int  idx )

Remove a modification group from the list in memory by its index.

Parameters:
idxnumber of the modification group for deletion from 0 to (getNumberOfModificationGroups() - 1).
Returns:
TRUE if the modification group has been found and successfully deleted and FALSE otherwise.
void dropFileIndex (  )

Delete the file_index element.

Deletes the element until it is re-set.

void dropMoverz (  )

Delete the moverz element.

Deletes the element until it is re-set.

void dropName (  )

Delete the name attribute.

Deletes the attribute until it is re-set.

void dropSatellite (  )

Delete the satellite element.

Deletes the element until it is re-set.

const ms_quant_correction * getCorrection ( const int  idx ) const

Returns a correction element object by its number.

Parameters:
idxa zero-based index of the element to retrieve.
Returns:
a read-only pointer to the retrieved element. See Maintaining object references: two rules of thumb.
std::string getCorrectionSchemaType (  ) const

Obtain a symbolic name for the correction element schema type.

The obtained type name can be used to get a corresponding type description object from ms_xml_schema.

Returns:
symbolic type name for the element.
int getFileIndex (  ) const

Returns the value of the file_index element.

The file_index element is a data file identifier (replicate).

Returns:
current element content.
std::string getFileIndexSchemaType (  ) const

Obtain a symbolic name for the file_index element schema type.

The obtained type name can be used to get a corresponding type description object from ms_xml_schema.

Returns:
symbolic type name for the element.
const ms_quant_isotope * getIsotope ( const int  idx ) const

Returns a isotope element object by its number.

Element for non-SILAC metabolic labelling. Applies to residues only.

Parameters:
idxa zero-based index of the element to retrieve.
Returns:
a read-only pointer to the retrieved element. See Maintaining object references: two rules of thumb.
std::string getIsotopeSchemaType (  ) const

Obtain a symbolic name for the isotope element schema type.

The obtained type name can be used to get a corresponding type description object from ms_xml_schema.

Returns:
symbolic type name for the element.
const ms_quant_modgroup * getModificationGroupByName ( const char *  name ) const

Returns a modification group object by its name or a null value in case it is not found.

Parameters:
namename of the modification group to find.
Returns:
a read-only pointer to a modification group object. See Maintaining object references: two rules of thumb.
const ms_quant_modgroup * getModificationGroupByNumber ( const int  idx ) const

Returns a modification group object by its number.

Parameters:
idxnumber of the modification group from 0 to (getNumberOfModificationGroups() - 1).
Returns:
a read-only pointer to a modification group object. See Maintaining object references: two rules of thumb.
std::string getModificationGroupSchemaType (  ) const

Obtain a symbolic name for the modification_group element schema type.

The obtained type name can be used to get a corresponding type description object from ms_xml_schema.

Returns:
symbolic type name for the element.
const ms_quant_moverz * getMoverz (  ) const

Returns the value of the moverz element.

Returns:
a read-only pointer to an object with the current element content. See Maintaining object references: two rules of thumb.
std::string getMoverzSchemaType (  ) const

Obtain a symbolic name for the moverz element schema type.

The obtained type name can be used to get a corresponding type description object from ms_xml_schema.

Returns:
symbolic type name for the element.
std::string getName (  ) const

Returns the value of the name attribute.

Returns:
a descriptive name that will appear in drop down lists, etc.
std::string getNameSchemaType (  ) const

Obtain a symbolic name for the name attribute schema type.

The obtained type name can be used to get a corresponding type description object from ms_xml_schema.

Returns:
symbolic type name for the element.
int getNumberOfCorrections (  ) const

Returns the number of correction elements held.

Returns:
total number of correction elements held.
int getNumberOfIsotopes (  ) const

Returns the number of isotope elements held.

Returns:
total number of isotope elements held.
int getNumberOfModificationGroups (  ) const

Returns the number of nested modification groups.

Returns:
total number of nested modification groups.
const ms_quant_satellite * getSatellite (  ) const

Returns the value of the satellite element.

Returns:
a read-only pointer to an object with the current element content. See Maintaining object references: two rules of thumb.
std::string getSatelliteSchemaType (  ) const

Obtain a symbolic name for the satellite element schema type.

The obtained type name can be used to get a corresponding type description object from ms_xml_schema.

Returns:
symbolic type name for the element.
std::string getSchemaType (  ) const [virtual]

Returns name of the schema type that can be used to validate this element.

Additional information about the current object can be retrieved from the associated XML schema file. Every element in an XML document is defined with a named type, which you can use to find out what kind of limits (numerical or otherwise) are defined for values of that type.

See also:
validateShallow(), validateDeep()
Returns:
a symbolic fully qualified type name (for example, "umod:nameType")
bool haveFileIndex (  ) const

Check for presence of the file_index element.

Returns:
TRUE if the element is present and FALSE otherwise.
bool haveMoverz (  ) const

Check for presence of the moverz element.

Returns:
TRUE if the element is present and FALSE otherwise.
bool haveName (  ) const

Check for presence of the name attribute.

Returns:
TRUE if the attribute is present and FALSE otherwise.
bool haveSatellite (  ) const

Check for presence of the satellite element.

Returns:
TRUE if the element is present and FALSE otherwise.
ms_quant_component & operator= ( const ms_quant_component right )

C++ style assignment operator.

Parameters:
rightanother instance of this class to copy the content from.
Returns:
reference to the current object
void setFileIndex ( const int  file_index )

Supply a custom content for the file_index element.

Parameters:
file_indexa new content for the element.
void setMoverz ( const ms_quant_moverz moverz )

Supply a custom content for the moverz element.

Parameters:
moverza new content for the element.
void setName ( const char *  value )

Set a custom value for the name attribute.

Parameters:
valuea new value for the attribute.
void setSatellite ( const ms_quant_satellite satellite )

Supply a custom content for the satellite element.

Parameters:
satellitea new content for the element.
bool updateCorrection ( const int  idx,
const ms_quant_correction correction 
)

Update the information for a specific correction element.

Parameters:
idxa zero-based index of the element to update.
correctionan instance to copy the content from.
Returns:
TRUE if the element has been successfully updated and FALSE otherwise.
bool updateIsotope ( const int  idx,
const ms_quant_isotope isotope 
)

Update the information for a specific isotope element.

Parameters:
idxa zero-based index of the element to update.
isotopean instance to copy the content from.
Returns:
TRUE if the element has been successfully updated and FALSE otherwise.
bool updateModificationGroupByName ( const char *  name,
const ms_quant_modgroup modgroup 
)

Update the information for a specific modification group refering to it by its unique name.

Parameters:
namename of the modification group for updating.
modgroupan object to copy the content from.
Returns:
TRUE if the modification group has been found and successfully updated and FALSE otherwise.
bool updateModificationGroupByNumber ( const int  idx,
const ms_quant_modgroup modgroup 
)

Update the information for a specific modification group refering to it by its index.

Parameters:
idxnumber of the modification group for updating from 0 to (getNumberOfModificationGroups() - 1).
modgroupan object to copy the content from.
Returns:
TRUE if the modification group has been found and successfully updated and FALSE otherwise.
std::string validateDeep ( const ms_xml_schema *  pSchemaFileObj ) const [virtual]

Performs validation of all child elements in addition to 'shallow' validation.

The current object can be checked against an XML schema. When using this method all possible checks are performed. However, this is not a substitute for the schema: some schema-defined constraint are not applied (unique fields, foreign keys etc.).

In order to make sure that current object is free from all syntax errors validate it as a part of the whole document.

See also:
validateShallow(), getSchemaType()
Parameters:
pSchemaFileObja valid schema object instance to validate against.
Returns:
user-friendly description of any errors found during validation or an empty string if no errors detected.
std::string validateShallow ( const ms_xml_schema *  pSchemaFileObj ) const [virtual]

Performs simple validation of the top-level elements only.

The current object can be checked against some basic constraints in a schema without looking at children element types. When using this method only the current object and children derived from standard types (for example, restrictions with enumerations) are checked. For more thorough validation, use validateDeep().

See also:
getSchemaType()
Parameters:
pSchemaFileObja valid schema object instance to validate against.
Returns:
user-friendly description of any errors found during validation or an empty string if no errors detected.

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

Copyright © 2022 Matrix Science Ltd.  All Rights Reserved. Generated on Thu Mar 31 2022 01:12:36