龙盟编程博客 | 无障碍搜索 | 云盘搜索神器
快速搜索
主页 > 软件开发 > VC开发 >

Developing COM Components using VC-ATL(3-7)(2)

时间:2009-12-30 15:42来源:未知 作者:admin 点击:
分享到:
struct __declspec(uuid("b1d1c73c-e340-4fdc-8734-92ecec64dc4e"))……………………用户接口IID IValidateCard : IDispatch { // // Wrapper methods for error-handling // long ValidateCreditCard (

struct __declspec(uuid("b1d1c73c-e340-4fdc-8734-92ecec64dc4e"))……………………用户接口IID

IValidateCard : IDispatch

{

    //

    // Wrapper methods for error-handling

    //

    long ValidateCreditCard (

        _bstr_t bstrCCNo,

        _bstr_t bstrCCType );

    HRESULT LuhnCheck (

        _bstr_t bstrCCNo,

        _bstr_t bstrCCType );

    HRESULT LengthCheck (

        _bstr_t bstrCCNo,

        _bstr_t bstrCCType );

    HRESULT PrefixCheck (

        _bstr_t bstrCCNo,

        _bstr_t bstrCCType );……………………………………………….………….. 接口方法(对外)

    //

    // Raw methods provided by interface

    //

    virtual HRESULT __stdcall raw_ValidateCreditCard (

        BSTR bstrCCNo,

        BSTR bstrCCType,

        long * val ) = 0;

精彩图集

赞助商链接