alhc 0.2.2

Async Lightweight HTTP Client: A async http client library that using system library to reduce binary size if possible. (Currently under heavy development)
Documentation
#![allow(unused)]
#![allow(non_snake_case)]
#![allow(non_upper_case_globals)]

use core_foundation::{
    base::CFOptionFlags,
    mach_port::{CFAllocatorRef, CFIndex},
};

use super::cf_network::{CFReadStreamRef, CFWriteStreamRef};

pub type CFStreamEventType = CFOptionFlags;

pub const kCFStreamEventNone: CFStreamEventType = 0;
pub const kCFStreamEventOpenCompleted: CFStreamEventType = 1;
pub const kCFStreamEventHasBytesAvailable: CFStreamEventType = 2;
pub const kCFStreamEventCanAcceptBytes: CFStreamEventType = 4;
pub const kCFStreamEventErrorOccurred: CFStreamEventType = 8;
pub const kCFStreamEventEndEncountered: CFStreamEventType = 16;

#[link(name = "CoreFoundation", kind = "framework")]
extern "C" {
    pub fn CFStreamCreateBoundPair(
        alloc: CFAllocatorRef,
        readStream: *mut CFReadStreamRef,
        writeStream: *mut CFWriteStreamRef,
        transferBufferSize: CFIndex,
    );
}