ObjFW  Diff

Differences From Artifact [24104f796c]:

To Artifact [a9ea4a0db3]:


15
16
17
18
19
20
21

22
23
24
25
26
27
28
 */

#include <sys/types.h>

#import "OFObject.h"

@class OFString;


/**
 * \brief An exception indicating an object could not be allocated.
 *
 * This exception is preallocated, as if there's no memory, no exception can
 * be allocated of course. That's why you shouldn't and even can't deallocate
 * it.







>







15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
 */

#include <sys/types.h>

#import "OFObject.h"

@class OFString;
@class OFURL;

/**
 * \brief An exception indicating an object could not be allocated.
 *
 * This exception is preallocated, as if there's no memory, no exception can
 * be allocated of course. That's why you shouldn't and even can't deallocate
 * it.
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260





































 * \param prefix The prefix which is unbound
 * \return A new unbound namespace exception
 */
+ newWithClass: (Class)class_
	prefix: (OFString*)prefix;

/**
 * Initializes an already allocated unbound namespace failed exception
 *
 * \param class_ The class of the object which caused the exception
 * \param ns The namespace which is unbound
 * \return An initialized unbound namespace exception
 */
- initWithClass: (Class)class_
      namespace: (OFString*)ns;

/**
 * Initializes an already allocated unbound namespace failed exception
 *
 * \param class_ The class of the object which caused the exception
 * \param prefix The prefix which is unbound
 * \return An initialized unbound namespace exception
 */
- initWithClass: (Class)class_
	 prefix: (OFString*)prefix;

/**
 * \return The unbound namespace
 */
- (OFString*)namespace;

/**
 * \return The unbound prefix
 */
- (OFString*)prefix;
@end












































|









|


















>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
 * \param prefix The prefix which is unbound
 * \return A new unbound namespace exception
 */
+ newWithClass: (Class)class_
	prefix: (OFString*)prefix;

/**
 * Initializes an already allocated unbound namespace exception
 *
 * \param class_ The class of the object which caused the exception
 * \param ns The namespace which is unbound
 * \return An initialized unbound namespace exception
 */
- initWithClass: (Class)class_
      namespace: (OFString*)ns;

/**
 * Initializes an already allocated unbound namespace exception
 *
 * \param class_ The class of the object which caused the exception
 * \param prefix The prefix which is unbound
 * \return An initialized unbound namespace exception
 */
- initWithClass: (Class)class_
	 prefix: (OFString*)prefix;

/**
 * \return The unbound namespace
 */
- (OFString*)namespace;

/**
 * \return The unbound prefix
 */
- (OFString*)prefix;
@end

/**
 * \brief An exception indicating that the protocol specified by the URL is not
 *	  supported.
 */
@interface OFUnsupportedProtocolException: OFException
{
	OFURL *URL;
}

#ifdef OF_HAVE_PROPERTIES
@property (readonly, nonatomic) OFURL *URL;
#endif

/**
 * \param class_ The class of the object which caused the exception
 * \param url The URL whose protocol is unsupported
 * \return A new unsupported protocol exception
 */
+ newWithClass: (Class)class_
	   URL: (OFURL*)url;

/**
 * Initializes an already allocated unsupported protocol exception
 *
 * \param class_ The class of the object which caused the exception
 * \param url The URL whose protocol is unsupported
 * \return An initialized unsupported protocol exception
 */
- initWithClass: (Class)class_
	    URL: (OFURL*)url;

/**
 * \return The URL whose protocol is unsupported
 */
- (OFURL*)URL;
@end