Pylon::CEnumParameter#
#include <pylon/EnumParameter.h>
Inherits from Pylon::IEnumerationEx, Pylon::CParameter, GenApi::IEnumeration, Pylon::IValueEx, GenApi::IValue, GenApi::IBase
Inherited by Pylon::CEnumParameterT< EnumT >
Public Classes#
| Name | |
|---|---|
| class | Table_t |
| class | TableItem_t |
Public Functions#
| Name | |
|---|---|
| CEnumParameter() Creates an empty CEnumParameter object. | |
| CEnumParameter(GenApi::INode * pNode) Creates a CEnumParameter object and attaches it to a node, typically retrieved for a nodemap calling GetNode(). | |
| CEnumParameter(GenApi::IEnumeration * pEnumeration) Creates a CEnumParameter object and attaches it to a node of a matching type. | |
| CEnumParameter(GenApi::INodeMap * pNodeMap, const char * pName) Creates a CEnumParameter object and attaches it to a node retrieved from the provided node map. | |
| CEnumParameter(GenApi::INodeMap & nodeMap, const char * pName) Creates a CEnumParameter object and attaches it to a node retrieved from the provided node map. | |
| CEnumParameter(const CEnumParameter & rhs) Copies a CEnumParameter object. | |
| virtual | ~CEnumParameter() Destroys the CEnumParameter object. |
| virtual bool | Attach(GenApi::INodeMap * pNodeMap, const char * pName) Attaches a node retrieved from the provided node map. |
| virtual bool | Attach(GenApi::INodeMap & nodeMap, const char * pName) Attaches a node retrieved from the provided node map. |
| virtual bool | Attach(GenApi::INode * pNode) Attaches a node, typically retrieved for a nodemap calling GetNode(). |
| virtual bool | Attach(GenApi::IEnumeration * pEnumeration) Assigns a node of the same type to the parameter object. |
| CEnumParameter & | operator=(const CEnumParameter & rhs) Assigns a CEnumParameter object. |
| virtual bool | Equals(const CEnumParameter & rhs) const Returns true if the same nodes are attached or both parameters are empty. |
| virtual bool | Equals(const GenApi::INode * pNode) const Returns true if the attached node pointer is equal. |
| virtual bool | Equals(const GenApi::IEnumeration * pEnumeration) const Returns true if the attached node pointer is equal. |
| virtual void | Release() Releases the attached node. |
| virtual bool | IsValid() const Indicates whether a node is attached. |
| 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. |
| virtual GenICam::gcstring | operator*() Get string node value. |
| virtual int64_t | GetIntValue(bool Verify =false, bool IgnoreCache =false) Get integer node value. |
| 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. |
| 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. |
| virtual void | SetValue(const char ** nullTerminatedList) Sets the value of the parameter to the first valid value in a list of values. |
| 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. |
| virtual bool | CanSetValue(const String_t & value) Indicates whether the given value can be set. |
| virtual void | SetValue(const String_t & value) Sets the value of the parameter. |
| virtual String_t | GetValue() Gets the value of the parameter. |
| virtual void | GetSettableValues(GenApi::StringList_t & values) Gets a list of all values of the enumeration that are currently settable. |
| virtual void | GetAllValues(GenApi::StringList_t & values) Gets a list of all values of the enumeration including the values that are currently not settable. |
| virtual CParameter | GetEntryByNameAsParameter(const GenICam::gcstring & value) Gets an enumeration entry by its symbolic name. |
| virtual CParameter | GetCurrentEntryAsParameter() Gets the currently selected entry of an enumeration. |
| virtual 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. |
| virtual void | FromString(const GenICam::gcstring & ValueStr, bool Verify =true) Set content of the node as string. |
| virtual bool | IsValueCacheValid() const Checks if the value comes from cache or is requested from another node. |
| virtual EAccessMode | GetAccessMode() const Get the access mode of the node. |
| virtual bool | IsReadable() const Indicates whether the parameter is readable. |
| virtual bool | IsWritable() const Indicates whether the parameter is writable. |
| virtual String_t | GetInfo(EParameterInfo info) Gets the parameter information. |
| virtual String_t | GetInfoOrDefault(EParameterInfo info, const String_t defaultInfo) Gets the parameter information if the parameter is attached to a node. |
| virtual String_t | ToStringOrDefault(const String_t & defaultValue) Gets the parameter value as string if the parameter is readable. |
| virtual bool | Attach(GenApi::IValue * pValue) Assigns a node of the same type to the parameter object. |
| virtual bool | Equals(const CParameter & rhs) const Returns true if the same nodes are attached or both parameters are empty. |
| virtual bool | Equals(const GenApi::IValue * pValue) const Returns true if the attached node pointer is equal. |
| 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. |
| virtual void | FromString(const GenICam::gcstring & ValueStr, bool Verify =true) Set content of the node as string. |
| 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. |
| virtual bool | IsWritable() const Indicates whether the parameter is writable. |
| virtual String_t | GetInfo(EParameterInfo info) Gets the parameter information. |
| virtual String_t | GetInfoOrDefault(EParameterInfo info, const String_t defaultInfo) Gets the parameter information if the parameter is attached to a node. |
| virtual String_t | ToStringOrDefault(const String_t & defaultValue) Gets the parameter value as string if the parameter is readable. |
Protected Functions#
| Name | |
|---|---|
| void | SetValue(const Table_t & table, size_t index, bool verify) |
| size_t | GetValue(const Table_t & table, bool verify, bool ignoreCache) |
| GenApi::IEnumEntry * | GetEntry(const Table_t & table, size_t index) |
| bool | CanSetValue(const Table_t & table, size_t index) |
Protected Attributes#
| Name | |
|---|---|
| GenApi::IEnumeration * | m_pFeature |
| GenApi::IValue * | m_pValue |
Additional inherited members#
Public Functions inherited from Pylon::CParameter
| Name | |
|---|---|
| CParameter() Creates an empty CParameter object. | |
| CParameter(GenApi::INode * pNode) Creates a CParameter object and attaches it to a node, typically retrieved for a nodemap calling GetNode(). | |
| CParameter(GenApi::IValue * pValue) Creates a CParameter object and attaches it to a node of a matching type. | |
| CParameter(GenApi::INodeMap * pNodeMap, const char * pName) Creates a CParameter object and attaches it to a node retrieved from the provided node map. | |
| CParameter(GenApi::INodeMap & nodeMap, const char * pName) Creates a CParameter object and attaches it to a node retrieved from the provided node map. | |
| CParameter(const CParameter & rhs) Copies a CParameter object. | |
| virtual | ~CParameter() Destroys the CParameter object. |
Public Functions inherited from GenApi::IBase
| Name | |
|---|---|
| virtual | ~IBase() Virtual destructor enforcing virtual destructor on all derived classes. |
Public Functions Documentation#
CEnumParameter#
CEnumParameter()
Creates an empty CEnumParameter object.
Error Safety:
Does not throw C++ exceptions.
CEnumParameter#
explicit CEnumParameter(
GenApi::INode * pNode
)
Creates a CEnumParameter object and attaches it to a node, typically retrieved for a nodemap calling GetNode().
Parameters:
- pNode The node to attach.
Postcondition:
- If the passed node does not match the parameter type, the parameter will be empty, see IsValid().
- If the passed node does match the parameter type, it is attached and the parameter object can be used to access the node's functionality.
- The parameter object must not be used to access the node's functionality if the source of the attached
pNodehas been destroyed. In this case, call Release() or attach a new node.
Error Safety:
Does not throw C++ exceptions.
CEnumParameter#
explicit CEnumParameter(
GenApi::IEnumeration * pEnumeration
)
Creates a CEnumParameter object and attaches it to a node of a matching type.
Parameters:
- pEnumeration The node to attach.
Postcondition: The parameter object must not be used to access the node's functionality if the source of the attached pEnumeration has been destroyed. In this case, call Release() or attach a new node.
Error Safety:
Does not throw C++ exceptions.
CEnumParameter#
CEnumParameter(
GenApi::INodeMap * pNodeMap,
const char * pName
)
Creates a CEnumParameter object and attaches it to a node retrieved from the provided node map.
Parameters:
- pNodeMap The node map. The source of the parameter.
- pName The name of the parameter to attach.
Postcondition:
- If
pNodeMapornameis NULL, the parameter will be empty, see IsValid(). - If the node does not match the parameter type, the parameter will be empty, see IsValid().
- If the node does match the parameter type, it is attached and the parameter object can be used to access the node's functionality.
- The parameter object must not be used to access the node's functionality if the provided node map has been destroyed. In this case, call Release() or attach a new node.
Error Safety:
The call to GenApi::INodeMap::GetNode can throw C++ exceptions.
CEnumParameter#
CEnumParameter(
GenApi::INodeMap & nodeMap,
const char * pName
)
Creates a CEnumParameter object and attaches it to a node retrieved from the provided node map.
Parameters:
- nodeMap The node map. The source of the parameter.
- pName The name of the parameter to attach.
Postcondition:
- If
nameis NULL, the parameter will be empty, see IsValid(). - If the node does not match the parameter type, the parameter will be empty, see IsValid().
- If the node does match the parameter type, it is attached and the parameter object can be used to access the node's functionality.
- The parameter object must not be used to access the node's functionality if the provided node map has been destroyed. In this case, call Release() or attach a new node.
Error Safety:
The call to GenApi::INodeMap::GetNode can throw C++ exceptions.
CEnumParameter#
CEnumParameter(
const CEnumParameter & rhs
)
Copies a CEnumParameter object.
Parameters:
- rhs The object to copy.
Error Safety:
Does not throw C++ exceptions.
~CEnumParameter#
virtual ~CEnumParameter()
Destroys the CEnumParameter object.
Error Safety:
Does not throw C++ exceptions.
Does not access the attached node.
Attach#
virtual bool Attach(
GenApi::INodeMap * pNodeMap,
const char * pName
)
Attaches a node retrieved from the provided node map.
Parameters:
- pNodeMap The node map. The source of the parameter.
- pName The name of the parameter to attach.
Return: Returns true if the node has been attached.
Postcondition:
- If
pNodeMapornameis NULL, the parameter will be empty, see IsValid(). - If the node does not match the parameter type, the parameter will be empty, see IsValid().
- If the node does match the parameter type, it is attached and the parameter object can be used to access the node's functionality.
- The parameter object must not be used to access the node's functionality if the provided node map has been destroyed. In this case, call Release() or attach a new node.
Error Safety:
The call to GenApi::INodeMap::GetNode can throw C++ exceptions.
Reimplements: Pylon::CParameter::Attach
Attach#
virtual bool Attach(
GenApi::INodeMap & nodeMap,
const char * pName
)
Attaches a node retrieved from the provided node map.
Parameters:
- nodeMap The node map. The source of the parameter.
- pName The name of the parameter to attach.
Return: Returns true if the node has been attached.
Postcondition:
- If
nameis NULL the parameter will be empty, see IsValid(). - If the node does not match the parameter type, the parameter will be empty, see IsValid().
- If the node does match the parameter type, it is attached and the parameter object can be used to access the node's functionality.
- The parameter object must not be used to access the node's functionality if the provided node map has been destroyed. In this case, call Release() or attach a new node.
Error Safety:
The call to GenApi::INodeMap::GetNode can throw C++ exceptions.
Reimplements: Pylon::CParameter::Attach
Attach#
virtual bool Attach(
GenApi::INode * pNode
)
Attaches a node, typically retrieved for a nodemap calling GetNode().
Parameters:
- pNode The node to assign.
Return: Returns true if the node has been attached.
Postcondition:
- If the node does not match the parameter type, the parameter will be empty, see IsValid().
- If the node does match the parameter type, it is attached and the parameter object can be used to access the node's functionality.
- The parameter object must not be used to access the node's functionality if the source of the attached
pNodehas been destroyed. In this case, call Release() or attach a new node.
Error Safety:
Does not throw C++ exceptions.
Reimplements: Pylon::CParameter::Attach
Attach#
virtual bool Attach(
GenApi::IEnumeration * pEnumeration
)
Assigns a node of the same type to the parameter object.
Parameters:
- pEnumeration The node to assign.
Return: Returns true if the node has been attached.
Error Safety:
Does not throw C++ exceptions.
operator=#
CEnumParameter & operator=(
const CEnumParameter & rhs
)
Assigns a CEnumParameter object.
Parameters:
- rhs The object to assign.
Error Safety:
Does not throw C++ exceptions.
Equals#
virtual bool Equals(
const CEnumParameter & rhs
) const
Returns true if the same nodes are attached or both parameters are empty.
Parameters:
- rhs The object to compare to.
Return: Returns true if the same nodes are attached or both parameters are empty.
Error Safety:
Does not throw C++ exceptions.
Equals#
virtual bool Equals(
const GenApi::INode * pNode
) const
Returns true if the attached node pointer is equal.
Parameters:
- pNode The node to compare to.
Return: Returns true if the attached node pointer is equal.
Error Safety:
Does not throw C++ exceptions.
Reimplements: Pylon::CParameter::Equals
Equals#
virtual bool Equals(
const GenApi::IEnumeration * pEnumeration
) const
Returns true if the attached node pointer is equal.
Parameters:
- pEnumeration The node to compare to.
Return: Returns true if the attached node pointer is equal.
Error Safety:
Does not throw C++ exceptions.
Release#
virtual void Release()
Releases the attached node.
Error Safety:
Does not throw C++ exceptions.
Reimplements: Pylon::CParameter::Release
IsValid#
virtual bool IsValid() const
Indicates whether a node is attached.
Return: Returns true if a node is attached.
Error Safety:
Does not throw C++ exceptions.
Reimplements: Pylon::CParameter::IsValid
GetSymbolics#
virtual void GetSymbolics(
GenApi::StringList_t & Symbolics
)
Get list of symbolic Values.
Reimplements: GenApi::IEnumeration::GetSymbolics
GetEntries#
virtual void GetEntries(
GenApi::NodeList_t & Entries
)
Get list of entry nodes.
Reimplements: GenApi::IEnumeration::GetEntries
operator=#
virtual GenApi::IEnumeration & operator=(
const GenICam::gcstring & ValueStr
)
Set string node value.
Reimplements: GenApi::IEnumeration::operator=
SetIntValue#
virtual void SetIntValue(
int64_t Value,
bool Verify =true
)
Set integer node value.
Parameters:
- Value The value to set
- Verify Enables AccessMode and Range verification (default = true)
Reimplements: GenApi::IEnumeration::SetIntValue
operator*#
virtual GenICam::gcstring operator*()
Get string node value.
Reimplements: GenApi::IEnumeration::operator*
GetIntValue#
virtual int64_t GetIntValue(
bool Verify =false,
bool IgnoreCache =false
)
Get integer node value.
Parameters:
- Verify Enables Range verification (default = false). The AccessMode is always checked
- IgnoreCache If true the value is read ignoring any caches (default = false)
Return: The value read
Reimplements: GenApi::IEnumeration::GetIntValue
GetEntryByName#
virtual GenApi::IEnumEntry * GetEntryByName(
const GenICam::gcstring & Symbolic
)
Get an entry node by name.
Reimplements: GenApi::IEnumeration::GetEntryByName
GetEntry#
virtual GenApi::IEnumEntry * GetEntry(
const int64_t IntValue
)
Get an entry node by its IntValue.
Reimplements: GenApi::IEnumeration::GetEntry
GetCurrentEntry#
virtual GenApi::IEnumEntry * GetCurrentEntry(
bool Verify =false,
bool IgnoreCache =false
)
Get the current entry.
Reimplements: GenApi::IEnumeration::GetCurrentEntry
GetValueOrDefault#
virtual String_t GetValueOrDefault(
const String_t & defaultValue
)
Gets the value of the parameter if the parameter is readable.
Parameters:
- defaultValue The default value returned if the parameter is not readable.
Return: Returns the parameter value if the parameter is readable. Otherwise returns the default value.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions if reading the value fails.
Reimplements: Pylon::IEnumerationEx::GetValueOrDefault
Otherwise returns the default value.
TrySetValue#
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.
Parameters:
- value The value to set.
Return: Returns false if the parameter is not writable or the value is not contained in the set of settable enumeration values.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:-
Can throw exceptions if the preconditions are not met or if writing the value fails.
Reimplements: Pylon::IEnumerationEx::TrySetValue
SetValue#
virtual void SetValue(
const char ** nullTerminatedList
)
Sets the value of the parameter to the first valid value in a list of values.
Parameters:
- nullTerminatedList The list of possible values to set. The list is terminated by a NULL value.
Precondition:
- The parameter must be writable.
- At least one value within the list passed must be contained in the set of settable enumeration values.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions if the parameter is not writable, no value nullTerminatedList is settable, or writing the value fails.
Reimplements: Pylon::IEnumerationEx::SetValue
Example:
CEnumParameter pixelFormat(nodemap, "PixelFormat");
const char* list[] = { "BayerGR8", "BayerRG8", "BayerGB8", "BayerBG8", "Mono8", NULL };
pixelFormat.SetValue(list);
TrySetValue#
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.
Parameters:
- nullTerminatedList The list of possible values to set. The list is terminated by a NULL value.
Return: Returns false if the parameter is not writable.
Precondition: At least one value within the passed list must be contained in the set of settable enumeration values.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions if the parameter is not writable, no value nullTerminatedList is settable, or writing the value fails.
Reimplements: Pylon::IEnumerationEx::TrySetValue
Example:
CEnumParameter pixelFormat(nodemap, "PixelFormat");
const char* list[] = { "BayerGR8", "BayerRG8", "BayerGB8", "BayerBG8", "Mono8", NULL };
pixelFormat.TrySetValue(list);
CanSetValue#
virtual bool CanSetValue(
const String_t & value
)
Indicates whether the given value can be set.
Parameters:
- value The value to be checked.
Return: Returns true if the value can be set, otherwise false.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Does not throw exceptions.
Reimplements: Pylon::IEnumerationEx::CanSetValue
SetValue#
virtual void SetValue(
const String_t & value
)
Sets the value of the parameter.
Parameters:
- value The value to set.
Precondition: The value must be contained in the set of settable enumeration values.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions if the parameter is not writable, no value is valid, or writing the value fails.
Reimplements: Pylon::IEnumerationEx::SetValue
Calls FromString().
GetValue#
virtual String_t GetValue()
Gets the value of the parameter.
Return: Returns the current parameter value.
Precondition: The parameter must be readable.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions if the parameter is not readable or if reading the value fails.
Reimplements: Pylon::IEnumerationEx::GetValue
GetSettableValues#
virtual void GetSettableValues(
GenApi::StringList_t & values
)
Gets a list of all values of the enumeration that are currently settable.
Parameters:
- values Returns a list of all values of the enumeration that are currently settable.
Precondition: The parameter must be readable.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions.
Reimplements: Pylon::IEnumerationEx::GetSettableValues
GetAllValues#
virtual void GetAllValues(
GenApi::StringList_t & values
)
Gets a list of all values of the enumeration including the values that are currently not settable.
Parameters:
- values Returns a list of all values of the enumeration including the values that are currently not settable.
Precondition: The parameter must be readable.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions.
Reimplements: Pylon::IEnumerationEx::GetAllValues
GetEntryByNameAsParameter#
virtual CParameter GetEntryByNameAsParameter(
const GenICam::gcstring & value
)
Gets an enumeration entry by its symbolic name.
Parameters:
- value The symbolic name of the enumeration entry, e.g., "Testimage1".
Precondition: The parameter must be readable.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions.
Reimplements: Pylon::IEnumerationEx::GetEntryByNameAsParameter
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().
GetCurrentEntryAsParameter#
virtual CParameter GetCurrentEntryAsParameter()
Gets the currently selected entry of an enumeration.
Precondition: The parameter must be readable.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions.
Reimplements: Pylon::IEnumerationEx::GetCurrentEntryAsParameter
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().
GetNode#
inline virtual INode * GetNode()
Get the INode interface of the node.
Reimplemented by: Pylon::CArrayParameter::GetNode
ToString#
virtual GenICam::gcstring ToString(
bool Verify =false,
bool IgnoreCache =false
)
Get content of the node as string.
Parameters:
- Verify Enables Range verification (default = false). The AccessMode is always checked
- IgnoreCache If true the value is read ignoring any caches (default = false)
Return: The value read
Reimplemented by: Pylon::CArrayParameter::ToString
FromString#
virtual void FromString(
const GenICam::gcstring & ValueStr,
bool Verify =true
)
Set content of the node as string.
Parameters:
- ValueStr The value to set
- Verify Enables AccessMode and Range verification (default = true)
Reimplemented by: Pylon::CArrayParameter::FromString
IsValueCacheValid#
virtual bool IsValueCacheValid() const
Checks if the value comes from cache or is requested from another node.
Reimplemented by: Pylon::CArrayParameter::IsValueCacheValid
GetAccessMode#
virtual EAccessMode GetAccessMode() const
Get the access mode of the node.
Reimplemented by: Pylon::CArrayParameter::GetAccessMode
IsReadable#
virtual bool IsReadable() const
Indicates whether the parameter is readable.
Return: Returns true if the parameter is readable.
Error Safety:
Does not throw C++ exceptions.
Reimplemented by: Pylon::CArrayParameter::IsReadable
IsWritable#
virtual bool IsWritable() const
Indicates whether the parameter is writable.
Return: Returns true if the parameter is writable.
Error Safety:
Does not throw C++ exceptions.
Reimplemented by: Pylon::CArrayParameter::IsWritable
GetInfo#
virtual String_t GetInfo(
EParameterInfo info
)
Gets the parameter information.
Parameters:
- info The type information to return.
Return: Returns the parameter information.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Throws an exception if no node is attached. Can throw exceptions if the retrieval of the information fails.
Reimplemented by: Pylon::CArrayParameter::GetInfo
GetInfoOrDefault#
virtual String_t GetInfoOrDefault(
EParameterInfo info,
const String_t defaultInfo
)
Gets the parameter information if the parameter is attached to a node.
Parameters:
- 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.
- defaultInfo The default information returned if the parameter is not attached to a node.
Return: Returns the parameter information if the parameter is attached to a node. Otherwise returns the default information.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions if the retrieval of the information fails.
Reimplemented by: Pylon::CArrayParameter::GetInfoOrDefault
See IsValid().
ToStringOrDefault#
virtual String_t ToStringOrDefault(
const String_t & defaultValue
)
Gets the parameter value as string if the parameter is readable.
Parameters:
- defaultValue The default value returned if the parameter is not readable.
Return: Returns the parameter value if the parameter is readable. Otherwise returns the default value.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions if reading the value fails.
Reimplemented by: Pylon::CArrayParameter::ToStringOrDefault
Otherwise returns the default value.
Attach#
virtual bool Attach(
GenApi::IValue * pValue
)
Assigns a node of the same type to the parameter object.
Parameters:
- pValue The node to assign.
Return: Returns true if the node has been attached.
Error Safety:
Does not throw C++ exceptions.
Equals#
virtual bool Equals(
const CParameter & rhs
) const
Returns true if the same nodes are attached or both parameters are empty.
Parameters:
- rhs The object to compare to.
Return: Returns true if the same nodes are attached or both parameters are empty.
Error Safety:
Does not throw C++ exceptions.
Equals#
virtual bool Equals(
const GenApi::IValue * pValue
) const
Returns true if the attached node pointer is equal.
Parameters:
- pValue The node to compare to.
Return: Returns true if the attached node pointer is equal.
Error Safety:
Does not throw C++ exceptions.
GetAccessMode#
virtual GenApi::EAccessMode GetAccessMode() const
Get the access mode of the node.
Reimplements: GenApi::IBase::GetAccessMode
GetNode#
virtual GenApi::INode * GetNode()
Get the INode interface of the node.
Reimplements: GenApi::IBoolean::GetNode
ToString#
virtual GenICam::gcstring ToString(
bool Verify =false,
bool IgnoreCache =false
)
Get content of the node as string.
Parameters:
- Verify Enables Range verification (default = false). The AccessMode is always checked
- IgnoreCache If true the value is read ignoring any caches (default = false)
Return: The value read
Reimplements: GenApi::IBoolean::ToString
FromString#
virtual void FromString(
const GenICam::gcstring & ValueStr,
bool Verify =true
)
Set content of the node as string.
Parameters:
- ValueStr The value to set
- Verify Enables AccessMode and Range verification (default = true)
Reimplements: GenApi::IBoolean::FromString
IsValueCacheValid#
virtual bool IsValueCacheValid() const
Checks if the value comes from cache or is requested from another node.
Reimplements: GenApi::IBoolean::IsValueCacheValid
IsReadable#
virtual bool IsReadable() const
Indicates whether the parameter is readable.
Return: Returns true if the parameter is readable.
Error Safety:
Does not throw C++ exceptions.
Reimplements: Pylon::CArrayParameter::IsReadable
IsWritable#
virtual bool IsWritable() const
Indicates whether the parameter is writable.
Return: Returns true if the parameter is writable.
Error Safety:
Does not throw C++ exceptions.
Reimplements: Pylon::CArrayParameter::IsWritable
GetInfo#
virtual String_t GetInfo(
EParameterInfo info
)
Gets the parameter information.
Parameters:
- info The type information to return.
Return: Returns the parameter information.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Throws an exception if no node is attached. Can throw exceptions if the retrieval of the information fails.
Reimplements: Pylon::CArrayParameter::GetInfo
GetInfoOrDefault#
virtual String_t GetInfoOrDefault(
EParameterInfo info,
const String_t defaultInfo
)
Gets the parameter information if the parameter is attached to a node.
Parameters:
- 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.
- defaultInfo The default information returned if the parameter is not attached to a node.
Return: Returns the parameter information if the parameter is attached to a node. Otherwise returns the default information.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions if the retrieval of the information fails.
Reimplements: Pylon::CArrayParameter::GetInfoOrDefault
See IsValid().
ToStringOrDefault#
virtual String_t ToStringOrDefault(
const String_t & defaultValue
)
Gets the parameter value as string if the parameter is readable.
Parameters:
- defaultValue The default value returned if the parameter is not readable.
Return: Returns the parameter value if the parameter is readable. Otherwise returns the default value.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions if reading the value fails.
Reimplements: Pylon::CArrayParameter::ToStringOrDefault
Otherwise returns the default value.
Protected Functions Documentation#
SetValue#
void SetValue(
const Table_t & table,
size_t index,
bool verify
)
GetValue#
size_t GetValue(
const Table_t & table,
bool verify,
bool ignoreCache
)
GetEntry#
GenApi::IEnumEntry * GetEntry(
const Table_t & table,
size_t index
)
CanSetValue#
bool CanSetValue(
const Table_t & table,
size_t index
)
Protected Attributes Documentation#
m_pFeature#
GenApi::IEnumeration * m_pFeature;
m_pValue#
GenApi::IValue * m_pValue;
Updated on 5 July 2022 at 15:30:00