![]() |
![]() |
CEnumParameter class used to simplify access to GenApi parameters. More...
#include <pylon/EnumParameter.h>
Public Member Functions | |
CEnumParameter () | |
Creates an empty CEnumParameter object. More... | |
CEnumParameter (GenApi::INode *pNode) | |
Creates a CEnumParameter object and attaches it to a node, typically retrieved for a nodemap calling GetNode(). More... | |
CEnumParameter (GenApi::IEnumeration *pEnumeration) | |
Creates a CEnumParameter object and attaches it to a node of a matching type. More... | |
CEnumParameter (GenApi::INodeMap *pNodeMap, const char *pName) | |
Creates a CEnumParameter object and attaches it to a node retrieved from the provided node map. More... | |
CEnumParameter (GenApi::INodeMap &nodeMap, const char *pName) | |
Creates a CEnumParameter object and attaches it to a node retrieved from the provided node map. More... | |
CEnumParameter (const CEnumParameter &rhs) | |
Copies a CEnumParameter object. More... | |
virtual | ~CEnumParameter () |
Destroys the CEnumParameter object. More... | |
virtual bool | Attach (GenApi::INodeMap *pNodeMap, const char *pName) |
Attaches a node retrieved from the provided node map. More... | |
virtual bool | Attach (GenApi::INodeMap &nodeMap, const char *pName) |
Attaches a node retrieved from the provided node map. More... | |
virtual bool | Attach (GenApi::INode *pNode) |
Attaches a node, typically retrieved for a nodemap calling GetNode(). More... | |
virtual bool | Attach (GenApi::IEnumeration *pEnumeration) |
Assigns a node of the same type to the parameter object. More... | |
CEnumParameter & | operator= (const CEnumParameter &rhs) |
Assigns a CEnumParameter object. More... | |
virtual bool | Equals (const CEnumParameter &rhs) const |
Returns true if the same nodes are attached or both parameters are empty. More... | |
virtual bool | Equals (const GenApi::INode *pNode) const |
Returns true if the attached node pointer is equal. More... | |
virtual bool | Equals (const GenApi::IEnumeration *pEnumeration) const |
Returns true if the attached node pointer is equal. More... | |
virtual void | Release () |
Releases the attached node. More... | |
virtual bool | IsValid () const |
Indicates whether a node is attached. More... | |
virtual void | GetSymbolics (GenApi::StringList_t &symbolics) |
Get list of symbolic Values. | |
virtual void | GetEntries (GenApi::NodeList_t &entries) |
Get list of entry nodes. | |
virtual GenApi::IEnumeration & | operator= (const GenICam::gcstring &valueStr) |
Set string node value. | |
virtual void | SetIntValue (int64_t value, bool verify=true) |
Set integer node value. More... | |
virtual GenICam::gcstring | operator* () |
Get string node value. | |
virtual int64_t | GetIntValue (bool verify=false, bool ignoreCache=false) |
Get integer node value. More... | |
virtual GenApi::IEnumEntry * | GetEntryByName (const GenICam::gcstring &symbolic) |
Get an entry node by name. | |
virtual GenApi::IEnumEntry * | GetEntry (const int64_t intValue) |
Get an entry node by its IntValue. | |
virtual GenApi::IEnumEntry * | GetCurrentEntry (bool verify=false, bool ignoreCache=false) |
Get the current entry. | |
virtual String_t | GetValueOrDefault (const String_t &defaultValue) |
Gets the value of the parameter if the parameter is readable. More... | |
virtual bool | TrySetValue (const String_t &value) |
Sets the value of the parameter if the parameter is writable and the value is contained in the set of settable enumeration values. More... | |
virtual void | SetValue (const char **nullTerminatedList) |
Sets the value of the parameter to the first valid value in a list of values. More... | |
virtual bool | TrySetValue (const char **nullTerminatedList) |
If the parameter is writable, sets the value of the parameter to the first valid value in a list of values. More... | |
virtual bool | CanSetValue (const String_t &value) |
Indicates whether the given value can be set. More... | |
virtual void | SetValue (const String_t &value) |
Sets the value of the parameter. More... | |
virtual String_t | GetValue () |
Gets the value of the parameter. More... | |
virtual void | GetSettableValues (GenApi::StringList_t &values) |
Gets a list of all values of the enumeration that are currently settable. More... | |
virtual void | GetAllValues (GenApi::StringList_t &values) |
Gets a list of all values of the enumeration including the values that are currently not settable. More... | |
virtual CParameter | GetEntryByNameAsParameter (const GenICam::gcstring &value) |
Gets an enumeration entry by its symbolic name. More... | |
virtual CParameter | GetCurrentEntryAsParameter () |
Gets the currently selected entry of an enumeration. More... | |
virtual INode * | GetNode () |
Get the INode interface of the node. | |
virtual GenICam::gcstring | ToString (bool Verify=false, bool IgnoreCache=false)=0 |
Get content of the node as string. More... | |
virtual void | FromString (const GenICam::gcstring &ValueStr, bool Verify=true)=0 |
Set content of the node as string. More... | |
virtual bool | IsValueCacheValid () const =0 |
Checks if the value comes from cache or is requested from another node. | |
virtual EAccessMode | GetAccessMode () const =0 |
Get the access mode of the node. | |
virtual bool | IsReadable () const =0 |
Indicates whether the parameter is readable. More... | |
virtual bool | IsWritable () const =0 |
Indicates whether the parameter is writable. More... | |
virtual String_t | GetInfo (EParameterInfo info)=0 |
Gets the parameter information. More... | |
virtual String_t | GetInfoOrDefault (EParameterInfo info, const String_t defaultInfo)=0 |
Gets the parameter information if the parameter is attached to a node. More... | |
virtual String_t | ToStringOrDefault (const String_t &defaultValue)=0 |
Gets the parameter value as string if the parameter is readable. More... | |
virtual bool | Attach (GenApi::IValue *pValue) |
Assigns a node of the same type to the parameter object. More... | |
virtual bool | Equals (const CParameter &rhs) const |
Returns true if the same nodes are attached or both parameters are empty. More... | |
virtual bool | Equals (const GenApi::IValue *pValue) const |
Returns true if the attached node pointer is equal. More... | |
virtual GenApi::EAccessMode | GetAccessMode () const |
Get the access mode of the node. | |
virtual GenApi::INode * | GetNode () |
Get the INode interface of the node. | |
virtual GenICam::gcstring | ToString (bool verify=false, bool ignoreCache=false) |
Get content of the node as string. More... | |
virtual void | FromString (const GenICam::gcstring &valueStr, bool verify=true) |
Set content of the node as string. More... | |
virtual bool | IsValueCacheValid () const |
Checks if the value comes from cache or is requested from another node. | |
virtual bool | IsReadable () const |
Indicates whether the parameter is readable. More... | |
virtual bool | IsWritable () const |
Indicates whether the parameter is writable. More... | |
virtual String_t | GetInfo (EParameterInfo info) |
Gets the parameter information. More... | |
virtual String_t | GetInfoOrDefault (EParameterInfo info, const String_t defaultInfo) |
Gets the parameter information if the parameter is attached to a node. More... | |
virtual String_t | ToStringOrDefault (const String_t &defaultValue) |
Gets the parameter value as string if the parameter is readable. More... | |
CEnumParameter class used to simplify access to GenApi parameters.
Pylon::CEnumParameter::CEnumParameter | ( | ) |
Creates an empty CEnumParameter object.
|
explicit |
Creates a CEnumParameter object and attaches it to a node, typically retrieved for a nodemap calling GetNode().
[in] | pNode | The node to attach. |
pNode
has been destroyed. In this case, call Release() or attach a new node.
|
explicit |
Creates a CEnumParameter object and attaches it to a node of a matching type.
[in] | pEnumeration | The node to attach. |
pEnumeration
has been destroyed. In this case, call Release() or attach a new node. Pylon::CEnumParameter::CEnumParameter | ( | GenApi::INodeMap * | pNodeMap, |
const char * | pName | ||
) |
Creates a CEnumParameter object and attaches it to a node retrieved from the provided node map.
[in] | pNodeMap | The node map. The source of the parameter. |
[in] | pName | The name of the parameter to attach. |
pNodeMap
or name
is NULL, the parameter will be empty, see IsValid(). Pylon::CEnumParameter::CEnumParameter | ( | GenApi::INodeMap & | nodeMap, |
const char * | pName | ||
) |
Creates a CEnumParameter object and attaches it to a node retrieved from the provided node map.
[in] | nodeMap | The node map. The source of the parameter. |
[in] | pName | The name of the parameter to attach. |
name
is NULL, the parameter will be empty, see IsValid(). Pylon::CEnumParameter::CEnumParameter | ( | const CEnumParameter & | rhs | ) |
Copies a CEnumParameter object.
[in] | rhs | The object to copy. |
|
virtual |
Destroys the CEnumParameter object.
Does not access the attached node.
|
virtualinherited |
Assigns a node of the same type to the parameter object.
[in] | pValue | The node to assign. |
|
virtual |
Attaches a node retrieved from the provided node map.
[in] | pNodeMap | The node map. The source of the parameter. |
[in] | pName | The name of the parameter to attach. |
pNodeMap
or name
is NULL, the parameter will be empty, see IsValid(). Reimplemented from Pylon::CParameter.
|
virtual |
Attaches a node retrieved from the provided node map.
[in] | nodeMap | The node map. The source of the parameter. |
[in] | pName | The name of the parameter to attach. |
name
is NULL the parameter will be empty, see IsValid(). Reimplemented from Pylon::CParameter.
|
virtual |
Attaches a node, typically retrieved for a nodemap calling GetNode().
[in] | pNode | The node to assign. |
pNode
has been destroyed. In this case, call Release() or attach a new node. Reimplemented from Pylon::CParameter.
|
virtual |
Assigns a node of the same type to the parameter object.
[in] | pEnumeration | The node to assign. |
|
virtual |
Indicates whether the given value can be set.
[in] | value | The value to be checked. |
Implements Pylon::IEnumerationEx.
|
virtualinherited |
Returns true if the same nodes are attached or both parameters are empty.
[in] | rhs | The object to compare to. |
|
virtualinherited |
Returns true if the attached node pointer is equal.
[in] | pValue | The node to compare to. |
|
virtual |
Returns true if the same nodes are attached or both parameters are empty.
[in] | rhs | The object to compare to. |
|
virtual |
Returns true if the attached node pointer is equal.
[in] | pNode | The node to compare to. |
Reimplemented from Pylon::CParameter.
|
virtual |
Returns true if the attached node pointer is equal.
[in] | pEnumeration | The node to compare to. |
|
pure virtualinherited |
Set content of the node as string.
ValueStr | The value to set |
Verify | Enables AccessMode and Range verification (default = true) |
Implemented in Pylon::CParameter.
|
virtualinherited |
Set content of the node as string.
ValueStr | The value to set |
Verify | Enables AccessMode and Range verification (default = true) |
Implements GenApi::IValue.
|
virtual |
Gets a list of all values of the enumeration including the values that are currently not settable.
[out] | values | Returns a list of all values of the enumeration including the values that are currently not settable. |
Implements Pylon::IEnumerationEx.
|
virtual |
Gets the currently selected entry of an enumeration.
The entry is returned as a CParameter. This method can be used to access information about the enumeration value represented by the entry using CParameter::GetInfo().
Implements Pylon::IEnumerationEx.
|
virtual |
Gets an enumeration entry by its symbolic name.
The entry is returned as a CParameter. This method can be used to access information about the enumeration value represented by the entry using CParameter::GetInfo().
[in] | value | The symbolic name of the enumeration entry, e.g., "Testimage1". |
Implements Pylon::IEnumerationEx.
|
pure virtualinherited |
Gets the parameter information.
[in] | info | The type information to return. |
Implemented in Pylon::CParameter.
|
virtualinherited |
Gets the parameter information.
[in] | info | The type information to return. |
Implements Pylon::IValueEx.
|
pure virtualinherited |
Gets the parameter information if the parameter is attached to a node.
See IsValid().
[in] | info | The type information to return. Otherwise returns the default information. This method is useful if you want to display parameter information and handle the case that some parameters are not available for a device. |
[in] | defaultInfo | The default information returned if the parameter is not attached to a node. |
Implemented in Pylon::CParameter.
|
virtualinherited |
Gets the parameter information if the parameter is attached to a node.
See IsValid().
[in] | info | The type information to return. Otherwise returns the default information. This method is useful if you want to display parameter information and handle the case that some parameters are not available for a device. |
[in] | defaultInfo | The default information returned if the parameter is not attached to a node. |
Implements Pylon::IValueEx.
|
virtual |
Get integer node value.
Verify | Enables Range verification (default = false). The AccessMode is always checked |
IgnoreCache | If true the value is read ignoring any caches (default = false) |
Implements GenApi::IEnumeration.
|
virtual |
Gets a list of all values of the enumeration that are currently settable.
[out] | values | Returns a list of all values of the enumeration that are currently settable. |
Implements Pylon::IEnumerationEx.
|
virtual |
Gets the value of the parameter.
Implements Pylon::IEnumerationEx.
Gets the value of the parameter if the parameter is readable.
Otherwise returns the default value.
[in] | defaultValue | The default value returned if the parameter is not readable. |
Implements Pylon::IEnumerationEx.
|
pure virtualinherited |
Indicates whether the parameter is readable.
Implemented in Pylon::CParameter.
|
virtualinherited |
Indicates whether the parameter is readable.
Implements Pylon::IValueEx.
|
virtual |
Indicates whether a node is attached.
Reimplemented from Pylon::CParameter.
|
pure virtualinherited |
Indicates whether the parameter is writable.
Implemented in Pylon::CParameter.
|
virtualinherited |
Indicates whether the parameter is writable.
Implements Pylon::IValueEx.
CEnumParameter& Pylon::CEnumParameter::operator= | ( | const CEnumParameter & | rhs | ) |
Assigns a CEnumParameter object.
[in] | rhs | The object to assign. |
|
virtual |
Releases the attached node.
Reimplemented from Pylon::CParameter.
|
virtual |
Set integer node value.
Value | The value to set |
Verify | Enables AccessMode and Range verification (default = true) |
Implements GenApi::IEnumeration.
|
virtual |
Sets the value of the parameter to the first valid value in a list of values.
Example:
[in] | nullTerminatedList | The list of possible values to set. The list is terminated by a NULL value. |
nullTerminatedList
is settable, or writing the value fails. Implements Pylon::IEnumerationEx.
|
virtual |
Sets the value of the parameter.
Calls FromString().
[in] | value | The value to set. |
Implements Pylon::IEnumerationEx.
|
pure virtualinherited |
Get content of the node as string.
Verify | Enables Range verification (default = false). The AccessMode is always checked |
IgnoreCache | If true the value is read ignoring any caches (default = false) |
Implemented in Pylon::CParameter.
|
virtualinherited |
Get content of the node as string.
Verify | Enables Range verification (default = false). The AccessMode is always checked |
IgnoreCache | If true the value is read ignoring any caches (default = false) |
Implements GenApi::IValue.
|
pure virtualinherited |
Gets the parameter value as string if the parameter is readable.
Otherwise returns the default value.
[in] | defaultValue | The default value returned if the parameter is not readable. |
Implemented in Pylon::CParameter.
|
virtualinherited |
Gets the parameter value as string if the parameter is readable.
Otherwise returns the default value.
[in] | defaultValue | The default value returned if the parameter is not readable. |
Implements Pylon::IValueEx.
|
virtual |
Sets the value of the parameter if the parameter is writable and the value is contained in the set of settable enumeration values.
[in] | value | The value to set. |
Implements Pylon::IEnumerationEx.
|
virtual |
If the parameter is writable, sets the value of the parameter to the first valid value in a list of values.
Example:
[in] | nullTerminatedList | The list of possible values to set. The list is terminated by a NULL value. |
nullTerminatedList
is settable, or writing the value fails. Implements Pylon::IEnumerationEx.