⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 iball_p.c

📁 服务器方面的
💻 C
📖 第 1 页 / 共 2 页
字号:
        (unsigned int)((long)_StubMsg.Buffer - (long)_pRpcMessage->Buffer);
    
}


/* [id] */ HRESULT STDMETHODCALLTYPE IBall_Move_Proxy( 
    IBall __RPC_FAR * This,
    /* [in] */ BOOL bAlive,
    /* [retval][out] */ BOOL __RPC_FAR *bRet)
{

    HRESULT _RetVal;
    
    RPC_MESSAGE _RpcMessage;
    
    MIDL_STUB_MESSAGE _StubMsg;
    
    RpcTryExcept
        {
        NdrProxyInitialize(
                      ( void __RPC_FAR *  )This,
                      ( PRPC_MESSAGE  )&_RpcMessage,
                      ( PMIDL_STUB_MESSAGE  )&_StubMsg,
                      ( PMIDL_STUB_DESC  )&Object_StubDesc,
                      5);
        
        
        
        RpcTryFinally
            {
            
            _StubMsg.BufferLength = 4U;
            NdrProxyGetBuffer(This, &_StubMsg);
            *(( BOOL __RPC_FAR * )_StubMsg.Buffer)++ = bAlive;
            
            NdrProxySendReceive(This, &_StubMsg);
            
            if ( (_RpcMessage.DataRepresentation & 0X0000FFFFUL) != NDR_LOCAL_DATA_REPRESENTATION )
                NdrConvert( (PMIDL_STUB_MESSAGE) &_StubMsg, (PFORMAT_STRING) &__MIDL_ProcFormatString.Format[22] );
            
            *bRet = *(( BOOL __RPC_FAR * )_StubMsg.Buffer)++;
            
            _RetVal = *(( HRESULT __RPC_FAR * )_StubMsg.Buffer)++;
            
            }
        RpcFinally
            {
            NdrProxyFreeBuffer(This, &_StubMsg);
            
            }
        RpcEndFinally
        
        }
    RpcExcept(_StubMsg.dwStubPhase != PROXY_SENDRECEIVE)
        {
        NdrClearOutParameters(
                         ( PMIDL_STUB_MESSAGE  )&_StubMsg,
                         ( PFORMAT_STRING  )&__MIDL_TypeFormatString.Format[12],
                         ( void __RPC_FAR * )bRet);
        _RetVal = NdrProxyErrorHandler(RpcExceptionCode());
        }
    RpcEndExcept
    return _RetVal;
}

void __RPC_STUB IBall_Move_Stub(
    IRpcStubBuffer *This,
    IRpcChannelBuffer *_pRpcChannelBuffer,
    PRPC_MESSAGE _pRpcMessage,
    DWORD *_pdwStubPhase)
{
    BOOL _M1;
    HRESULT _RetVal;
    MIDL_STUB_MESSAGE _StubMsg;
    BOOL bAlive;
    BOOL __RPC_FAR *bRet;
    
NdrStubInitialize(
                     _pRpcMessage,
                     &_StubMsg,
                     &Object_StubDesc,
                     _pRpcChannelBuffer);
    bRet = 0;
    RpcTryFinally
        {
        if ( (_pRpcMessage->DataRepresentation & 0X0000FFFFUL) != NDR_LOCAL_DATA_REPRESENTATION )
            NdrConvert( (PMIDL_STUB_MESSAGE) &_StubMsg, (PFORMAT_STRING) &__MIDL_ProcFormatString.Format[22] );
        
        bAlive = *(( BOOL __RPC_FAR * )_StubMsg.Buffer)++;
        
        bRet = &_M1;
        
        *_pdwStubPhase = STUB_CALL_SERVER;
        _RetVal = (((IBall *) ((CStdStubBuffer *)This)->pvServerObject)->lpVtbl) -> Move(
        (IBall *) ((CStdStubBuffer *)This)->pvServerObject,
        bAlive,
        bRet);
        
        *_pdwStubPhase = STUB_MARSHAL;
        
        _StubMsg.BufferLength = 4U + 4U;
        NdrStubGetBuffer(This, _pRpcChannelBuffer, &_StubMsg);
        *(( BOOL __RPC_FAR * )_StubMsg.Buffer)++ = *bRet;
        
        *(( HRESULT __RPC_FAR * )_StubMsg.Buffer)++ = _RetVal;
        
        }
    RpcFinally
        {
        }
    RpcEndFinally
    _pRpcMessage->BufferLength = 
        (unsigned int)((long)_StubMsg.Buffer - (long)_pRpcMessage->Buffer);
    
}


static const MIDL_STUB_DESC Object_StubDesc = 
    {
    0,
    NdrOleAllocate,
    NdrOleFree,
    0,
    0,
    0,
    0,
    0,
    __MIDL_TypeFormatString.Format,
    0, /* -error bounds_check flag */
    0x10001, /* Ndr library version */
    0,
    0x300002c, /* MIDL Version 3.0.44 */
    0,
    0,
    0,  /* Reserved1 */
    0,  /* Reserved2 */
    0,  /* Reserved3 */
    0,  /* Reserved4 */
    0   /* Reserved5 */
    };

const CINTERFACE_PROXY_VTABLE(6) _IBallProxyVtbl = 
{
    &IID_IBall,
    IUnknown_QueryInterface_Proxy,
    IUnknown_AddRef_Proxy,
    IUnknown_Release_Proxy ,
    IBall_get_Ball_Proxy ,
    IBall_Reset_Proxy ,
    IBall_Move_Proxy
};


