ObjFW  Diff

Differences From Artifact [05eb8e5213]:

To Artifact [917291b8e9]:


51
52
53
54
55
56
57





58
59
60
61
62
63
64
			       stringValue: stringval] autorelease];
}

+ elementWithCharacters: (OFString*)chars
{
	return [[[self alloc] initWithCharacters: chars] autorelease];
}






+ elementWithComment: (OFString*)comment
{
	return [[[self alloc] initWithComment: comment] autorelease];
}

- init







>
>
>
>
>







51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
			       stringValue: stringval] autorelease];
}

+ elementWithCharacters: (OFString*)chars
{
	return [[[self alloc] initWithCharacters: chars] autorelease];
}

+ elementWithCDATA: (OFString*)cdata
{
	return [[[self alloc] initWithCDATA: cdata] autorelease];
}

+ elementWithComment: (OFString*)comment
{
	return [[[self alloc] initWithComment: comment] autorelease];
}

- init
117
118
119
120
121
122
123









124
125
126
127
128
129
130
{
	self = [super init];

	characters = [chars copy];

	return self;
}










- initWithComment: (OFString*)comment_
{
	self = [super init];

	comment = [comment_ copy];








>
>
>
>
>
>
>
>
>







122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
{
	self = [super init];

	characters = [chars copy];

	return self;
}

- initWithCDATA: (OFString*)cdata_
{
	self = [super init];

	cdata = [cdata_ copy];

	return self;
}

- initWithComment: (OFString*)comment_
{
	self = [super init];

	comment = [comment_ copy];

142
143
144
145
146
147
148




149
150
151
152
153
154
155
	OFString *ret, *tmp;
	OFMutableDictionary *all_namespaces;
	OFString *def_ns;

	if (characters != nil)
		return [characters stringByXMLEscaping];





	if (comment != nil) {
		OFMutableString *str;

		str = [OFMutableString stringWithString: @"<!--"];
		[str appendString: comment];
		[str appendString: @"-->"];








>
>
>
>







156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
	OFString *ret, *tmp;
	OFMutableDictionary *all_namespaces;
	OFString *def_ns;

	if (characters != nil)
		return [characters stringByXMLEscaping];

	if (cdata != nil)
		return [OFString stringWithFormat: @"<![CDATA[%s]]>",
						   [cdata cString]];

	if (comment != nil) {
		OFMutableString *str;

		str = [OFMutableString stringWithString: @"<!--"];
		[str appendString: comment];
		[str appendString: @"-->"];

429
430
431
432
433
434
435

436
437
438
439
440
{
	[name release];
	[namespace release];
	[attributes release];
	[namespaces release];
	[children release];
	[characters release];

	[comment release];

	[super dealloc];
}
@end







>





447
448
449
450
451
452
453
454
455
456
457
458
459
{
	[name release];
	[namespace release];
	[attributes release];
	[namespaces release];
	[children release];
	[characters release];
	[cdata release];
	[comment release];

	[super dealloc];
}
@end