libdrmconf  0.11.3
A library to program DMR radios.
Public Member Functions | Protected Member Functions | List of all members
ChannelRefList Class Reference

Represents a list of weak references to channels (analog and digital). More...

#include <configreference.hh>

Inheritance diagram for ChannelRefList:
Inheritance graph
[legend]
Collaboration diagram for ChannelRefList:
Collaboration graph
[legend]

Public Member Functions

 ChannelRefList (QObject *parent=nullptr)
 Empty constructor.
 
- Public Member Functions inherited from ConfigObjectRefList
bool label (ConfigItem::Context &context, const ErrorStack &err=ErrorStack())
 Recursively labels the config object.
 
YAML::Node serialize (const ConfigItem::Context &context, const ErrorStack &err=ErrorStack())
 Recursively serializes the configuration to YAML nodes. More...
 
virtual int compare (const ConfigObjectRefList &other) const
 Compares the object ref lists. More...
 
- Public Member Functions inherited from AbstractConfigObjectList
virtual bool copy (const AbstractConfigObjectList &other)
 Copies all elements from other to this list.
 
virtual int count () const
 Returns the number of elements in the list.
 
virtual int indexOf (ConfigObject *obj) const
 Returns the index of the given object within the list.
 
virtual void clear ()
 Clears the list.
 
virtual const Configconfig () const
 Returns the config object, this list belongs to.
 
virtual void findItemsOfTypes (const QStringList &typeNames, QSet< ConfigItem * > &items) const
 Searches the config tree to find all instances of the given type names.
 
virtual bool has (ConfigObject *obj) const
 Returns true, if the list contains the given object.
 
virtual ConfigObjectget (int idx) const
 Returns the list element at the given index or nullptr if out of bounds.
 
virtual int add (ConfigObject *obj, int row=-1)
 Adds an element to the list.
 
virtual bool take (ConfigObject *obj)
 Removes an element from the list.
 
virtual bool del (ConfigObject *obj)
 Removes an element from the list (and deletes it if owned).
 
virtual bool moveUp (int idx)
 Moves the channel at index idx one step up.
 
virtual bool moveUp (int first, int last)
 Moves the channels at one step up.
 
virtual bool moveDown (int idx)
 Moves the channel at index idx one step down.
 
virtual bool moveDown (int first, int last)
 Moves the channels one step down.
 
const QList< QMetaObject > & elementTypes () const
 Returns the element type for this list.
 
QStringList classNames () const
 Returns a list of all class names.
 

Protected Member Functions

 ChannelRefList (const QMetaObject &elementTypes, QObject *parent=nullptr)
 Hidden constructor.
 
- Protected Member Functions inherited from ConfigObjectRefList
 ConfigObjectRefList (const QMetaObject &elementTypes=ConfigObject::staticMetaObject, QObject *parent=nullptr)
 Hidden constructor.
 
 ConfigObjectRefList (const std::initializer_list< QMetaObject > &elementTypes, QObject *parent=nullptr)
 Hidden constructor from initializer list.
 
- Protected Member Functions inherited from AbstractConfigObjectList
 AbstractConfigObjectList (const QMetaObject &elementTypes=ConfigObject::staticMetaObject, QObject *parent=nullptr)
 Hidden constructor.
 
 AbstractConfigObjectList (const std::initializer_list< QMetaObject > &elementTypes, QObject *parent=nullptr)
 Hidden constructor from initializer list.
 

Additional Inherited Members

- Signals inherited from AbstractConfigObjectList
void elementAdded (int idx)
 Gets emitted if an element was added to the list.
 
void elementModified (int idx)
 Gets emitted if one of the lists elements gets modified.
 
void elementRemoved (int idx)
 Gets emitted if one of the lists elements gets deleted.
 
- Protected Attributes inherited from AbstractConfigObjectList
QList< QMetaObject > _elementTypes
 Holds the static QMetaObject of the element type.
 
QVector< ConfigObject * > _items
 Holds the list items.
 

Detailed Description

Represents a list of weak references to channels (analog and digital).


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