static const PRPC_STUB_FUNCTION IBall_table[] =
{
    IBall_get_Ball_Stub,
    IBall_Reset_Stub,
    IBall_Move_Stub
};

const CInterfaceStubVtbl _IBallStubVtbl =
{
    &IID_IBall,
    0,
    6,
    &IBall_table[-3],
    CStdStubBuffer_METHODS
};

#pragma data_seg(".rdata")

#if !defined(__RPC_WIN32__)
#error  Invalid build platform for this stub.
#endif


static const MIDL_PROC_FORMAT_STRING __MIDL_ProcFormatString =
    {
        0,
        {
            
            0x51,       /* FC_OUT_PARAM */
#ifndef _ALPHA_
            0x1,        /* x86, MIPS & PPC Stack size = 1 */
#else
            0x2,        /* Alpha Stack size = 2 */
#endif
/*  2 */    NdrFcShort( 0x0 ),  /* Type Offset=0 */
/*  4 */    
            0x51,       /* FC_OUT_PARAM */
#ifndef _ALPHA_
            0x1,        /* x86, MIPS & PPC Stack size = 1 */
#else
            0x2,        /* Alpha Stack size = 2 */
#endif
/*  6 */    NdrFcShort( 0x0 ),  /* Type Offset=0 */
/*  8 */    
            0x51,       /* FC_OUT_PARAM */
#ifndef _ALPHA_
            0x1,        /* x86, MIPS & PPC Stack size = 1 */
#else
            0x2,        /* Alpha Stack size = 2 */
#endif
/* 10 */    NdrFcShort( 0xc ),  /* Type Offset=12 */
/* 12 */    0x53,       /* FC_RETURN_PARAM_BASETYPE */
            0x8,        /* FC_LONG */
/* 14 */    
            0x4d,       /* FC_IN_PARAM */
#ifndef _ALPHA_
            0x1,        /* x86, MIPS & PPC Stack size = 1 */
#else
            0x2,        /* Alpha Stack size = 2 */
#endif
/* 16 */    NdrFcShort( 0x10 ), /* Type Offset=16 */
/* 18 */    0x4e,       /* FC_IN_PARAM_BASETYPE */
            0x6,        /* FC_SHORT */
/* 20 */    0x53,       /* FC_RETURN_PARAM_BASETYPE */
            0x8,        /* FC_LONG */
/* 22 */    0x4e,       /* FC_IN_PARAM_BASETYPE */
            0x8,        /* FC_LONG */
/* 24 */    
            0x51,       /* FC_OUT_PARAM */
#ifndef _ALPHA_
            0x1,        /* x86, MIPS & PPC Stack size = 1 */
#else
            0x2,        /* Alpha Stack size = 2 */
#endif
/* 26 */    NdrFcShort( 0xc ),  /* Type Offset=12 */
/* 28 */    0x53,       /* FC_RETURN_PARAM_BASETYPE */
            0x8,        /* FC_LONG */

            0x0
        }
    };

static const MIDL_TYPE_FORMAT_STRING __MIDL_TypeFormatString =
    {
        0,
        {
            0x11, 0x4,  /* FC_RP [alloced_on_stack] */
/*  2 */    NdrFcShort( 0x2 ),  /* Offset= 2 (4) */
/*  4 */    
            0x15,       /* FC_STRUCT */
            0x3,        /* 3 */
/*  6 */    NdrFcShort( 0x8 ),  /* 8 */
/*  8 */    0x8,        /* FC_LONG */
            0x8,        /* FC_LONG */
/* 10 */    0x5c,       /* FC_PAD */
            0x5b,       /* FC_END */
/* 12 */    
            0x11, 0xc,  /* FC_RP [alloced_on_stack] [simple_pointer] */
/* 14 */    0x8,        /* FC_LONG */
            0x5c,       /* FC_PAD */
/* 16 */    
            0x11, 0x0,  /* FC_RP */
/* 18 */    NdrFcShort( 0x2 ),  /* Offset= 2 (20) */
/* 20 */    
            0x15,       /* FC_STRUCT */
            0x3,        /* 3 */
/* 22 */    NdrFcShort( 0x10 ), /* 16 */
/* 24 */    0x8,        /* FC_LONG */
            0x8,        /* FC_LONG */
/* 26 */    0x8,        /* FC_LONG */
            0x8,        /* FC_LONG */
/* 28 */    0x5c,       /* FC_PAD */
            0x5b,       /* FC_END */

            0x0
        }
    };

const CInterfaceProxyVtbl * _iball_ProxyVtblList[] = 
{
    ( CInterfaceProxyVtbl *) &_IBallProxyVtbl,
    0
};

const CInterfaceStubVtbl * _iball_StubVtblList[] = 
{
    ( CInterfaceStubVtbl *) &_IBallStubVtbl,
    0
};

PCInterfaceName const _iball_InterfaceNamesList[] = 
{
    "IBall",
    0
};


#define _iball_CHECK_IID(n) IID_GENERIC_CHECK_IID( _iball, pIID, n)

int __stdcall _iball_IID_Lookup( const IID * pIID, int * pIndex )
{
    
    if(!_iball_CHECK_IID(0))
        {
        *pIndex = 0;
        return 1;
        }

    return 0;
}

const ExtendedProxyFileInfo iball_ProxyFileInfo = 
{
    (PCInterfaceProxyVtblList *) & _iball_ProxyVtblList,
    (PCInterfaceStubVtblList *) & _iball_StubVtblList,
    (const PCInterfaceName * ) & _iball_InterfaceNamesList,
    0, // no delegation
    & _iball_IID_Lookup, 
    1,
    1
};

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -