00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00015 
00016 
00017 
00018 
00019 
00020 
00021 
00022 
00023 
00024 
00025 
00026 
00027 
00028 
00029 
00030 
00031 
00032 
00033 
00034 
00035 
00036 
00037 
00038 
00039 
00040 
00041 
00042 
00043 #if !defined(PAIR_OL_GUARD)
00044 #define PAIR_OL_GUARD
00045 
00046 #include <ObjectiveLib/ObjectBase.h>
00047 
00055 @interface OLPair :
00056 #if defined(OL_NO_OPENSTEP)
00057     Object <OLStreamable>
00058 #else
00059     NSObject <OLStreamable, NSCopying, NSCoding>
00060 #endif
00061 {
00062 @protected
00066     id      first;
00067 
00071     id      second;
00072 }
00073 
00077 
00078 #if !defined(OL_NO_OPENSTEP)
00079 
00089 - (id) initWithCoder: (NSCoder*)decoder;
00090 #endif
00091 
00099 - (id) initWithFirst: (id)f second: (id)s;
00100 
00101 - (id) initWithObjectInStream: (OLObjectInStream*)stream;
00102 
00106 #if defined(OL_NO_OPENSTEP)
00107 - (id) free;
00108 #else
00109 - (void) dealloc;
00110 #endif
00111 
00112 
00123 - (int) compare: (id)other;
00124 #if defined(OL_NO_OPENSTEP)
00125 
00130 - (id) copy;
00131 #else
00132 
00138 - (id) copyWithZone: (NSZone*)zone;
00139 #endif
00140 
00141 #if !defined(OL_NO_OPENSTEP)
00142 
00148 - (void) encodeWithCoder: (NSCoder*)encoder;
00149 #endif
00150 
00156 - (id) first;
00157 
00167 - (BOOL) isEqual: (id)object;
00168 
00174 - (id) second;
00175 
00181 - (void) setFirst: (id)f;
00182 
00188 - (void) setSecond: (id)s;
00189 
00190 - (void) writeSelfToStream: (OLObjectOutStream*)stream;
00191 
00192 @end
00193 
00194 #endif