|
| 1 | +--- |
| 2 | +title: "_ATL_FUNC_INFO Structure" |
| 3 | +ms.custom: na |
| 4 | +ms.date: "10/14/2016" |
| 5 | +ms.prod: "visual-studio-dev14" |
| 6 | +ms.reviewer: na |
| 7 | +ms.suite: na |
| 8 | +ms.technology: |
| 9 | + - "devlang-cpp" |
| 10 | +ms.tgt_pltfrm: na |
| 11 | +ms.topic: "article" |
| 12 | +f1_keywords: |
| 13 | + - "_ATL_FUNC_INFO" |
| 14 | + - "ATL::_ATL_FUNC_INFO" |
| 15 | + - "ATL._ATL_FUNC_INFO" |
| 16 | +dev_langs: |
| 17 | + - "C++" |
| 18 | +helpviewer_keywords: |
| 19 | + - "_ATL_FUNC_INFO structure" |
| 20 | + - "ATL_FUNC_INFO structure" |
| 21 | +ms.assetid: 441ebe2c-f971-47de-9f52-a258e8d6f88e |
| 22 | +caps.latest.revision: 17 |
| 23 | +ms.author: "mblome" |
| 24 | +manager: "ghogen" |
| 25 | +translation.priority.ht: |
| 26 | + - "cs-cz" |
| 27 | + - "de-de" |
| 28 | + - "es-es" |
| 29 | + - "fr-fr" |
| 30 | + - "it-it" |
| 31 | + - "ja-jp" |
| 32 | + - "ko-kr" |
| 33 | + - "pl-pl" |
| 34 | + - "pt-br" |
| 35 | + - "ru-ru" |
| 36 | + - "tr-tr" |
| 37 | + - "zh-cn" |
| 38 | + - "zh-tw" |
| 39 | +--- |
| 40 | +# _ATL_FUNC_INFO Structure |
| 41 | +Contains type information used to describe a method or property on a dispinterface. |
| 42 | + |
| 43 | +## Syntax |
| 44 | + |
| 45 | +``` |
| 46 | +struct _ATL_FUNC_INFO{ CALLCONV cc; VARTYPE vtReturn; SHORT nParams; VARTYPE pVarTypes[_ATL_MAX_VARTYPES]; |
| 47 | +}; |
| 48 | +``` |
| 49 | + |
| 50 | +## Members |
| 51 | + **cc** |
| 52 | + The calling convention. When using this structure with the [IDispEventSimpleImpl](../atl/idispeventsimpleimpl-class.md) class, this member must be **CC_STDCALL**. `CC_CDECL` is the only option supported in Windows CE for the `CALLCONV` field of the `_ATL_FUNC_INFO` structure. Any other value is unsupported thus its behavior undefined. |
| 53 | + |
| 54 | + **vtReturn** |
| 55 | + The variant type of the function return value. |
| 56 | + |
| 57 | + **nParams** |
| 58 | + The number of function parameters. |
| 59 | + |
| 60 | + **pVarTypes** |
| 61 | + An array of variant types of the function parameters. |
| 62 | + |
| 63 | +## Remarks |
| 64 | + Internally, ATL uses this structure to hold information obtained from a type library. You may need to manipulate this structure directly if you provide type information for an event handler used with the [IDispEventSimpleImpl](../atl/idispeventsimpleimpl-class.md) class and [SINK_ENTRY_INFO](../Topic/SINK_ENTRY_INFO.md) macro. |
| 65 | + |
| 66 | +## Example |
| 67 | + Given a dispinterface method defined in IDL: |
| 68 | + |
| 69 | + [!code[NVC_ATL_Windowing#139](../atl/codesnippet/CPP/_atl_func_info-structure_1.idl)] |
| 70 | + |
| 71 | + you would define an `_ATL_FUNC_INFO` structure: |
| 72 | + |
| 73 | + [!code[NVC_ATL_Windowing#140](../atl/codesnippet/CPP/_atl_func_info-structure_2.h)] |
| 74 | + |
| 75 | +## Requirements |
| 76 | + **Header:** atlcom.h |
| 77 | + |
| 78 | +## See Also |
| 79 | + [Structures](../atl/atl-structures.md) |
| 80 | + [IDispEventSimpleImpl Class](../atl/idispeventsimpleimpl-class.md) |
| 81 | + [SINK_ENTRY_INFO](../Topic/SINK_ENTRY_INFO.md) |
| 82 | + |
0 commit comments