Skip to content

Commit

Permalink
more basemodel zhuzhings.. Jerenum, etc.
Browse files Browse the repository at this point in the history
  • Loading branch information
mralexgray committed Apr 10, 2013
1 parent de8861a commit cc96035
Show file tree
Hide file tree
Showing 15 changed files with 1,089 additions and 1,076 deletions.
5 changes: 4 additions & 1 deletion .gitmodules
Expand Up @@ -170,4 +170,7 @@
path = Frameworks/NoodleKit
url = https://github.com/mralexgray/NoodleKit.git
ignore = dirty


[submodule "AtoZ/Core/JREnum"]
path = AtoZ/Core/JREnum
url = https://github.com/mralexgray/JREnum.git
232 changes: 127 additions & 105 deletions AtoZ/AtoZ-Framework.pch
@@ -1,81 +1,86 @@
#import <libkern/OSAtomic.h>
#import <sys/xattr.h>
#import <sys/sysctl.h>
#import <unistd.h>
#import <dirent.h>
#import <sys/stat.h>
#import <Foundation/Foundation.h>
#ifdef __OBJC__
#import <Availability.h>

#import <TargetConditionals.h>
#if TARGET_OS_IPHONE
#if __IPHONE_OS_VERSION_MIN_REQUIRED
#import <SystemConfiguration/SystemConfiguration.h>
#import <MobileCoreServices/MobileCoreServices.h>
#import <sys/xattr.h>
#else
#import <SystemConfiguration/SystemConfiguration.h>
#import <CoreServices/CoreServices.h>
#endif

#import <TargetConditionals.h>
#if TARGET_OS_IPHONE
#import <MobileCoreServices/MobileCoreServices.h>
#import <sys/xattr.h>
#else
#import <CoreServices/CoreServices.h>
#endif


#define NSLog(fmt...) _AZColorLog(nil,__FILE__,__LINE__,__PRETTY_FUNCTION__,fmt)

#import <xpc/xpc.h>
#import <Cocoa/Cocoa.h>
#include <pwd.h>
#include <sys/types.h>
#import <objc/message.h>
#import <objc/runtime.h>
#import <Quartz/Quartz.h>
#import <Carbon/Carbon.h>
#import <unistd.h>
#import <libkern/OSAtomic.h>
#import <sys/time.h>
#import <sys/xattr.h>
#import <sys/sysctl.h>
#import <sys/stat.h>
#import <dirent.h>
#import <xpc/xpc.h>
#import <Cocoa/Cocoa.h>
#import <AppKit/AppKit.h>
#import <Carbon/Carbon.h>
#import <Quartz/Quartz.h>
#import <Python/Python.h>
#import <Security/Security.h>
#import <QuartzCore/QuartzCore.h>
#import <Foundation/Foundation.h>
#import <QuartzCore/QuartzCore.h>
#import <AudioToolbox/AudioToolbox.h>
#import <CoreServices/CoreServices.h>
#import <AVFoundation/AVFoundation.h>
#import <CoreFoundation/CoreFoundation.h>
#import <ApplicationServices/ApplicationServices.h>
#endif

/*
#undef ah_retain #undef ah_dealloc
#undef ah_autorelease autorelease
#undef ah_dealloc dealloc
*/

#if __has_feature(objc_arc) // ARC Helper Version 2.2
#define ah_retain self
#define ah_release self
#define ah_autorelease self

#ifndef ah_retain
#if __has_feature(objc_arc)
#define ah_retain self
#define ah_dealloc self
#define release self
#define autorelease self
#else
#define ah_retain retain
#define ah_dealloc dealloc
#define __bridge
#endif
#endif

// Weak delegate support
#define release self // Is this right? Why's mine different?
#define autorelease self // But shit hits fan without.

