INTRODUCTION
Overview
Download and Install
Quick Start
Documentation
Publications

NONFRAMEWORK CODE
Driver Interfaces
Drivers
Libraries
Utilities

FRAMEWORK CODE
Interfaces
Components
Libraries
Utilities

Full Software Listings

DEVELOPER
Tutorials
Examples
Dev Guide
Dashboard

PEOPLE
Contributors
Users

SourceForge.net Logo
Project
Download
Mailing lists

 

         

orcaqcm::OcmModel Class Reference

#include <ocmmodel.h>

List of all members.

Public Slots

void clear ()
 Delete all data from the model.

Public Member Functions

virtual void customEvent (QEvent *e)
 Processes events sent to us by the GetComponentsJob.
QModelIndex registryIndex (const QString &registry, bool create=false)
 Find registry node by its name. If not found and create=TRUE, create a new one.
QModelIndex platformIndex (const QString &registry, const QString &platform, bool create=false)
QModelIndex componentIndex (const QString &registry, const QString &platform, const QString &component, bool create=false)
QModelIndex interfaceIndex (const QString &registry, const QString &platform, const QString &component, const QString &interface, bool create=false)
QModelIndex operationIndex (const QString &registry, const QString &platform, const QString &component, const QString &interface, const QString &operation, bool create=false)
QModelIndex resultIndex (const QString &registry, const QString &platform, const QString &component, const QString &interface, const QString &operation, const QString &result, bool create=false)
void setRegistry (const QString &registry, const QString &regAddress, bool connected)
 Set info for a registry node.
void setPlatform (const QString &registry, const QString &platform)
 Set info for a platform node.
void setComponent (const QString &registry, const QString &platform, const QString &component, const QString &compAddress, bool connected)
 Set info for a component node.
void setInterface (const QString &registry, const QString &platform, const QString &component, const QString &interface, const bool isProvided, const QString &ids, bool isEnabled)
 Set info for a interface node.
void setOperation (const QString &registry, const QString &platform, const QString &component, const QString &interface, const QString &operation, const QString &signature)
 Set info for a operation node.
void setResult (const QString &registry, const QString &platform, const QString &component, const QString &interface, const QString &operation, const QString &result, const QString &text)
 Set info for a result node.
int interfaceData (const QModelIndex &ind, QString &registry, QString &platform, QString &component, QString &interface, QString &id)
int interfacesOnPlatform (const QModelIndex &ind, QStringList &registries, QStringList &platforms, QStringList &components, QStringList &interfaces, QStringList &ids)
int interfacesOnComponent (const QModelIndex &ind, QStringList &registries, QStringList &platforms, QStringList &components, QStringList &interfaces, QStringList &ids)
 As above but for interfaces of a component.

Detailed Description

A model (as in model-view-controller) holding information about the Orca component model (i.e. a hierarchy of platforms, components, interfaces).

Determines the paint style of individual entries in the model based on data.

See also:
OcmView, OcmDelegate

Member Function Documentation

QModelIndex orcaqcm::OcmModel::componentIndex ( const QString &  registry,
const QString &  platform,
const QString &  component,
bool  create = false 
)

Find component node by its name, and the names of its parents. If not found and create=TRUE, create a new one.

References platformIndex().

Referenced by interfaceIndex(), and setComponent().

int orcaqcm::OcmModel::interfaceData ( const QModelIndex &  ind,
QString &  registry,
QString &  platform,
QString &  component,
QString &  interface,
QString &  id 
)

Custom function for getting information about an interface. Returns 0 if the data was retrieved properly or 1 if something went wrong, e.g. the index does not point to an InterfaceType.

QModelIndex orcaqcm::OcmModel::interfaceIndex ( const QString &  registry,
const QString &  platform,
const QString &  component,
const QString &  interface,
bool  create = false 
)

Find interface node by its name, and the names of its parents. If not found and create=TRUE, create a new one.

References componentIndex().

Referenced by operationIndex(), and setInterface().

int orcaqcm::OcmModel::interfacesOnPlatform ( const QModelIndex &  ind,
QStringList &  registries,
QStringList &  platforms,
QStringList &  components,
QStringList &  interfaces,
QStringList &  ids 
)

Custom function for getting information about interfaces on a platform. Returns 0 if the data was retrieved properly or 1 if something went wrong, e.g. the index does not point to a PlatformType.

QModelIndex orcaqcm::OcmModel::operationIndex ( const QString &  registry,
const QString &  platform,
const QString &  component,
const QString &  interface,
const QString &  operation,
bool  create = false 
)

Find operation node by its name, and the names of its parents. If not found and create=TRUE, create a new one.

References interfaceIndex().

Referenced by resultIndex(), and setOperation().

QModelIndex orcaqcm::OcmModel::platformIndex ( const QString &  registry,
const QString &  platform,
bool  create = false 
)

Find platform node by its name and the name of its registry. If not found and create=TRUE, create a new one.

References registryIndex().

Referenced by componentIndex(), and setPlatform().

QModelIndex orcaqcm::OcmModel::resultIndex ( const QString &  registry,
const QString &  platform,
const QString &  component,
const QString &  interface,
const QString &  operation,
const QString &  result,
bool  create = false 
)

Find result node by its name, and the names of its parents. If not found and create=TRUE, create a new one.

References operationIndex().

Referenced by setResult().


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

Webmaster: Tobias Kaupp (tobasco at users.sourceforge.net)


Generated for Orca Robotics by  doxygen 1.4.5