Discuss this help topic in SecureBlackbox Forum

TElFTPSServer.OnDataReceive

TElFTPSServer     See also     


Filter: C#/Java  VB.NET  Pascal  C++  PHP  


This event is used to read data from the data channel.

Declaration

[C#/Java]
    event TSBReceiveEvent OnDataReceive;
    delegate void TSBReceiveEvent(object Sender, ref byte[] Buffer, int MaxSize, [out] ref int Written);

[VB.NET]
    Event OnDataReceive As TSBReceiveEvent
    Delegate Sub TSBReceiveEvent(ByVal Sender As Object, ByRef Buffer As Byte(), ByVal MaxSize As Integer, ByRef Written As Integer)

[Pascal]
    property OnDataReceive : TSBReceiveEvent;
    TSBReceiveEvent = procedure (Sender: TObject; Buffer : Pointer; MaxSize : LongInt; out Written : LongInt) of object;

[C++]
    void get_OnDataReceive(TSBReceiveEvent &pMethodOutResult, void * &pDataOutResult);
    void set_OnDataReceive(TSBReceiveEvent pMethodValue, void * pDataValue);
    typedef void (SB_CALLBACK *TSBReceiveEvent)(void * _ObjectData, TObjectHandle Sender, void * Buffer, int32_t MaxSize, int32_t &Written);

[PHP]
    TSBReceiveEvent|callable|NULL get_OnDataReceive()
    void set_OnDataReceive(TSBReceiveEvent|callable|NULL $Value)
    callable TSBReceiveEvent(TObject $Sender, TSBPointer|NULL $Buffer, integer $MaxSize, integer &$Written)

Parameters

  • Buffer - the buffer that should be filled with data which were read from the socket by application.
  • MaxSize - the length of the buffer. Specifies the maximum number of bytes that can be written to the buffer.
  • Written - the amount of data that was placed to the buffer.

Description

    This event is fired by TElFTPSServer when it needs to read some data from the socket. Usually this is caused by the call to DataAvailable. The application should fill the Buffer with the amount of data not more than MaxSize bytes and return the number of bytes written in Written parameter.

See also:     DataAvailable     OnDataSend    

Discuss this help topic in SecureBlackbox Forum