#ifndef ah_weak
#import <Availability.h>
#if (__has_feature(objc_arc)) && \
((defined __IPHONE_OS_VERSION_MIN_REQUIRED && \
__IPHONE_OS_VERSION_MIN_REQUIRED >= __IPHONE_5_0) || \
(defined __MAC_OS_X_VERSION_MIN_REQUIRED && \
__MAC_OS_X_VERSION_MIN_REQUIRED > __MAC_10_7))
#define ah_weak weak
#define __ah_weak __weak
#define ah_dealloc self
#else
#define ah_weak unsafe_unretained
#define __ah_weak __unsafe_unretained
#define ah_retain retain
#define ah_release release
#define ah_autorelease autorelease
#define ah_dealloc dealloc
#undef __bridge
#define __bridge
#undef __bridge_transfer
#define __bridge_transfer
#endif
#if !__has_feature(objc_arc_weak) // Weak reference support
#undef ah_weak
#define ah_weak unsafe_unretained
#undef __ah_weak
#define __ah_weak __unsafe_unretained
#endif

// ARC Helper ends
#undef ah_weak_delegate // Weak delegate support
#undef __ah_weak_delegate
#if __has_feature(objc_arc_weak) && \
(!(defined __MAC_OS_X_VERSION_MIN_REQUIRED) ||\
__MAC_OS_X_VERSION_MIN_REQUIRED >= __MAC_10_8)
#define ah_weak_delegate weak
#define __ah_weak_delegate __weak
#else
#define ah_weak_delegate unsafe_unretained
#define __ah_weak_delegate __unsafe_unretained
#endif // ARC Helper ends

// Prefix header for all source files of the 'AtoZ' target in the 'AtoZ' project

// ARC Helper Version 1.3.1
// Created by Nick Lockwood on 05/01/2012. Copyright 2012 Charcoal Design
Expand All @@ -99,79 +104,30 @@ __MAC_OS_X_VERSION_MIN_REQUIRED > __MAC_10_7))
#endif
#endif

// ARC Helper ends

#ifndef ah_retain
#if __has_feature(objc_arc)
#define ah_retain self
#define ah_dealloc self
#define release self
#define autorelease self
#else
#define ah_retain retain
#define ah_dealloc dealloc
#define __bridge
#endif
#endif

// ARC Helper ends

#ifdef __OBJC__

//static inline BOOL isEmpty(id thing);
// return thing ?: [thing respondsToSelector:@selector(length)] && [ (NSD*)thing length]
// ?: [thing respondsToSelector:@selector(count) ] && [ (NSA*)thing count ]
// NO;
//}

// StringConsts.h
//#ifdef SYNTHESIZE_CONSTS
//# define STR_CONST(name, value) NSString* const name = @ value
//#else
//# define STR_CONST(name, value) extern NSString* const name
//#endif

//The in my .h/.m pair where I want to define the constant I do the following:
// myfile.h
//#import <StringConsts.h>

//STR_CONST(MyConst, "Lorem Ipsum");
//STR_CONST(MyOtherConst, "Hello world");

// myfile.m
//#define SYNTHESIZE_CONSTS
//#import "myfile.h"
//#undef SYNTHESIZE_CONSTS



//#define EXCLUDE_STUB_PROTOTYPES 1
//#import <PLWeakCompatibility/PLWeakCompatibilityStubs.h>
#import <Rebel/Rebel.h>
#import <FunSize/FunSize.h>
#import <DrawKit/DKDrawKit.h>
//#import <MapKit/MapKit.h>
//
//#import <Nu/Nu.h>
#import <KSHTMLWriterFramework/KSHTMLWriterFramework.h>
#import <Zangetsu/Zangetsu.h>
#import <BlocksKit/BlocksKit.h>
#import <CocoaPuffs/CocoaPuffs.h>
#import <AtoZBezierPath/AtoZBezierPath.h>
#import <AtoZAppKit/BGHUDAppKit.h>
//#import <MapKit/MapKit.h>
//#import <Nu/Nu.h>
//#import <Lumberjack/Lumberjack.h>

//#import <XPCKit/XPCKit.h>
//#import <SNRHUDKit/SNRHUDKit.h>
//#import <NanoStore/NanoStore.h>
//#import <AtoZUI/AtoZUI.h>

