1
/* $Id: GVGraphArguments.m,v 1.1 2008/02/11 12:34:07 glenlow Exp $ $Revision: 1.1 $ */
2
/* vim:set shiftwidth=4 ts=8: */
4
/**********************************************************
5
* This software is part of the graphviz package *
6
* http://www.graphviz.org/ *
8
* Copyright (c) 1994-2008 AT&T Corp. *
9
* and is licensed under the *
10
* Common Public License, Version 1.0 *
13
* Information and Software Systems Research *
14
* AT&T Research, Florham Park NJ *
15
**********************************************************/
17
#import "GVGraphArguments.h"
20
@implementation GVGraphArguments
22
- (id)initWithGraph:(GVGraph *)graph
24
if (self = [super init]) {
25
_graph = graph; /* no retain to avoid a retain cycle */
26
_arguments = [[NSMutableDictionary alloc] init];
33
return [_arguments count];
36
- (NSEnumerator *)keyEnumerator
38
return [_arguments keyEnumerator];
41
- (id)objectForKey:(id)aKey
43
return [_arguments objectForKey:aKey];
46
/* mutable dictionary primitive methods */
47
- (void)setObject:(id)anObject forKey:(id)aKey
49
[_arguments setObject:anObject forKey:aKey];
50
[_graph noteChanged:YES];
53
- (void)removeObjectForKey:(id)aKey
55
[_arguments removeObjectForKey:aKey];
56
[_graph noteChanged:YES];