Pylon::IIntegerEx#
#include <pylon/IntegerParameter.h>
Inherits from GenApi::IInteger, Pylon::IValueEx, GenApi::IValue, GenApi::IBase
Inherited by Pylon::CIntegerParameter
Public Functions#
Name | |
---|---|
virtual bool | TrySetValue(int64_t value) =0 Sets the value of the parameter if the parameter is writable. |
virtual int64_t | GetValueOrDefault(int64_t defaultValue) =0 Gets the value of the parameter if the parameter is readable. |
virtual bool | TrySetValue(int64_t value, EIntegerValueCorrection correction) =0 Sets the value of the parameter if the parameter is writable and readable. |
virtual void | SetValue(int64_t value, EIntegerValueCorrection correction) =0 Sets the value of the parameter. |
virtual double | GetValuePercentOfRange() =0 Gets the value of the parameter in percent of its value range (from minimum to maximum). |
virtual void | SetValuePercentOfRange(double percentOfRange) =0 Sets the value of the parameter to a value within its range, using this formula (simplified): ((max - min) * (percentOfRange / 100.0)) + min. |
virtual bool | TrySetValuePercentOfRange(double percentOfRange) =0 If the parameter is writable and readable, sets the value of the parameter to a value within its range, using this formula (simplified): ((max - min) * (percentOfRange / 100.0)) + min. |
virtual void | SetToMaximum() =0 Sets the value of the parameter to the maximum possible value. |
virtual void | SetToMinimum() =0 Sets the value of the parameter to the minimum possible value. |
virtual bool | TrySetToMaximum() =0 Sets the value of the parameter to the maximum possible value if the parameter is readable and writable. |
virtual bool | TrySetToMinimum() =0 Sets the value of the parameter to the minimum possible value if the parameter is readable and writable. |
virtual void | SetValue(int64_t Value, bool Verify =true) =0 Set node value. |
virtual int64_t | GetValue(bool Verify =false, bool IgnoreCache =false) =0 Get node value. |
virtual int64_t | operator())() =0 Get node value. |
virtual int64_t | operator*() =0 Get node value. |
virtual int64_t | GetMin() =0 Get minimum value allowed. |
virtual int64_t | GetMax() =0 Get maximum value allowed. |
virtual EIncMode | GetIncMode() =0 Get increment mode. |
virtual int64_t | GetInc() =0 Get increment. |
virtual int64_autovector_t | GetListOfValidValues(bool bounded =true) =0 Get list of valid value. |
virtual ERepresentation | GetRepresentation() =0 Get recommended representation. |
virtual GenICam::gcstring | GetUnit() =0 Get the physical unit name. |
virtual void | ImposeMin(int64_t Value) =0 Restrict minimum value. |
virtual void | ImposeMax(int64_t Value) =0 Restrict maximum value. |
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. |
virtual void | FromString(const GenICam::gcstring & ValueStr, bool Verify =true) =0 Set content of the node as string. |
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. |
virtual bool | IsWritable() const =0 Indicates whether the parameter is writable. |
virtual bool | IsValid() const =0 Indicates whether a node is attached. |
virtual String_t | GetInfo(EParameterInfo info) =0 Gets the parameter information. |
virtual String_t | GetInfoOrDefault(EParameterInfo info, const String_t defaultInfo) =0 Gets the parameter information if the parameter is attached to a node. |
virtual String_t | ToStringOrDefault(const String_t & defaultValue) =0 Gets the parameter value as string if the parameter is readable. |
Additional inherited members#
Public Functions inherited from GenApi::IInteger
Name | |
---|---|
virtual IInteger & | operator=(int64_t Value) =0 Set node value. |
Public Functions inherited from GenApi::IBase
Name | |
---|---|
virtual | ~IBase() =0 Virtual destructor enforcing virtual destructor on all derived classes. |
Public Functions Documentation#
function TrySetValue#
Sets the value of the parameter if the parameter is writable.
Parameters:
- value The value to set.
Return: Returns false if the parameter is not writable.
Precondition:
- The passed value must be >= GenApi::IInteger::GetMin().
- The passed value must be <= GenApi::IInteger::GetMax().
- The passed value must be aligned to the increment returned by GenApi::IInteger::GetInc().
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.
Reimplemented by: Pylon::CIntegerParameter::TrySetValue
The value must be in the valid range and the increment must be correct.
function GetValueOrDefault#
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 exception if reading the value fails.
Reimplemented by: Pylon::CIntegerParameter::GetValueOrDefault
Otherwise returns the default value.
function TrySetValue#
Sets the value of the parameter if the parameter is writable and readable.
Parameters:
- value The value to set.
- correction The correction method.
Return: Returns false if the parameter is not readable or not writable.
Note Calls TrySetValue(GenApi::IInteger*, int64_t) if
correction
equals IntegerValueCorrection_None.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions if writing the value fails.
Reimplemented by: Pylon::CIntegerParameter::TrySetValue
The value is automatically corrected if needed.
function SetValue#
Sets the value of the parameter.
Parameters:
- value The value to set.
- correction The correction method.
Note Calls GenApi::IInteger::SetValue(int64_t) if
correction
equals IntegerValueCorrection_None.
Precondition:
- The parameter must be writable.
- 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 preconditions are not met or if writing the value fails.
Reimplemented by: Pylon::CIntegerParameter::SetValue
The value is automatically corrected if needed.
function GetValuePercentOfRange#
Gets the value of the parameter in percent of its value range (from minimum to maximum).
Return: Returns the parameter value in percent of its value range. Returns 100 if minimum equals maximum.
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 writing the value fails.
Reimplemented by: Pylon::CIntegerParameter::GetValuePercentOfRange
function SetValuePercentOfRange#
Sets the value of the parameter to a value within its range, using this formula (simplified): ((max - min) * (percentOfRange / 100.0)) + min.
Parameters:
- percentOfRange The percentage of the range to be used in the calculation.
Precondition:
- The parameter must be writable.
- 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 writing the value fails.
Reimplemented by: Pylon::CIntegerParameter::SetValuePercentOfRange
The value is always corrected to the nearest valid value.
The parameter must be writable.
function TrySetValuePercentOfRange#
If the parameter is writable and readable, sets the value of the parameter to a value within its range, using this formula (simplified): ((max - min) * (percentOfRange / 100.0)) + min.
Parameters:
- percentOfRange The percentage of the range to be used in the calculation.
Return: Returns true if the a value has been set.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions if writing the value fails.
Reimplemented by: Pylon::CIntegerParameter::TrySetValuePercentOfRange
The value is always corrected to the nearest valid value.
function SetToMaximum#
Sets the value of the parameter to the maximum possible value.
Precondition:
- The parameter must be writable.
- 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 writable, not readable, or if reading or writing fails.
Reimplemented by: Pylon::CIntegerParameter::SetToMaximum
function SetToMinimum#
Sets the value of the parameter to the minimum possible value.
Precondition:
- The parameter must be writable.
- 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 writable, not readable, or if reading or writing fails.
Reimplemented by: Pylon::CIntegerParameter::SetToMinimum
function TrySetToMaximum#
Sets the value of the parameter to the maximum possible value if the parameter is readable and writable.
Return: Returns true if the maximum value has been set.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions if reading or writing fails.
Reimplemented by: Pylon::CIntegerParameter::TrySetToMaximum
function TrySetToMinimum#
Sets the value of the parameter to the minimum possible value if the parameter is readable and writable.
Return: Returns true if the minimum value has been set.
Thread Safety:
The method accesses the parameter multiple times. These accesses are not synchronized by a lock.
Error Safety:
Can throw exceptions if reading or writing fails.
Reimplemented by: Pylon::CIntegerParameter::TrySetToMinimum
function SetValue#
Set node value.
Parameters:
- Value The value to set
- Verify Enables AccessMode and Range verification (default = true)
Reimplemented by: Pylon::CIntegerParameter::SetValue
function GetValue#
Get 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
Reimplemented by: Pylon::CIntegerParameter::GetValue
function operator()#
Get node value.
Reimplemented by: Pylon::CIntegerParameter::operator())
function operator*#
Get node value.
Reimplemented by: Pylon::CIntegerParameter::operator*
function GetMin#
Get minimum value allowed.
Reimplemented by: Pylon::CIntegerParameter::GetMin
function GetMax#
Get maximum value allowed.
Reimplemented by: Pylon::CIntegerParameter::GetMax
function GetIncMode#
Get increment mode.
Reimplemented by: Pylon::CIntegerParameter::GetIncMode
function GetInc#
Get increment.
Reimplemented by: Pylon::CIntegerParameter::GetInc
function GetListOfValidValues#
Get list of valid value.
Reimplemented by: Pylon::CIntegerParameter::GetListOfValidValues
function GetRepresentation#
Get recommended representation.
Reimplemented by: Pylon::CIntegerParameter::GetRepresentation
function GetUnit#
Get the physical unit name.
Reimplemented by: Pylon::CIntegerParameter::GetUnit
function ImposeMin#
Restrict minimum value.
Reimplemented by: Pylon::CIntegerParameter::ImposeMin
function ImposeMax#
Restrict maximum value.
Reimplemented by: Pylon::CIntegerParameter::ImposeMax
function GetNode#
Get the INode interface of the node.
Reimplemented by: Pylon::CArrayParameter::GetNode
function ToString#
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
function FromString#
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
function IsValueCacheValid#
Checks if the value comes from cache or is requested from another node.
Reimplemented by: Pylon::CArrayParameter::IsValueCacheValid
function GetAccessMode#
Get the access mode of the node.
Reimplemented by: Pylon::CArrayParameter::GetAccessMode
function IsReadable#
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
function IsWritable#
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
function IsValid#
Indicates whether a node is attached.
Return: Returns true if a node is attached.
Error Safety:
Does not throw C++ exceptions.
Reimplemented by: Pylon::CArrayParameter::IsValid, Pylon::CCommandParameter::IsValid, Pylon::CBooleanParameter::IsValid, Pylon::CStringParameter::IsValid, Pylon::CParameter::IsValid, Pylon::CEnumParameter::IsValid, Pylon::CIntegerParameter::IsValid, Pylon::CFloatParameter::IsValid
function GetInfo#
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
function GetInfoOrDefault#
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().
function ToStringOrDefault#
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.