This is Program.m in view mode; [Download] [Up]
#import "Program.h"
@implementation Program
- (id)initWithTitle:(NSString *)aTitle
channel:(NSString *)aChannel
broadcastDate:(NSCalendarDate *)aDate
cost:(NSString *)aCost;
{
self = [super init];
if (!self) return nil;
[self setTitle:aTitle];
[self setChannel:aChannel];
[self setBroadcastDate:aDate];
[self setCost:aCost];
return self;
}
- (void)setTitle:(NSString *)value
{
[title autorelease];
title = [value copy];
return;
}
- (NSString *)title
{
return title;
}
- (void)setChannel:(NSString *)value
{
[channel autorelease];
channel = [value copy];
return;
}
- (NSString *)channel
{
return channel;
}
- (void)setBroadcastDate:(NSCalendarDate *)value
{
[broadcastDate autorelease];
broadcastDate = [value copy];
[broadcastDate setCalendarFormat:@"%B %d, %Y %I:%m %p"];
return;
}
- (NSCalendarDate *)broadcastDate
{
return broadcastDate;
}
- (void)setCost:(NSString *)value
{
[cost autorelease];
cost = [value copy];
return;
}
- (NSString *)cost
{
return cost;
}
- (void)dealloc
{
[broadcastDate autorelease];
[channel autorelease];
[cost autorelease];
[title autorelease];
[super dealloc];
return;
}
@end
These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.