/*
 * CDDL HEADER START
 *
 * The contents of this file are subject to the terms of the
 * Common Development and Distribution License (the "Licence").
 * You may not use this file except in compliance with the Licence.
 *
 * You can obtain a copy of the licence at RISC OS path @.^.LICENCE
 * or http://www.riscosdev.com/lanman98/LICENCE.CDDL
 * See the Licence for the specific language governing permissions
 * and limitations under the Licence.
 *
 * When distributing Covered Code, include this CDDL HEADER in each
 * file and include the Licence file.
 *
 * CDDL HEADER END
 *
 * Portions Copyright 2026 RISC OS Developments
 * SPDX-License-Identifier: CDDL-1.0
 */
#ifndef LM98_WEBIO_H
#define LM98_WEBIO_H
#include "webhttp.h"
typedef struct web_io_s {
    void *tcp;
    int tls;
    int forward_proxy;
    /* Bytes already read that belong to the next response on a kept connection. */
    unsigned char *ahead;
    int ahead_pos, ahead_end;
} web_io;
void WebIssue(const char *, ...);
void WebIOInit(web_io *);
void WebIOOpen(web_io *, const web_url *);
void WebIOClose(web_io *);
int WebIORead(web_io *, void *, int);
void WebIOWrite(web_io *, const void *, int);
#endif
