예제 #1
0
 internal static void SNIPacketReset([In] SNIHandle pConn, IOType IOType, SNIPacket pPacket, ConsumerNumber ConsNum)
 {
     if (s_is64bitProcess)
     {
         SNINativeManagedWrapperX64.SNIPacketReset(pConn, IOType, pPacket, ConsNum);
     }
     else
     {
         SNINativeManagedWrapperX86.SNIPacketReset(pConn, IOType, pPacket, ConsNum);
     }
 }
예제 #2
0
 internal static void SNIGetLastError(out SNI_Error pErrorStruct)
 {
     if (s_is64bitProcess)
     {
         SNINativeManagedWrapperX64.SNIGetLastError(out pErrorStruct);
     }
     else
     {
         SNINativeManagedWrapperX86.SNIGetLastError(out pErrorStruct);
     }
 }
예제 #3
0
 internal static void SNIPacketRelease(IntPtr pPacket)
 {
     if (s_is64bitProcess)
     {
         SNINativeManagedWrapperX64.SNIPacketRelease(pPacket);
     }
     else
     {
         SNINativeManagedWrapperX86.SNIPacketRelease(pPacket);
     }
 }
예제 #4
0
 private static unsafe void SNIPacketSetData(SNIPacket pPacket, [In] byte *pbBuf, uint cbBuf)
 {
     if (s_is64bitProcess)
     {
         SNINativeManagedWrapperX64.SNIPacketSetData(pPacket, pbBuf, cbBuf);
     }
     else
     {
         SNINativeManagedWrapperX86.SNIPacketSetData(pPacket, pbBuf, cbBuf);
     }
 }
 internal static void SNIServerEnumClose([In] IntPtr packet)
 {
     if (s_is64bitProcess)
     {
         SNINativeManagedWrapperX64.SNIServerEnumClose(packet);
     }
     else
     {
         SNINativeManagedWrapperX86.SNIServerEnumClose(packet);
     }
 }
예제 #6
0
 private static uint SNIOpenWrapper(
     [In] ref Sni_Consumer_Info pConsumerInfo,
     [MarshalAs(UnmanagedType.LPWStr)] string szConnect,
     [In] SNIHandle pConn,
     out IntPtr ppConn,
     [MarshalAs(UnmanagedType.Bool)] bool fSync)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIOpenWrapper(ref pConsumerInfo, szConnect, pConn, out ppConn, fSync) :
            SNINativeManagedWrapperX86.SNIOpenWrapper(ref pConsumerInfo, szConnect, pConn, out ppConn, fSync));
 }
 internal static void UnregisterTraceProvider()
 {
     if (s_is64bitProcess)
     {
         SNINativeManagedWrapperX64.UnregisterTraceProviderWrapper();
     }
     else
     {
         SNINativeManagedWrapperX86.UnregisterTraceProviderWrapper();
     }
 }
예제 #8
0
 private static uint SNIOpenWrapper(
     [In] ref Sni_Consumer_Info pConsumerInfo,
     [MarshalAs(UnmanagedType.LPWStr)] string szConnect,
     [In] SNIHandle pConn,
     out IntPtr ppConn,
     [MarshalAs(UnmanagedType.Bool)] bool fSync,
     SqlConnectionIPAddressPreference ipPreference,
     [In] ref SNI_DNSCache_Info pDNSCachedInfo)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIOpenWrapper(ref pConsumerInfo, szConnect, pConn, out ppConn, fSync, ipPreference, ref pDNSCachedInfo) :
            SNINativeManagedWrapperX86.SNIOpenWrapper(ref pConsumerInfo, szConnect, pConn, out ppConn, fSync, ipPreference, ref pDNSCachedInfo));
 }
 internal static bool RegisterTraceProvider(int eventKeyword)
 {
     // Registers the TraceLogging provider, enabling it to generate events.
     // Return true if enabled, otherwise false.
     if (s_is64bitProcess)
     {
         return(SNINativeManagedWrapperX64.RegisterTraceProviderWrapper(eventKeyword));
     }
     else
     {
         return(SNINativeManagedWrapperX86.RegisterTraceProviderWrapper(eventKeyword));
     }
 }
