7#ifndef INCLUDED_OOTCPStreamDecoderAbstractionLayer_h
8#define INCLUDED_OOTCPStreamDecoderAbstractionLayer_h
10#ifndef OOTCPSTREAM_USE_COREFOUNDATION
11#define OOTCPSTREAM_USE_COREFOUNDATION 0
14#if OOTCPSTREAM_USE_COREFOUNDATION
16#include <CoreFoundation/CoreFoundation.h>
17#import "JAAutoreleasePool.h"
20#define OOALRelease(object) CFRelease(object)
22#define OOTypeDescription(object) JAAutorelease(CFCopyTypeIDDescription(CFGetTypeID(object)))
27#define OOALIsString(object) (CFGetTypeID(object) == CFStringGetTypeID())
29#define OOALSTR(str) CFSTR(str)
31#define OOALStringCreateWithFormatAndArguments(format, args) CFStringCreateWithFormatAndArguments(kCFAllocatorDefault, NULL, format, args)
36#define OOALIsDictionary(object) (CFGetTypeID(object) == CFDictionaryGetTypeID())
38#define OOALDictionaryGetValue(dictionary, key) CFDictionaryGetValue(dictionary, key)
44#define OOALIsData(object) (CFGetTypeID(object) == CFDataGetTypeID())
46#define OOALDataCreateMutable(capacity) CFDataCreateMutable(kCFAllocatorDefault, capacity)
48#define OOALMutableDataAppendBytes(data, bytes, length) CFDataAppendBytes(data, bytes, length)
50#define OOALDataGetBytePtr(data) CFDataGetBytePtr(data)
51#define OOALDataGetLength(data) CFDataGetLength(data)
57#define OOALCreateAutoreleasePool() JACreateAutoreleasePool()
58#define OOALDestroyAutoreleasePool(pool) JADestroyAutoreleasePool(pool)
62#define OOALPropertyListFromData(data, errStr) JAAutorelease(CFPropertyListCreateFromXMLData(kCFAllocatorDefault, data, kCFPropertyListImmutable, errStr))
73#import <Foundation/Foundation.h>
83#define OOALSTR(x) @""x
96#define OOALSTR(string) OOALGetConstantString("" string "")
117#define OOALDestroyAutoreleasePool(pool) OOALRelease(pool)
OOALStringRef OOTypeDescription(OOALObjectRef object)
bool OOALIsDictionary(OOALObjectRef object)
OOALStringRef OOALStringCreateWithFormatAndArguments(OOALStringRef format, va_list args)
const struct NSAutoreleasePool * OOALAutoreleasePoolRef
void OOALMutableDataAppendBytes(OOALMutableDataRef data, const void *bytes, size_t length)
const void * OOALDataGetBytePtr(OOALDataRef data)
const struct NSString * OOALStringRef
size_t OOALDataGetLength(OOALDataRef data)
const void * OOALObjectRef
OOALObjectRef OOALDictionaryGetValue(OOALDictionaryRef dictionary, OOALObjectRef key)
bool OOALIsData(OOALObjectRef object)
OOALStringRef OOALGetConstantString(const char *string)
const struct NSDictionary * OOALDictionaryRef
bool OOALIsString(OOALObjectRef object)
OOALAutoreleasePoolRef OOALCreateAutoreleasePool(void)
struct NSData * OOALMutableDataRef
OOALMutableDataRef OOALDataCreateMutable(size_t capacity)
void OOALRelease(OOALObjectRef object)
OOALObjectRef OOALPropertyListFromData(OOALMutableDataRef data, OOALStringRef *errStr)
const struct NSData * OOALDataRef