mirror of
https://github.com/BeyondDimension/SteamTools.git
synced 2026-10-19 07:01:35 +08:00
798355e342
新增反代脚本只对Steam内置浏览器生效的选项
155 lines
9.2 KiB
C#
155 lines
9.2 KiB
C#
// This file is automatically generated.
|
|
using System;
|
|
using System.Text;
|
|
using System.Runtime.InteropServices;
|
|
|
|
namespace Steam4NET
|
|
{
|
|
|
|
[StructLayout(LayoutKind.Sequential,Pack=4)]
|
|
public class ISteamHTTP002VTable
|
|
{
|
|
public IntPtr CreateHTTPRequest0;
|
|
public IntPtr SetHTTPRequestContextValue1;
|
|
public IntPtr SetHTTPRequestNetworkActivityTimeout2;
|
|
public IntPtr SetHTTPRequestHeaderValue3;
|
|
public IntPtr SetHTTPRequestGetOrPostParameter4;
|
|
public IntPtr SendHTTPRequest5;
|
|
public IntPtr SendHTTPRequestAndStreamResponse6;
|
|
public IntPtr DeferHTTPRequest7;
|
|
public IntPtr PrioritizeHTTPRequest8;
|
|
public IntPtr GetHTTPResponseHeaderSize9;
|
|
public IntPtr GetHTTPResponseHeaderValue10;
|
|
public IntPtr GetHTTPResponseBodySize11;
|
|
public IntPtr GetHTTPResponseBodyData12;
|
|
public IntPtr GetHTTPStreamingResponseBodyData13;
|
|
public IntPtr ReleaseHTTPRequest14;
|
|
public IntPtr GetHTTPDownloadProgressPct15;
|
|
public IntPtr SetHTTPRequestRawPostBody16;
|
|
private IntPtr DTorISteamHTTP00217;
|
|
};
|
|
|
|
[InteropHelp.InterfaceVersion("STEAMHTTP_INTERFACE_VERSION002")]
|
|
public class ISteamHTTP002 : InteropHelp.NativeWrapper<ISteamHTTP002VTable>
|
|
{
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate UInt32 NativeCreateHTTPRequestES( IntPtr thisptr, EHTTPMethod eHTTPRequestMethod, string pchAbsoluteURL );
|
|
public UInt32 CreateHTTPRequest( EHTTPMethod eHTTPRequestMethod, string pchAbsoluteURL )
|
|
{
|
|
return this.GetFunction<NativeCreateHTTPRequestES>( this.Functions.CreateHTTPRequest0 )( this.ObjectAddress, eHTTPRequestMethod, pchAbsoluteURL );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativeSetHTTPRequestContextValueUU( IntPtr thisptr, UInt32 hRequest, UInt64 ulContextValue );
|
|
public bool SetHTTPRequestContextValue( UInt32 hRequest, UInt64 ulContextValue )
|
|
{
|
|
return this.GetFunction<NativeSetHTTPRequestContextValueUU>( this.Functions.SetHTTPRequestContextValue1 )( this.ObjectAddress, hRequest, ulContextValue );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativeSetHTTPRequestNetworkActivityTimeoutUU( IntPtr thisptr, UInt32 hRequest, UInt32 unTimeoutSeconds );
|
|
public bool SetHTTPRequestNetworkActivityTimeout( UInt32 hRequest, UInt32 unTimeoutSeconds )
|
|
{
|
|
return this.GetFunction<NativeSetHTTPRequestNetworkActivityTimeoutUU>( this.Functions.SetHTTPRequestNetworkActivityTimeout2 )( this.ObjectAddress, hRequest, unTimeoutSeconds );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativeSetHTTPRequestHeaderValueUSS( IntPtr thisptr, UInt32 hRequest, string pchHeaderName, string pchHeaderValue );
|
|
public bool SetHTTPRequestHeaderValue( UInt32 hRequest, string pchHeaderName, string pchHeaderValue )
|
|
{
|
|
return this.GetFunction<NativeSetHTTPRequestHeaderValueUSS>( this.Functions.SetHTTPRequestHeaderValue3 )( this.ObjectAddress, hRequest, pchHeaderName, pchHeaderValue );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativeSetHTTPRequestGetOrPostParameterUSS( IntPtr thisptr, UInt32 hRequest, string pchParamName, string pchParamValue );
|
|
public bool SetHTTPRequestGetOrPostParameter( UInt32 hRequest, string pchParamName, string pchParamValue )
|
|
{
|
|
return this.GetFunction<NativeSetHTTPRequestGetOrPostParameterUSS>( this.Functions.SetHTTPRequestGetOrPostParameter4 )( this.ObjectAddress, hRequest, pchParamName, pchParamValue );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativeSendHTTPRequestUU( IntPtr thisptr, UInt32 hRequest, ref UInt64 pCallHandle );
|
|
public bool SendHTTPRequest( UInt32 hRequest, ref UInt64 pCallHandle )
|
|
{
|
|
return this.GetFunction<NativeSendHTTPRequestUU>( this.Functions.SendHTTPRequest5 )( this.ObjectAddress, hRequest, ref pCallHandle );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativeSendHTTPRequestAndStreamResponseUU( IntPtr thisptr, UInt32 hRequest, ref UInt64 pCallHandle );
|
|
public bool SendHTTPRequestAndStreamResponse( UInt32 hRequest, ref UInt64 pCallHandle )
|
|
{
|
|
return this.GetFunction<NativeSendHTTPRequestAndStreamResponseUU>( this.Functions.SendHTTPRequestAndStreamResponse6 )( this.ObjectAddress, hRequest, ref pCallHandle );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativeDeferHTTPRequestU( IntPtr thisptr, UInt32 hRequest );
|
|
public bool DeferHTTPRequest( UInt32 hRequest )
|
|
{
|
|
return this.GetFunction<NativeDeferHTTPRequestU>( this.Functions.DeferHTTPRequest7 )( this.ObjectAddress, hRequest );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativePrioritizeHTTPRequestU( IntPtr thisptr, UInt32 hRequest );
|
|
public bool PrioritizeHTTPRequest( UInt32 hRequest )
|
|
{
|
|
return this.GetFunction<NativePrioritizeHTTPRequestU>( this.Functions.PrioritizeHTTPRequest8 )( this.ObjectAddress, hRequest );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativeGetHTTPResponseHeaderSizeUSU( IntPtr thisptr, UInt32 hRequest, string pchHeaderName, ref UInt32 unResponseHeaderSize );
|
|
public bool GetHTTPResponseHeaderSize( UInt32 hRequest, string pchHeaderName, ref UInt32 unResponseHeaderSize )
|
|
{
|
|
return this.GetFunction<NativeGetHTTPResponseHeaderSizeUSU>( this.Functions.GetHTTPResponseHeaderSize9 )( this.ObjectAddress, hRequest, pchHeaderName, ref unResponseHeaderSize );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativeGetHTTPResponseHeaderValueUSBU( IntPtr thisptr, UInt32 hRequest, string pchHeaderName, Byte[] pHeaderValueBuffer, UInt32 unBufferSize );
|
|
public bool GetHTTPResponseHeaderValue( UInt32 hRequest, string pchHeaderName, Byte[] pHeaderValueBuffer )
|
|
{
|
|
return this.GetFunction<NativeGetHTTPResponseHeaderValueUSBU>( this.Functions.GetHTTPResponseHeaderValue10 )( this.ObjectAddress, hRequest, pchHeaderName, pHeaderValueBuffer, (UInt32) pHeaderValueBuffer.Length );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativeGetHTTPResponseBodySizeUU( IntPtr thisptr, UInt32 hRequest, ref UInt32 unBodySize );
|
|
public bool GetHTTPResponseBodySize( UInt32 hRequest, ref UInt32 unBodySize )
|
|
{
|
|
return this.GetFunction<NativeGetHTTPResponseBodySizeUU>( this.Functions.GetHTTPResponseBodySize11 )( this.ObjectAddress, hRequest, ref unBodySize );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativeGetHTTPResponseBodyDataUBU( IntPtr thisptr, UInt32 hRequest, Byte[] pBodyDataBuffer, UInt32 unBufferSize );
|
|
public bool GetHTTPResponseBodyData( UInt32 hRequest, Byte[] pBodyDataBuffer )
|
|
{
|
|
return this.GetFunction<NativeGetHTTPResponseBodyDataUBU>( this.Functions.GetHTTPResponseBodyData12 )( this.ObjectAddress, hRequest, pBodyDataBuffer, (UInt32) pBodyDataBuffer.Length );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativeGetHTTPStreamingResponseBodyDataUUBU( IntPtr thisptr, UInt32 hRequest, UInt32 cOffset, Byte[] pBodyDataBuffer, UInt32 unBufferSize );
|
|
public bool GetHTTPStreamingResponseBodyData( UInt32 hRequest, UInt32 cOffset, Byte[] pBodyDataBuffer )
|
|
{
|
|
return this.GetFunction<NativeGetHTTPStreamingResponseBodyDataUUBU>( this.Functions.GetHTTPStreamingResponseBodyData13 )( this.ObjectAddress, hRequest, cOffset, pBodyDataBuffer, (UInt32) pBodyDataBuffer.Length );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativeReleaseHTTPRequestU( IntPtr thisptr, UInt32 hRequest );
|
|
public bool ReleaseHTTPRequest( UInt32 hRequest )
|
|
{
|
|
return this.GetFunction<NativeReleaseHTTPRequestU>( this.Functions.ReleaseHTTPRequest14 )( this.ObjectAddress, hRequest );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativeGetHTTPDownloadProgressPctUF( IntPtr thisptr, UInt32 hRequest, ref float pflPercentOut );
|
|
public bool GetHTTPDownloadProgressPct( UInt32 hRequest, ref float pflPercentOut )
|
|
{
|
|
return this.GetFunction<NativeGetHTTPDownloadProgressPctUF>( this.Functions.GetHTTPDownloadProgressPct15 )( this.ObjectAddress, hRequest, ref pflPercentOut );
|
|
}
|
|
|
|
[return: MarshalAs(UnmanagedType.I1)]
|
|
[UnmanagedFunctionPointer(CallingConvention.ThisCall)] private delegate bool NativeSetHTTPRequestRawPostBodyUSBU( IntPtr thisptr, UInt32 hRequest, string pchContentType, Byte[] pubBody, UInt32 unBodyLen );
|
|
public bool SetHTTPRequestRawPostBody( UInt32 hRequest, string pchContentType, Byte[] pubBody )
|
|
{
|
|
return this.GetFunction<NativeSetHTTPRequestRawPostBodyUSBU>( this.Functions.SetHTTPRequestRawPostBody16 )( this.ObjectAddress, hRequest, pchContentType, pubBody, (UInt32) pubBody.Length );
|
|
}
|
|
|
|
};
|
|
}
|