ObjFW  Diff

Differences From Artifact [919c1667cd]:

To Artifact [54f5f7c2a3]:


18
19
20
21
22
23
24

25
26
27
28
29
30
31
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32







+








#include <stdlib.h>
#include <string.h>

#include <assert.h>

#import "OFXMLElement.h"
#import "OFXMLNode+Private.h"
#import "OFString.h"
#import "OFArray.h"
#import "OFDictionary.h"
#import "OFDataArray.h"
#import "OFXMLAttribute.h"
#import "OFXMLCharacters.h"
#import "OFXMLCDATA.h"
156
157
158
159
160
161
162
163

164
165
166
167
168
169
170
157
158
159
160
161
162
163

164
165
166
167
168
169
170
171







-
+







		      stringValue: nil];
}

- initWithName: (OFString *)name
     namespace: (OFString *)namespace
   stringValue: (OFString *)stringValue
{
	self = [super init];
	self = [super OF_init];

	@try {
		if (name == nil)
			@throw [OFInvalidArgumentException exception];

		_name = [name copy];
		_namespace = [namespace copy];
182
183
184
185
186
187
188
189

190
191
192
193
194
195
196
183
184
185
186
187
188
189

190
191
192
193
194
195
196
197







-
+







	}

	return self;
}

- initWithElement: (OFXMLElement *)element
{
	self = [super init];
	self = [super OF_init];

	@try {
		if (element == nil)
			@throw [OFInvalidArgumentException exception];

		_name = [element->_name copy];
		_namespace = [element->_namespace copy];
271
272
273
274
275
276
277
278

279
280
281
282
283
284
285
272
273
274
275
276
277
278

279
280
281
282
283
284
285
286







-
+








	return self;
}
#endif

- initWithSerialization: (OFXMLElement *)element
{
	self = [super init];
	self = [super OF_init];

	@try {
		void *pool = objc_autoreleasePoolPush();
		OFXMLElement *attributesElement, *namespacesElement;
		OFXMLElement *childrenElement;
		OFEnumerator *keyEnumerator, *objectEnumerator;
		id key, object;