예제 #10
0
 private static unsafe uint SNISecGenClientContextWrapper(
     [In] SNIHandle pConn,
     [In, Out] byte[] pIn,
     uint cbIn,
     [In, Out] byte[] pOut,
     [In] ref uint pcbOut,
     [MarshalAsAttribute(UnmanagedType.Bool)] out bool pfDone,
     byte *szServerInfo,
     uint cbServerInfo,
     [MarshalAsAttribute(UnmanagedType.LPWStr)] string pwszUserName,
     [MarshalAsAttribute(UnmanagedType.LPWStr)] string pwszPassword)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNISecGenClientContextWrapper(pConn, pIn, cbIn, pOut, ref pcbOut, out pfDone, szServerInfo, cbServerInfo, pwszUserName, pwszPassword) :
            SNINativeManagedWrapperX86.SNISecGenClientContextWrapper(pConn, pIn, cbIn, pOut, ref pcbOut, out pfDone, szServerInfo, cbServerInfo, pwszUserName, pwszPassword));
 }
예제 #11
0
 private static uint SNIPacketGetDataWrapper([In] IntPtr packet, [In, Out] byte[] readBuffer, uint readBufferLength, out uint dataSize)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIPacketGetDataWrapper(packet, readBuffer, readBufferLength, out dataSize) :
            SNINativeManagedWrapperX86.SNIPacketGetDataWrapper(packet, readBuffer, readBufferLength, out dataSize));
 }
예제 #12
0
 internal static uint SNIQueryInfo(QTypes QType, ref IntPtr pbQInfo)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIQueryInfo(QType, ref pbQInfo) :
            SNINativeManagedWrapperX86.SNIQueryInfo(QType, ref pbQInfo));
 }
예제 #13
0
 private static IntPtr SNIPacketAllocateWrapper([In] SafeHandle pConn, IOType IOType)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIPacketAllocateWrapper(pConn, IOType) :
            SNINativeManagedWrapperX86.SNIPacketAllocateWrapper(pConn, IOType));
 }
예제 #14
0
 private static uint SNIInitialize([In] IntPtr pmo)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIInitialize(pmo) :
            SNINativeManagedWrapperX86.SNIInitialize(pmo));
 }
예제 #15
0
 private static uint SNIOpenSyncExWrapper(ref SNI_CLIENT_CONSUMER_INFO pClientConsumerInfo, out IntPtr ppConn)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIOpenSyncExWrapper(ref pClientConsumerInfo, out ppConn) :
            SNINativeManagedWrapperX86.SNIOpenSyncExWrapper(ref pClientConsumerInfo, out ppConn));
 }
예제 #16
0
 internal static uint SNISecInitPackage(ref uint pcbMaxToken)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNISecInitPackage(ref pcbMaxToken) :
            SNINativeManagedWrapperX86.SNISecInitPackage(ref pcbMaxToken));
 }
예제 #17
0
 private static uint SNIGetInfoWrapper([In] SNIHandle pConn, SNINativeMethodWrapper.QTypes QType, out ProviderEnum provNum)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIGetInfoWrapper(pConn, QType, out provNum) :
            SNINativeManagedWrapperX86.SNIGetInfoWrapper(pConn, QType, out provNum));
 }
예제 #18
0
 private static uint SNIGetInfoWrapper([In] SNIHandle pConn, SNINativeMethodWrapper.QTypes QType, [MarshalAs(UnmanagedType.Bool)] out bool pbQInfo)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIGetInfoWrapper(pConn, QType, out pbQInfo) :
            SNINativeManagedWrapperX86.SNIGetInfoWrapper(pConn, QType, out pbQInfo));
 }