//#import <libatoz.h>

//#import "BaseModel.h"
//#import "AutoCoding.h"
//#import "HRCoder.h"


#import "AtoZUmbrella.h"
#import "AtoZGeometry.h"
#import "AtoZFunctions.h"
Expand All @@ -184,7 +140,8 @@ __MAC_OS_X_VERSION_MIN_REQUIRED > __MAC_10_7))
#import "SNRHUDTextView.h"
#import "SNRHUDWindow.h"

#endif
#endif // END AZFRAMEWORK PCH #ifdef __OBJC__


//#import "NSObject+AutoMagicCoding.h"
//#import "AZSizer.h"
Expand Down Expand Up @@ -229,3 +186,68 @@ __MAC_OS_X_VERSION_MIN_REQUIRED > __MAC_10_7))


//#endif
//static inline BOOL isEmpty(id thing);
// return thing ?: [thing respondsToSelector:@selector(length)] && [ (NSD*)thing length]
// ?: [thing respondsToSelector:@selector(count) ] && [ (NSA*)thing count ]
// NO;
//}

// StringConsts.h
//#ifdef SYNTHESIZE_CONSTS
//# define STR_CONST(name, value) NSString* const name = @ value
//#else
//# define STR_CONST(name, value) extern NSString* const name
//#endif

//The in my .h/.m pair where I want to define the constant I do the following:
// myfile.h
//#import <StringConsts.h>

//STR_CONST(MyConst, "Lorem Ipsum");
//STR_CONST(MyOtherConst, "Hello world");

// myfile.m
//#define SYNTHESIZE_CONSTS
//#import "myfile.h"
//#undef SYNTHESIZE_CONSTS



#ifndef _OmniBase_assertions_h_
#define _OmniBase_assertions_h_
//#import <OmniBase/FrameworkDefines.h>
#import <objc/objc.h>

//#if defined(DEBUG) || defined(OMNI_FORCE_ASSERTIONS)
//#define OMNI_ASSERTIONS_ON
//#endif

// This allows you to turn off assertions when debugging
//#if defined(OMNI_FORCE_ASSERTIONS_OFF)
#undef OMNI_ASSERTIONS_ON
//#warning Forcing assertions off!
//#endif


// Make sure that we don't accidentally use the ASSERT macro instead of OBASSERT
#ifdef ASSERT
#undef ASSERT
#endif
typedef void (*OBAssertionFailureHandler)(const char *type, const char *expression, const char *file, unsigned int lineNumber);
#if defined(OMNI_ASSERTIONS_ON)
OmniBase_EXTERN void OBSetAssertionFailureHandler(OBAssertionFailureHandler handler);
OmniBase_EXTERN void OBAssertFailed(const char *type, const char *expression, const char *file, unsigned int lineNumber);
#define OBPRECONDITION(expression) do{if(!(expression))OBAssertFailed("PRECONDITION", #expression,__FILE__,__LINE__);}while(NO)
#define OBPOSTCONDITION(expression) do{if(!(expression))OBAssertFailed("POSTCONDITION",#expression,__FILE__,__LINE__);}while(NO)
#define OBINVARIANT(expression) do{if(!(expression))OBAssertFailed("INVARIANT", #expression,__FILE__,__LINE__);}while(NO)
#define OBASSERT(expression) do{if(!(expression))OBAssertFailed("ASSERT", #expression,__FILE__,__LINE__);}while(NO)
#define OBASSERT_NOT_REACHED(reason)do{ OBAssertFailed("NOTREACHED", reason,__FILE__,__LINE__);}while(NO)
#else // else insert blank lines into the code
#define OBPRECONDITION(expression)
#define OBPOSTCONDITION(expression)
#define OBINVARIANT(expression)
#define OBASSERT(expression)
#define OBASSERT_NOT_REACHED(reason)
#endif
#endif // _OmniBase_assertions_h_

0 comments on commit cc96035

Please sign in to comment.