00001 /*============================================================================= 00002 Copyright (C) 2012 Allied Vision Technologies. All Rights Reserved. 00003 00004 Redistribution of this file, in original or modified form, without 00005 prior written consent of Allied Vision Technologies is prohibited. 00006 00007 ------------------------------------------------------------------------------- 00008 00009 File: EnumEntry.h 00010 00011 Description: Definition of class AVT::VmbAPI::EnumEntry. 00012 An EnumEntry consists of 00013 Name 00014 DisplayName 00015 Value 00016 of one particular enumeration 00017 00018 ------------------------------------------------------------------------------- 00019 00020 THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED 00021 WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF TITLE, 00022 NON-INFRINGEMENT, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 00023 DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, 00024 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 00025 (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 00026 LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED 00027 AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR 00028 TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 00029 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 00030 00031 =============================================================================*/ 00032 00033 #ifndef AVT_VMBAPI_ENUMENTRY_H 00034 #define AVT_VMBAPI_ENUMENTRY_H 00035 00036 #include <string> 00037 00038 #include <VimbaC/Include/VimbaC.h> 00039 #include <VimbaCPP/Include/VimbaCPPCommon.h> 00040 00041 namespace AVT { 00042 namespace VmbAPI { 00043 00044 class EnumEntry 00045 { 00046 public: 00047 // 00048 // Method: EnumEntry constructor 00049 // 00050 // Purpose: Creates an instance of class EnumEntry 00051 // 00052 // Parameters: 00053 // 00054 // [in ] const char *pName The name of the enum 00055 // [in ] const char *pDisplayName The declarative name of the enum 00056 // [in ] const char *pDescription, The descripton of the enum 00057 // [in ] const char *pTooltip A tooltip that can be used by a GUI 00058 // [in ] const char *pSNFCNamespace the SFNC namespace of the enum 00059 // [in ] VmbFeatureVisibility_t visibility The visibility of the enum 00060 // [in ] VmbInt64_t value The integer value of the enum 00061 // 00062 EnumEntry( const char *pName, 00063 const char *pDisplayName, 00064 const char *pDescription, 00065 const char *pTooltip, 00066 const char *pSNFCNamespace, 00067 VmbFeatureVisibility_t visibility, 00068 VmbInt64_t value); 00069 00070 // 00071 // Method: EnumEntry constructor 00072 // 00073 // Purpose: Creates an instance of class EnumEntry 00074 // 00075 IMEXPORT EnumEntry(); 00076 00077 // 00078 // Method: EnumEntry destructor 00079 // 00080 // Purpose: Destroys an instance of class EnumEntry 00081 // 00082 IMEXPORT virtual ~EnumEntry(); 00083 00084 // 00085 // Method: GetName() 00086 // 00087 // Purpose: Gets the name of an enumeration 00088 // 00089 // Parameters: 00090 // 00091 // [out] std::string& name The name of the enumeration 00092 // 00093 VmbErrorType GetName( std::string &name ) const; 00094 00095 // 00096 // Method: GetDisplayName() 00097 // 00098 // Purpose: Gets a more declarative name of an enumeration 00099 // 00100 // Parameters: 00101 // 00102 // [out] std::string& displayName The display name of the enumeration 00103 // 00104 VmbErrorType GetDisplayName( std::string &displayName ) const; 00105 00106 // 00107 // Method: GetDescription() 00108 // 00109 // Purpose: Gets the description of an enumeration 00110 // 00111 // Parameters: 00112 // 00113 // [out] std::string& description The description of the enumeration 00114 // 00115 VmbErrorType GetDescription( std::string &description ) const; 00116 00117 // 00118 // Method: GetTooltip() 00119 // 00120 // Purpose: Gets a tooltip that can be used as pop up help in a GUI 00121 // 00122 // Parameters: 00123 // 00124 // [out] std::string& tooltip The tooltip as string 00125 // 00126 VmbErrorType GetTooltip( std::string &tooltip ) const; 00127 00128 // 00129 // Method: GetValue() 00130 // 00131 // Purpose: Gets the integer value of an enumeration 00132 // 00133 // Parameters: 00134 // 00135 // [out] VmbInt64_t& value The integer value of the enumeration 00136 // 00137 IMEXPORT VmbErrorType GetValue( VmbInt64_t &value ) const; 00138 00139 // 00140 // Method: GetVisibility() 00141 // 00142 // Purpose: Gets the visibility of an enumeration 00143 // 00144 // Parameters: 00145 // 00146 // [out] bool& value True when visible otherwise false 00147 // 00148 IMEXPORT VmbErrorType GetVisibility( VmbFeatureVisibilityType &value ) const; 00149 00150 // 00151 // Method: GetSNFCNamespace() 00152 // 00153 // Purpose: Gets the standard feature naming convention namespace of the enumeration 00154 // 00155 // Parameters: 00156 // 00157 // [out] std::string& tooltip The namespace as string 00158 // 00159 VmbErrorType GetSFNCNamespace( std::string &SFNCNamespace ) const; 00160 00161 private: 00162 std::string m_strName; 00163 std::string m_strDisplayName; 00164 std::string m_strDescription; 00165 std::string m_strTooltip; 00166 std::string m_strNamespace; 00167 VmbFeatureVisibilityType m_Visibility; 00168 VmbInt64_t m_nValue; 00169 00170 // Array functions to pass data across DLL boundaries 00171 IMEXPORT VmbErrorType GetName( char * const pName, VmbUint32_t &size ) const; 00172 IMEXPORT VmbErrorType GetDisplayName( char * const pDisplayName, VmbUint32_t &size ) const; 00173 IMEXPORT VmbErrorType GetTooltip( char * const pStrTooltip, VmbUint32_t &size ) const; 00174 IMEXPORT VmbErrorType GetDescription( char * const pStrDescription, VmbUint32_t &size ) const; 00175 IMEXPORT VmbErrorType GetSFNCNamespace( char * const pStrNamespace, VmbUint32_t &size ) const; 00176 00177 }; 00178 00179 #include <VimbaCPP/Include/EnumEntry.hpp> 00180 00181 }} // namespace AVT::VmbAPI 00182 00183 #endif