예제 #19
0
 private static uint SNIGetInfoWrapper([In] SNIHandle pConn, SNINativeMethodWrapper.QTypes QType, ref IntPtr pbQInfo)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIGetInfoWrapper(pConn, QType, ref pbQInfo) :
            SNINativeManagedWrapperX86.SNIGetInfoWrapper(pConn, QType, ref pbQInfo));
 }
예제 #20
0
 internal static uint SNIReadSyncOverAsync(SNIHandle pConn, ref IntPtr ppNewPacket, int timeout)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIReadSyncOverAsync(pConn, ref ppNewPacket, timeout) :
            SNINativeManagedWrapperX86.SNIReadSyncOverAsync(pConn, ref ppNewPacket, timeout));
 }
예제 #21
0
 private static uint GetSniMaxComposedSpnLength()
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.GetSniMaxComposedSpnLength() :
            SNINativeManagedWrapperX86.GetSniMaxComposedSpnLength());
 }
예제 #22
0
 private static uint SNIWriteSyncOverAsync(SNIHandle pConn, [In] SNIPacket pPacket)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIWriteSyncOverAsync(pConn, pPacket) :
            SNINativeManagedWrapperX86.SNIWriteSyncOverAsync(pConn, pPacket));
 }
예제 #23
0
 internal static uint SNITerminate()
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNITerminate() :
            SNINativeManagedWrapperX86.SNITerminate());
 }
예제 #24
0
 internal static uint SNISetInfo(SNIHandle pConn, QTypes QType, [In] ref uint pbQInfo)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNISetInfo(pConn, QType, ref pbQInfo) :
            SNINativeManagedWrapperX86.SNISetInfo(pConn, QType, ref pbQInfo));
 }
예제 #25
0
 internal static uint SNIClose(IntPtr pConn)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIClose(pConn) :
            SNINativeManagedWrapperX86.SNIClose(pConn));
 }
예제 #26
0
 private static uint SNIGetPeerAddrStrWrapper([In] SNIHandle pConn, int bufferSize, StringBuilder addrBuffer, out uint addrLen)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIGetPeerAddrStrWrapper(pConn, bufferSize, addrBuffer, out addrLen) :
            SNINativeManagedWrapperX86.SNIGetPeerAddrStrWrapper(pConn, bufferSize, addrBuffer, out addrLen));
 }
예제 #27
0
 internal static uint SNIWaitForSSLHandshakeToComplete([In] SNIHandle pConn, int dwMilliseconds, out uint pProtocolVersion)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIWaitForSSLHandshakeToComplete(pConn, dwMilliseconds, out pProtocolVersion) :
            SNINativeManagedWrapperX86.SNIWaitForSSLHandshakeToComplete(pConn, dwMilliseconds, out pProtocolVersion));
 }
예제 #28
0
 internal static uint SNIRemoveProvider(SNIHandle pConn, ProviderEnum ProvNum)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIRemoveProvider(pConn, ProvNum) :
            SNINativeManagedWrapperX86.SNIRemoveProvider(pConn, ProvNum));
 }
예제 #29
0
 private static IntPtr SNIClientCertificateFallbackWrapper(IntPtr pCallbackContext)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.SNIClientCertificateFallbackWrapper(pCallbackContext) :
            SNINativeManagedWrapperX86.SNIClientCertificateFallbackWrapper(pCallbackContext));
 }
예제 #30
0
 internal static uint UnmanagedIsTokenRestricted([In] IntPtr token, [MarshalAs(UnmanagedType.Bool)] out bool isRestricted)
 {
     return(s_is64bitProcess ?
            SNINativeManagedWrapperX64.UnmanagedIsTokenRestricted(token, out isRestricted) :
            SNINativeManagedWrapperX86.UnmanagedIsTokenRestricted(token, out isRestricted));
 }