|
gphoto2pp
A C++ Wrapper for libgphoto2
|
#include <camera_widget_wrapper.hpp>

Public Member Functions | |
| virtual | ~CameraWidgetWrapper () |
| CameraWidgetWrapper (CameraWidgetWrapper &&other) | |
| CameraWidgetWrapper & | operator= (CameraWidgetWrapper &&other) |
| CameraWidgetWrapper (CameraWidgetWrapper const &other) | |
| CameraWidgetWrapper & | operator= (CameraWidgetWrapper const &other) |
| gphoto2::_CameraWidget * | getPtr () const |
| Gets the raw resource RAII indicates we still should allow our users access to the RAW Resource and it is applicable. | |
| std::string | getName () const |
| Gets the widget's name. | |
| CameraWidgetTypeWrapper | getType () const |
| Gets the widget's type. | |
| std::string | getLabel () const |
| Gets the widget's label. | |
| std::string | getInfo () const |
| Gets the widget's info. | |
| int | getId () const |
| Gets the widget's unique id. | |
| CameraWidgetWrapper | getRoot () const |
| Gets the widget's Root. This is likely going to be the Window Widget (same widget from ICameraWrapper::getConfig()). | |
| CameraWidgetWrapper | getParent () const |
| Gets the widget's parent. This is the immediate parent of the widget. If the current widget is a leaf node, then this is likely a Section Widget, but could also be a Window Widget. | |
Protected Member Functions | |
| CameraWidgetWrapper (gphoto2::_CameraWidget *cameraWidget) | |
| void | ref () |
| Adds a reference count to the internal gphoto2::CameraWidget struct. | |
| void | unref () |
| Subtracts a reference count to the internal gphoto2::CameraWidget struct. | |
| gphoto2::_CameraWidget * | getRootDefault () const |
| Gets the unwrapped CameraWidget struct pointer of the root. | |
| gphoto2::_CameraWidget * | getParentDefault () const |
| Gets the unwrapped CameraWidget struct pointer of the parent. | |
Protected Attributes | |
| gphoto2::_CameraWidget * | m_cameraWidget = nullptr |
This class provides a RAII wrapper around the gphoto2 CameraWidget struct. In the gphoto2 the camera's abilities are represented by an N-ary tree.
Gphoto2 has 9 node types. 7 of them compose the leaf nodes of the tree and contian read, or read/write values. 2 of them (window and section) are non value widgets, and represent the internal nodes with 1 or more children.
Every camera abilities tree has Only 1 root node, which is always of type Window. Then this can have n children, typically they are Section widgets.
Please review the above graphical tree to look at the inheritance hierarchy of the widget types to understand the underlying value they each represent.
| Type | Value | Node Type |
|---|---|---|
| Window | N/A | Root |
| Section | N/A | Non Leaf |
| Text | string | Leaf |
| Range | float | Leaf |
| Toggle | int | Leaf |
| Radio | string | Leaf |
| Menu | string | Leaf |
| Button | N/A | Leaf |
| Date | time_t | Leaf |
|
virtual |
| gphoto2pp::CameraWidgetWrapper::CameraWidgetWrapper | ( | CameraWidgetWrapper && | other | ) |
| gphoto2pp::CameraWidgetWrapper::CameraWidgetWrapper | ( | CameraWidgetWrapper const & | other | ) |
|
protected |
| int gphoto2pp::CameraWidgetWrapper::getId | ( | ) | const |
Gets the widget's unique id.
| GPhoto2pp::exceptions::gphoto2_exception |
| std::string gphoto2pp::CameraWidgetWrapper::getInfo | ( | ) | const |
Gets the widget's info.
| GPhoto2pp::exceptions::gphoto2_exception |
| std::string gphoto2pp::CameraWidgetWrapper::getLabel | ( | ) | const |
Gets the widget's label.
| GPhoto2pp::exceptions::gphoto2_exception |
| std::string gphoto2pp::CameraWidgetWrapper::getName | ( | ) | const |
Gets the widget's name.
| GPhoto2pp::exceptions::gphoto2_exception |
| CameraWidgetWrapper gphoto2pp::CameraWidgetWrapper::getParent | ( | ) | const |
Gets the widget's parent. This is the immediate parent of the widget. If the current widget is a leaf node, then this is likely a Section Widget, but could also be a Window Widget.
| GPhoto2pp::exceptions::gphoto2_exception |
|
protected |
Gets the unwrapped CameraWidget struct pointer of the parent.
| GPhoto2pp::exceptions::gphoto2_exception |
| gphoto2::_CameraWidget* gphoto2pp::CameraWidgetWrapper::getPtr | ( | ) | const |
Gets the raw resource RAII indicates we still should allow our users access to the RAW Resource and it is applicable.
| CameraWidgetWrapper gphoto2pp::CameraWidgetWrapper::getRoot | ( | ) | const |
Gets the widget's Root. This is likely going to be the Window Widget (same widget from ICameraWrapper::getConfig()).
| GPhoto2pp::exceptions::gphoto2_exception |
|
protected |
Gets the unwrapped CameraWidget struct pointer of the root.
| GPhoto2pp::exceptions::gphoto2_exception |
| CameraWidgetTypeWrapper gphoto2pp::CameraWidgetWrapper::getType | ( | ) | const |
Gets the widget's type.
| GPhoto2pp::exceptions::gphoto2_exception |
| CameraWidgetWrapper& gphoto2pp::CameraWidgetWrapper::operator= | ( | CameraWidgetWrapper && | other | ) |
| CameraWidgetWrapper& gphoto2pp::CameraWidgetWrapper::operator= | ( | CameraWidgetWrapper const & | other | ) |
|
protected |
Adds a reference count to the internal gphoto2::CameraWidget struct.
| GPhoto2pp::exceptions::gphoto2_exception |
|
protected |
Subtracts a reference count to the internal gphoto2::CameraWidget struct.
| GPhoto2pp::exceptions::gphoto2_exception |
|
protected |