import { Callable, RoSocketAddress } from "..";
import * as net from "net";
/**
 * BrightScript Interface ifSocket
 * https://developer.roku.com/docs/references/brightscript/interfaces/ifsocket.md
 */
export declare class IfSocket {
    private readonly component;
    constructor(value: BrsSocket);
    /** Sends up to length bytes of data to the socket. */
    readonly send: Callable;
    /** Sends the whole string to the socket, if possible. */
    readonly sendStr: Callable;
    /** Reads data from the socket. */
    readonly receive: Callable;
    /** Reads data from the socket and stores the result in a string. */
    readonly receiveStr: Callable;
    /** Closes the socket */
    readonly close: Callable;
    /** Sets the address for the socket */
    readonly setAddress: Callable;
    /** Returns the port. */
    readonly getAddress: Callable;
    /** Sets the send-to address for the socket */
    readonly setSendToAddress: Callable;
    /** Gets the send-to address of the socket */
    readonly getSendToAddress: Callable;
    /** Returns the roSocketAddress for the remote address of the last message received via the receive() method. */
    readonly getReceivedFromAddress: Callable;
    /** Gets the count of the receive buffer */
    readonly getCountRcvBuf: Callable;
    /** Gets the count of the send buffer */
    readonly getCountSendBuf: Callable;
    /** Gets the status of the socket */
    readonly status: Callable;
}
export interface BrsSocket {
    readonly socket?: net.Socket;
    readonly identity: number;
    address?: RoSocketAddress;
    sendToAddress?: RoSocketAddress;
    ttl: number;
    reuseAddr: boolean;
    inline: boolean;
    sendBufferSize: number;
    recvBufferSize: number;
    sendTimeout: number;
    recvTimeout: number;
    errorCode: number;
}
/**
 * BrightScript Interface ifSocketAsync
 * https://developer.roku.com/docs/references/brightscript/interfaces/ifsocketasync.md
 */
export declare class IfSocketAsync {
    private readonly component;
    constructor(value: BrsSocket);
    /** Checks if the socket is readable */
    readonly isReadable: Callable;
    /** Checks if the socket is writable */
    readonly isWritable: Callable;
    /** Checks if the socket has an exception */
    readonly isException: Callable;
    /** Notifies when the socket is readable */
    readonly notifyReadable: Callable;
    /** Notifies when the socket is writable */
    readonly notifyWritable: Callable;
    /** Notifies when the socket has an exception */
    readonly notifyException: Callable;
    /** Gets the ID of the socket */
    readonly getID: Callable;
}
/**
 * BrightScript Interface ifSocketStatus
 * https://developer.roku.com/docs/references/brightscript/interfaces/ifsocketstatus.md
 */
export declare class IfSocketStatus {
    private readonly component;
    constructor(value: BrsSocket);
    /** Returns the EAGAIN status */
    readonly eAgain: Callable;
    /** Returns the EALREADY status */
    readonly eAlready: Callable;
    /** Returns the EBADADDR status */
    readonly eBadAddr: Callable;
    /** Returns the EDESTADDRREQ status */
    readonly eDestAddrReq: Callable;
    /** Returns the EHOSTUNREACH status */
    readonly eHostUnreach: Callable;
    /** Returns the EINVALID status */
    readonly eInvalid: Callable;
    /** Returns the EINPROGRESS status */
    readonly eInProgress: Callable;
    /** Returns the EWOULDBLOCK status */
    readonly eWouldBlock: Callable;
    /** Checks whether there are no errors (the error number is 0). */
    readonly eSuccess: Callable;
    /** Checks whether there is no hard error, but possibly one of the following async conditions: EAGAIN, EALREADY, EINPROGRESS, EWOULDBLOCK. */
    readonly eOK: Callable;
}
/**
 * BrightScript Interface ifSocketOption
 * https://developer.roku.com/docs/references/brightscript/interfaces/ifsocketoption.md
 */
export declare class IfSocketOption {
    private readonly component;
    constructor(value: BrsSocket);
    /** Returns the TTL (Time To Live) value for all IP packets on the socket. */
    readonly getTTL: Callable;
    /** Enables broadcast messages to be sent or received. */
    readonly setTTL: Callable;
    /** Checks whether an address that has been previously assigned can be immediately reassigned. */
    readonly getReuseAddr: Callable;
    /** Enables a previously assigned address to be immediately reassigned. */
    readonly setReuseAddr: Callable;
    /** Checks whether Out Of Bounds (OOB) data is read inline with regular data. */
    readonly getOOBInline: Callable;
    /** Enables Out Of Bounds (OOB) data to be read inline with regular data. */
    readonly setOOBInline: Callable;
    /** Returns the current send buffer size. */
    readonly getSendBuf: Callable;
    /** A flag indicating whether the send buffer size was successfully set. */
    readonly setSendBuf: Callable;
    /** Returns the current receive buffer size. */
    readonly getRcvBuf: Callable;
    /** A flag indicating whether the receive buffer size was successfully set. */
    readonly setRcvBuf: Callable;
    /** Returns the current send timeout. */
    readonly getSendTimeout: Callable;
    /** A flag indicating whether the send timeout was successfully set. */
    readonly setSendTimeout: Callable;
    /** Returns the current receive timeout. */
    readonly getReceiveTimeout: Callable;
    /** A flag indicating whether the receive timeout was successfully set. */
    readonly setReceiveTimeout: Callable;
}
