Description
Adapts an owned Flyology TLS connection to the HTTP transport boundary.
Connection_Transport
type Connection_Transport
(Channel : not null access Flyology.IO.TLS.Connection)
is limited new Flyology.HTTP.Server.Transport with private;
Borrowing adapter. Channel remains the sole closing owner and must outlive this object and every HTTP.Server.Connection that refers to it. The discriminant is the borrowed TLS connection.
Receive
procedure Receive
(Item : in out Connection_Transport;
Data : out Ada.Streams.Stream_Element_Array;
Last : out Ada.Streams.Stream_Element_Offset;
Timeout : Duration;
Token : access Flyology.Cancellation.Token)
Forward a receive through the TLS connection.
Parameters
- Item
TLS HTTP transport
- Data
Destination buffer
- Last
Last decrypted byte or close sentinel
- Timeout
Operation deadline
- Token
Optional cancellation source
Send_All
procedure Send_All
(Item : in out Connection_Transport;
Data : Ada.Streams.Stream_Element_Array;
Timeout : Duration;
Token : access Flyology.Cancellation.Token)
Forward a complete send through the TLS connection.
Parameters
- Item
TLS HTTP transport
- Data
Source bytes
- Timeout
Operation deadline
- Token
Optional cancellation source