LibUsbDotNet 2.2.8
SubmitAsyncTransfer Method (buffer, offset, length, timeout, transferContext)
Library Reference ► LibUsbDotNet.Main ► UsbEndpointBase ► SubmitAsyncTransfer(IntPtr, Int32, Int32, Int32, UsbTransfer%)
|
Creates, fills and submits an asynchronous UsbTransfer context.
Declaration Syntax
C# | Visual Basic | Visual C++ |
public virtual ErrorCode SubmitAsyncTransfer( IntPtr buffer, int offset, int length, int timeout, out UsbTransfer transferContext )
Public Overridable Function SubmitAsyncTransfer ( _ buffer As IntPtr, _ offset As Integer, _ length As Integer, _ timeout As Integer, _ <OutAttribute> ByRef transferContext As UsbTransfer _ ) As ErrorCode
public: virtual ErrorCode SubmitAsyncTransfer( IntPtr buffer, int offset, int length, int timeout, [OutAttribute] UsbTransfer^% transferContext )
Parameters
- buffer (IntPtr)
- A caller-allocated buffer for the data that is transferred.
- offset (Int32)
- Position in buffer that transferring begins.
- length (Int32)
- Number of bytes, starting from thr offset parameter to transfer.
- timeout (Int32)
- Maximum time to wait for the transfer to complete.
- transferContext (UsbTransfer%)
- On Success, a new transfer context.
Return Value
Success if the transfer context was created and Submit()()()() succeeded.
Remarks
Note:This is a non-blocking asynchronous transfer function. This function returns immediately after the context is created and submitted.