([NSDate -copyWithZone:]): New method.

([NSDate -descriptionWithCalendarFormat:timeZone:]): Uncommented.
([NSDate -dateWithCalendarFormat:timeZone:]): Uncommented.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@534 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
mccallum 1995-08-08 15:46:04 +00:00
parent e20a78619b
commit 7cd03134f5

View file

@ -82,6 +82,12 @@
@implementation NSDate @implementation NSDate
- (id) copyWithZone: (NSZone*)zone
{
return [[[NSConcreteDate class] allocWithZone:zone]
initWithTimeIntervalSinceReferenceDate:timeSinceReference];
}
// Getting current time // Getting current time
+ (NSTimeInterval) timeIntervalSinceReferenceDate + (NSTimeInterval) timeIntervalSinceReferenceDate
@ -178,13 +184,15 @@
} }
// Converting to NSCalendar // Converting to NSCalendar
#if 0
- (NSCalendarDate *) dateWithCalendarFormat: (NSString*)formatString - (NSCalendarDate *) dateWithCalendarFormat: (NSString*)formatString
timeZone: (NSTimeZone*)timeZone timeZone: (NSTimeZone*)timeZone
{ {
// Not done yet, NSCalendarDate doesn't exist yet! // Not done yet, NSCalendarDate doesn't exist yet!
[self notImplemented:_cmd];
return nil;
} }
#endif
// Representing dates // Representing dates
@ -202,13 +210,15 @@
strftime(buf, 64, "%Y-%m-%d %H:%M:%S", theTime); strftime(buf, 64, "%Y-%m-%d %H:%M:%S", theTime);
return [NSString stringWithCString: buf]; return [NSString stringWithCString: buf];
} }
#if 0
- (NSString*) descriptionWithCalendarFormat: (NSString*)format - (NSString*) descriptionWithCalendarFormat: (NSString*)format
timeZone: (NSTimeZone*)aTimeZone timeZone: (NSTimeZone*)aTimeZone
{ {
// Not done yet, no NSCalendarDate or NSTimeZone... // Not done yet, no NSCalendarDate or NSTimeZone...
[self notImplemented:_cmd];
return nil;
} }
#endif
// Adding and getting intervals // Adding and getting intervals