Files Transfer Protocol — sgcWebSockets | eSeGeCe

Files Transfer Protocol

Binary WebSocket transport for transferring files between connected clients with configurable packet sizes, authorization controls, and QoS delivery guarantees.

TsgcWSPClient_Files / TsgcWSPServer_Files

Chunked, resumable file transfer subprotocol with selectable QoS, configurable buffer size, and a save directory. Supports big files via per-fragment acknowledgement.

Component class

TsgcWSPClient_Files

Protocol

Chunked file transfer over a WebSocket channel

Platforms

Windows, macOS, Linux, iOS, Android

Edition

Professional / Enterprise

Drop the component, set a few properties, go

Set BufferSize, SaveDirectory, QoS.Level, then Subscribe and SendFile.

uses
  sgcWebSocket, sgcWebSocket_Protocols, sgcWebSocket_Types;

// --- Server ----------------------------------------------------
ServerFiles := TsgcWSPServer_Files.Create(nil);
ServerFiles.Server := WSServer;

// --- Client: chunked + resumable -------------------------------
ClientFiles := TsgcWSPClient_Files.Create(nil);
ClientFiles.Client := WSClient;
ClientFiles.Files.BufferSize    := 8192;
ClientFiles.Files.SaveDirectory := 'C:\inbox\';
ClientFiles.Files.QoS.Level     := qosLevel1;  // acknowledged delivery

ClientFiles.Subscribe('files');
ClientFiles.SendFile('C:\data\report.pdf');

What's inside

5 published properties, 4 methods, 19 events — pulled from the component reference.

Connection

Published properties: Client, Broker, Guid.

Messaging

Events: OnMessage, OnBinary, OnFragmented.

Lifecycle

Events: OnConnect, OnDisconnect, OnError.

Advanced

Methods: WriteData.

Diagnostics

Published properties: Version.

Files

Properties: Files.

Specifications & references

Authoritative sources for the protocols this component implements.

Documentation & Demos

Deep-link to the component reference, grab the ready-to-run demo project, and download the trial.

Demo Project — Demos\02.WebSocket_Protocols\02.Send_Receive_Files_Protocol Ready-to-run example project. Ships inside the sgcWebSockets package — download the trial below.
Technical Document (PDF) Features, quick start, code samples for Delphi, C++ Builder and .NET and primary-source references — this component only.
User Manual (PDF) Comprehensive manual covering every component in the library.
Best value: All-AccessEvery eSeGeCe product, Premium Support included, from €1,059/year.
See All-Access pricing

Ready to Transfer Files Over WebSocket?

Download the free trial and add file transfer support to your application.