ObjFW  Check-in [1038191a03]

Overview
Comment:Restrict subclassing on more classes
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 1038191a031145cab0b0d59dedb075c0e24a6afbe5bc4fd0ecad0a8618bdfb7e
User & Date: js on 2022-09-12 08:52:20
Other Links: manifest | tags
Context
2022-09-12
14:34
Either restrict subclassing or reserve ivars check-in: c40a295629 user: js tags: trunk
08:52
Restrict subclassing on more classes check-in: 1038191a03 user: js tags: trunk
2022-09-11
11:46
Clean up OFWindowsRegistryKey API check-in: deb57aa653 user: js tags: trunk
Changes

Modified src/OFDNSQuery.h from [9c2a0f4bc6] to [b49f52a5a4].

21
22
23
24
25
26
27

28
29
30
31
32
33
34
35
36
37
38
39
40
@class OFString;

/**
 * @class OFDNSQuery OFDNSQuery.h ObjFW/OFDNSQuery.h
 *
 * @brief A class representing a DNS query.
 */

@interface OFDNSQuery: OFObject <OFCopying>
{
	OFString *_domainName;
	OFDNSClass _DNSClass;
	OFDNSRecordType _recordType;
	OF_RESERVE_IVARS(OFDNSQuery, 4)
}

/**
 * @brief The domain name of the query.
 */
@property (readonly, nonatomic) OFString *domainName;








>





<







21
22
23
24
25
26
27
28
29
30
31
32
33

34
35
36
37
38
39
40
@class OFString;

/**
 * @class OFDNSQuery OFDNSQuery.h ObjFW/OFDNSQuery.h
 *
 * @brief A class representing a DNS query.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFDNSQuery: OFObject <OFCopying>
{
	OFString *_domainName;
	OFDNSClass _DNSClass;
	OFDNSRecordType _recordType;

}

/**
 * @brief The domain name of the query.
 */
@property (readonly, nonatomic) OFString *domainName;

Modified src/OFDNSResponse.h from [12d5300b31] to [229f42ebfc].

25
26
27
28
29
30
31

32
33
34
35
36
37
38
39
40
41
42
43
44
    OF_KINDOF(OFDNSResourceRecord *)) *) *OFDNSResponseRecords;

/**
 * @class OFDNSResponse OFDNSResponse.h ObjFW/OFDNSResponse.h
 *
 * @brief A class storing a response from @ref OFDNSResolver.
 */

@interface OFDNSResponse: OFObject
{
	OFString *_domainName;
	OFDNSResponseRecords _answerRecords, _authorityRecords;
	OFDNSResponseRecords _additionalRecords;
	OF_RESERVE_IVARS(OFDNSResponse, 4)
}

/**
 * @brief The domain name of the response.
 */
@property (readonly, nonatomic) OFString *domainName;








>





<







25
26
27
28
29
30
31
32
33
34
35
36
37

38
39
40
41
42
43
44
    OF_KINDOF(OFDNSResourceRecord *)) *) *OFDNSResponseRecords;

/**
 * @class OFDNSResponse OFDNSResponse.h ObjFW/OFDNSResponse.h
 *
 * @brief A class storing a response from @ref OFDNSResolver.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFDNSResponse: OFObject
{
	OFString *_domainName;
	OFDNSResponseRecords _answerRecords, _authorityRecords;
	OFDNSResponseRecords _additionalRecords;

}

/**
 * @brief The domain name of the response.
 */
@property (readonly, nonatomic) OFString *domainName;

Modified src/OFHTTPClient.h from [4532ba7b26] to [ce9ecefc1d].

140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
 * @class OFHTTPClient OFHTTPClient.h ObjFW/OFHTTPClient.h
 *
 * @brief A class for performing HTTP requests.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFHTTPClient: OFObject
{
#ifdef OF_HTTPCLIENT_M
@public
#endif
	OFObject <OFHTTPClientDelegate> *_Nullable _delegate;
	bool _allowsInsecureRedirects, _inProgress;
	OFStream *_Nullable _stream;
	OFURL *_Nullable _lastURL;
	bool _lastWasHEAD;







|







140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
 * @class OFHTTPClient OFHTTPClient.h ObjFW/OFHTTPClient.h
 *
 * @brief A class for performing HTTP requests.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFHTTPClient: OFObject
{
#ifdef OF_HTTP_CLIENT_M
@public
#endif
	OFObject <OFHTTPClientDelegate> *_Nullable _delegate;
	bool _allowsInsecureRedirects, _inProgress;
	OFStream *_Nullable _stream;
	OFURL *_Nullable _lastURL;
	bool _lastWasHEAD;

Modified src/OFHTTPClient.m from [e665adf188] to [b95b6d2add].

9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
 *
 * Alternatively, it may be distributed under the terms of the GNU General
 * Public License, either version 2 or 3, which can be found in the file
 * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this
 * file.
 */

#define OF_HTTPCLIENT_M

#include "config.h"

#include <errno.h>
#include <string.h>

#import "OFHTTPClient.h"







|







9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
 *
 * Alternatively, it may be distributed under the terms of the GNU General
 * Public License, either version 2 or 3, which can be found in the file
 * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this
 * file.
 */

#define OF_HTTP_CLIENT_M

#include "config.h"

#include <errno.h>
#include <string.h>

#import "OFHTTPClient.h"

Modified src/OFHTTPCookie.h from [c915720e1d] to [534b416a4f].

25
26
27
28
29
30
31

32
33
34
35
36
37
38
39
40
41
42
43
44
45
@class OFURL;

/**
 * @class OFHTTPCookie OFHTTPCookie.h ObjFW/OFHTTPCookie.h
 *
 * @brief A class for storing and manipulating HTTP cookies.
 */

@interface OFHTTPCookie: OFObject <OFCopying>
{
	OFString *_name, *_value, *_domain, *_path;
	OFDate *_Nullable _expires;
	bool _secure, _HTTPOnly;
	OFMutableArray OF_GENERIC(OFString *) *_extensions;
	OF_RESERVE_IVARS(OFHTTPCookie, 4)
}

/**
 * @brief The name of the cookie.
 */
@property (copy, nonatomic) OFString *name;








>






<







25
26
27
28
29
30
31
32
33
34
35
36
37
38

39
40
41
42
43
44
45
@class OFURL;

/**
 * @class OFHTTPCookie OFHTTPCookie.h ObjFW/OFHTTPCookie.h
 *
 * @brief A class for storing and manipulating HTTP cookies.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFHTTPCookie: OFObject <OFCopying>
{
	OFString *_name, *_value, *_domain, *_path;
	OFDate *_Nullable _expires;
	bool _secure, _HTTPOnly;
	OFMutableArray OF_GENERIC(OFString *) *_extensions;

}

/**
 * @brief The name of the cookie.
 */
@property (copy, nonatomic) OFString *name;

Modified src/OFHTTPRequest.h from [cc3f0d316f] to [5a42fad5dc].

61
62
63
64
65
66
67

68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
} OFHTTPRequestProtocolVersion;

/**
 * @class OFHTTPRequest OFHTTPRequest.h ObjFW/OFHTTPRequest.h
 *
 * @brief A class for storing HTTP requests.
 */

@interface OFHTTPRequest: OFObject <OFCopying>
{
	OFURL *_URL;
	OFHTTPRequestMethod _method;
	OFHTTPRequestProtocolVersion _protocolVersion;
	OFDictionary OF_GENERIC(OFString *, OFString *) *_Nullable _headers;
	OFSocketAddress _remoteAddress;
	bool _hasRemoteAddress;
	OF_RESERVE_IVARS(OFHTTPRequest, 4)
}

/**
 * @brief The URL of the HTTP request.
 */
@property (copy, nonatomic) OFURL *URL;








>








<







61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76

77
78
79
80
81
82
83
} OFHTTPRequestProtocolVersion;

/**
 * @class OFHTTPRequest OFHTTPRequest.h ObjFW/OFHTTPRequest.h
 *
 * @brief A class for storing HTTP requests.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFHTTPRequest: OFObject <OFCopying>
{
	OFURL *_URL;
	OFHTTPRequestMethod _method;
	OFHTTPRequestProtocolVersion _protocolVersion;
	OFDictionary OF_GENERIC(OFString *, OFString *) *_Nullable _headers;
	OFSocketAddress _remoteAddress;
	bool _hasRemoteAddress;

}

/**
 * @brief The URL of the HTTP request.
 */
@property (copy, nonatomic) OFURL *URL;

Modified src/OFHTTPResponse.h from [b3d8087036] to [b0f5fe9413].

22
23
24
25
26
27
28



29
30
31
32
33
34
35
36
37
38
39
40
41
@class OFArray OF_GENERIC(ObjectType);

/**
 * @class OFHTTPResponse OFHTTPResponse.h ObjFW/OFHTTPResponse.h
 *
 * @brief A class for representing an HTTP request response as a stream.
 */



@interface OFHTTPResponse: OFStream
{
	OFHTTPRequestProtocolVersion _protocolVersion;
	short _statusCode;
	OFDictionary OF_GENERIC(OFString *, OFString *) *_headers;
	OF_RESERVE_IVARS(OFHTTPResponse, 4)
}

/**
 * @brief The protocol version of the HTTP request response.
 */
@property (nonatomic) OFHTTPRequestProtocolVersion protocolVersion;








>
>
>





<







22
23
24
25
26
27
28
29
30
31
32
33
34
35
36

37
38
39
40
41
42
43
@class OFArray OF_GENERIC(ObjectType);

/**
 * @class OFHTTPResponse OFHTTPResponse.h ObjFW/OFHTTPResponse.h
 *
 * @brief A class for representing an HTTP request response as a stream.
 */
#if !defined(OF_HTTP_CLIENT_M) && !defined(OF_HTTP_SERVER_M)
OF_SUBCLASSING_RESTRICTED
#endif
@interface OFHTTPResponse: OFStream
{
	OFHTTPRequestProtocolVersion _protocolVersion;
	short _statusCode;
	OFDictionary OF_GENERIC(OFString *, OFString *) *_headers;

}

/**
 * @brief The protocol version of the HTTP request response.
 */
@property (nonatomic) OFHTTPRequestProtocolVersion protocolVersion;

Modified src/OFHTTPServer.m from [de62217765] to [aa1c799693].

8
9
10
11
12
13
14


15
16
17
18
19
20
21
 * the packaging of this file.
 *
 * Alternatively, it may be distributed under the terms of the GNU General
 * Public License, either version 2 or 3, which can be found in the file
 * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this
 * file.
 */



#include "config.h"

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








>
>







8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
 * the packaging of this file.
 *
 * Alternatively, it may be distributed under the terms of the GNU General
 * Public License, either version 2 or 3, which can be found in the file
 * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this
 * file.
 */

#define OF_HTTP_SERVER_M

#include "config.h"

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

Modified src/OFInvocation.h from [324ba0dca4] to [ab7d9433d5].

22
23
24
25
26
27
28

29
30
31
32
33
34
35
36
37
38
39
40
41
@class OFMutableData;

/**
 * @class OFInvocation OFInvocation.h ObjFW/OFInvocation.h
 *
 * @brief A class for storing and accessing invocations, and invoking them.
 */

@interface OFInvocation: OFObject
{
	OFMethodSignature *_methodSignature;
	OFMutableArray OF_GENERIC(OFMutableData *) *_arguments;
	OFMutableData *_returnValue;
	OF_RESERVE_IVARS(OFInvocation, 4)
}

/**
 * @brief The method signature for the invocation.
 */
@property (readonly, nonatomic) OFMethodSignature *methodSignature;








>





<







22
23
24
25
26
27
28
29
30
31
32
33
34

35
36
37
38
39
40
41
@class OFMutableData;

/**
 * @class OFInvocation OFInvocation.h ObjFW/OFInvocation.h
 *
 * @brief A class for storing and accessing invocations, and invoking them.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFInvocation: OFObject
{
	OFMethodSignature *_methodSignature;
	OFMutableArray OF_GENERIC(OFMutableData *) *_arguments;
	OFMutableData *_returnValue;

}

/**
 * @brief The method signature for the invocation.
 */
@property (readonly, nonatomic) OFMethodSignature *methodSignature;

Modified src/OFMessagePackExtension.h from [45f0ba641f] to [99c89d24f1].

22
23
24
25
26
27
28

29
30
31
32
33
34
35
36
37
38
39
40
41

/**
 * @class OFMessagePackExtension \
 *	  OFMessagePackExtension.h ObjFW/OFMessagePackExtension.h
 *
 * @brief A class for representing the MessagePack extension type.
 */

@interface OFMessagePackExtension: OFObject <OFMessagePackRepresentation,
    OFCopying>
{
	int8_t _type;
	OFData *_data;
	OF_RESERVE_IVARS(OFMessagePackExtension, 4)
}

/**
 * @brief The MessagePack extension type.
 */
@property (readonly, nonatomic) int8_t type;








>





<







22
23
24
25
26
27
28
29
30
31
32
33
34

35
36
37
38
39
40
41

/**
 * @class OFMessagePackExtension \
 *	  OFMessagePackExtension.h ObjFW/OFMessagePackExtension.h
 *
 * @brief A class for representing the MessagePack extension type.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFMessagePackExtension: OFObject <OFMessagePackRepresentation,
    OFCopying>
{
	int8_t _type;
	OFData *_data;

}

/**
 * @brief The MessagePack extension type.
 */
@property (readonly, nonatomic) int8_t type;

Modified src/OFMethodSignature.h from [6c7eab90df] to [91b0f20982].

20
21
22
23
24
25
26

27
28
29
30
31
32
33
34
35
36
37
38
@class OFMutableData;

/**
 * @class OFMethodSignature OFMethodSignature.h ObjFW/OFMethodSignature.h
 *
 * @brief A class for parsing type encodings and accessing them.
 */

@interface OFMethodSignature: OFObject
{
	char *_types;
	OFMutableData *_typesPointers, *_offsets;
	OF_RESERVE_IVARS(OFMethodSignature, 4)
}

/**
 * @brief The number of arguments of the method.
 */
@property (readonly, nonatomic) size_t numberOfArguments;








>




<







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

32
33
34
35
36
37
38
@class OFMutableData;

/**
 * @class OFMethodSignature OFMethodSignature.h ObjFW/OFMethodSignature.h
 *
 * @brief A class for parsing type encodings and accessing them.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFMethodSignature: OFObject
{
	char *_types;
	OFMutableData *_typesPointers, *_offsets;

}

/**
 * @brief The number of arguments of the method.
 */
@property (readonly, nonatomic) size_t numberOfArguments;

Modified src/OFSPXStreamSocket.h from [273c44a2b3] to [b5f5c82a33].

65
66
67
68
69
70
71

72
73
74
75
76
77
78
79
80
81
82
83
 *
 * @note If you want to use SPX in message mode instead of in streaming mode,
 *	 use @ref OFSPXSocket instead.
 *
 * To connect to a server, create a socket and connect it.
 * To create a server, create a socket, bind it and listen on it.
 */

@interface OFSPXStreamSocket: OFStreamSocket
{
	OF_RESERVE_IVARS(OFSPXStreamSocket, 4)
}

/**
 * @brief The delegate for asynchronous operations on the socket.
 *
 * @note The delegate is retained for as long as asynchronous operations are
 *	 still ongoing.
 */
@property OF_NULLABLE_PROPERTY (assign, nonatomic)







>

<
<
<
<







65
66
67
68
69
70
71
72
73




74
75
76
77
78
79
80
 *
 * @note If you want to use SPX in message mode instead of in streaming mode,
 *	 use @ref OFSPXSocket instead.
 *
 * To connect to a server, create a socket and connect it.
 * To create a server, create a socket, bind it and listen on it.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFSPXStreamSocket: OFStreamSocket




/**
 * @brief The delegate for asynchronous operations on the socket.
 *
 * @note The delegate is retained for as long as asynchronous operations are
 *	 still ongoing.
 */
@property OF_NULLABLE_PROPERTY (assign, nonatomic)

Modified src/OFSandbox.h from [8f1c6b186c] to [021642ddcf].

19
20
21
22
23
24
25

26
27
28
29
30
31
32

@class OFArray OF_GENERIC(ObjectType);
@class OFMutableArray OF_GENERIC(ObjectType);
@class OFPair OF_GENERIC(FirstType, SecondType);

typedef OFPair OF_GENERIC(OFString *, OFString *) *OFSandboxUnveilPath;


@interface OFSandbox: OFObject <OFCopying>
{
	unsigned int _allowsStdIO: 1;
	unsigned int _allowsReadingFiles: 1;
	unsigned int _allowsWritingFiles: 1;
	unsigned int _allowsCreatingFiles: 1;
	unsigned int _allowsCreatingSpecialFiles: 1;







>







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

@class OFArray OF_GENERIC(ObjectType);
@class OFMutableArray OF_GENERIC(ObjectType);
@class OFPair OF_GENERIC(FirstType, SecondType);

typedef OFPair OF_GENERIC(OFString *, OFString *) *OFSandboxUnveilPath;

OF_SUBCLASSING_RESTRICTED
@interface OFSandbox: OFObject <OFCopying>
{
	unsigned int _allowsStdIO: 1;
	unsigned int _allowsReadingFiles: 1;
	unsigned int _allowsWritingFiles: 1;
	unsigned int _allowsCreatingFiles: 1;
	unsigned int _allowsCreatingSpecialFiles: 1;
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
	unsigned int _allowsAudio: 1;
	unsigned int _allowsBPF: 1;
	unsigned int _allowsUnveil: 1;
	unsigned int _returnsErrors: 1;
	OFMutableArray OF_GENERIC(OFSandboxUnveilPath) *_unveiledPaths;
@public
	size_t _unveiledPathsIndex;
	OF_RESERVE_IVARS(OFSandbox, 4)
}

@property (nonatomic) bool allowsStdIO;
@property (nonatomic) bool allowsReadingFiles;
@property (nonatomic) bool allowsWritingFiles;
@property (nonatomic) bool allowsCreatingFiles;
@property (nonatomic) bool allowsCreatingSpecialFiles;







<







55
56
57
58
59
60
61

62
63
64
65
66
67
68
	unsigned int _allowsAudio: 1;
	unsigned int _allowsBPF: 1;
	unsigned int _allowsUnveil: 1;
	unsigned int _returnsErrors: 1;
	OFMutableArray OF_GENERIC(OFSandboxUnveilPath) *_unveiledPaths;
@public
	size_t _unveiledPathsIndex;

}

@property (nonatomic) bool allowsStdIO;
@property (nonatomic) bool allowsReadingFiles;
@property (nonatomic) bool allowsWritingFiles;
@property (nonatomic) bool allowsCreatingFiles;
@property (nonatomic) bool allowsCreatingSpecialFiles;

Modified src/OFXMLAttribute.h from [894be32117] to [f37ed8f3fd].

20
21
22
23
24
25
26

27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
@class OFString;

/**
 * @class OFXMLAttribute OFXMLAttribute.h ObjFW/OFXMLAttribute.h
 *
 * @brief A representation of an attribute of an XML element as an object.
 */

@interface OFXMLAttribute: OFXMLNode
{
#if defined(OF_XML_ELEMENT_M) || defined(OF_XML_PARSER_M)
@public
#endif
	OFString *_name, *_Nullable _namespace, *_stringValue;
	bool _useDoubleQuotes;
	OF_RESERVE_IVARS(OFXMLAttribute, 4)
}

/**
 * @brief The name of the attribute.
 */
@property (readonly, nonatomic) OFString *name;








>







<







20
21
22
23
24
25
26
27
28
29
30
31
32
33
34

35
36
37
38
39
40
41
@class OFString;

/**
 * @class OFXMLAttribute OFXMLAttribute.h ObjFW/OFXMLAttribute.h
 *
 * @brief A representation of an attribute of an XML element as an object.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFXMLAttribute: OFXMLNode
{
#if defined(OF_XML_ELEMENT_M) || defined(OF_XML_PARSER_M)
@public
#endif
	OFString *_name, *_Nullable _namespace, *_stringValue;
	bool _useDoubleQuotes;

}

/**
 * @brief The name of the attribute.
 */
@property (readonly, nonatomic) OFString *name;

Modified src/OFXMLCDATA.h from [566e9353f4] to [45c442f70d].

18
19
20
21
22
23
24

25
26
27
28
29
30
31
32
33
34
35
OF_ASSUME_NONNULL_BEGIN

/**
 * @class OFXMLCDATA OFXMLCDATA.h ObjFW/OFXMLCDATA.h
 *
 * @brief A class representing XML CDATA.
 */

@interface OFXMLCDATA: OFXMLNode
{
	OFString *_CDATA;
	OF_RESERVE_IVARS(OFXMLCDATA, 4)
}

/**
 * @brief Creates a new OFXMLCDATA with the specified string.
 *
 * @param string The string value for the CDATA
 * @return A new OFXMLCDATA







>



<







18
19
20
21
22
23
24
25
26
27
28

29
30
31
32
33
34
35
OF_ASSUME_NONNULL_BEGIN

/**
 * @class OFXMLCDATA OFXMLCDATA.h ObjFW/OFXMLCDATA.h
 *
 * @brief A class representing XML CDATA.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFXMLCDATA: OFXMLNode
{
	OFString *_CDATA;

}

/**
 * @brief Creates a new OFXMLCDATA with the specified string.
 *
 * @param string The string value for the CDATA
 * @return A new OFXMLCDATA

Modified src/OFXMLCharacters.h from [314ee7db3d] to [50ac8d5a7f].

18
19
20
21
22
23
24

25
26
27
28
29
30
31
32
33
34
35
OF_ASSUME_NONNULL_BEGIN

/**
 * @class OFXMLCharacters OFXMLCharacters.h ObjFW/OFXMLCharacters.h
 *
 * @brief A class representing XML characters.
 */

@interface OFXMLCharacters: OFXMLNode
{
	OFString *_characters;
	OF_RESERVE_IVARS(OFXMLCharacters, 4)
}

/**
 * @brief Creates a new OFXMLCharacters with the specified string.
 *
 * @param string The string value for the characters
 * @return A new OFXMLCharacters







>



<







18
19
20
21
22
23
24
25
26
27
28

29
30
31
32
33
34
35
OF_ASSUME_NONNULL_BEGIN

/**
 * @class OFXMLCharacters OFXMLCharacters.h ObjFW/OFXMLCharacters.h
 *
 * @brief A class representing XML characters.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFXMLCharacters: OFXMLNode
{
	OFString *_characters;

}

/**
 * @brief Creates a new OFXMLCharacters with the specified string.
 *
 * @param string The string value for the characters
 * @return A new OFXMLCharacters

Modified src/OFXMLComment.h from [cf96f4e7b5] to [566c15f0b8].

18
19
20
21
22
23
24

25
26
27
28
29
30
31
32
33
34
35
OF_ASSUME_NONNULL_BEGIN

/**
 * @class OFXMLComment OFXMLComment.h ObjFW/OFXMLComment.h
 *
 * @brief A class for representing XML comments.
 */

@interface OFXMLComment: OFXMLNode
{
	OFString *_text;
	OF_RESERVE_IVARS(OFXMLComment, 4)
}

/**
 * @brief The comment text.
 */
@property (readonly, nonatomic) OFString *text;








>



<







18
19
20
21
22
23
24
25
26
27
28

29
30
31
32
33
34
35
OF_ASSUME_NONNULL_BEGIN

/**
 * @class OFXMLComment OFXMLComment.h ObjFW/OFXMLComment.h
 *
 * @brief A class for representing XML comments.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFXMLComment: OFXMLNode
{
	OFString *_text;

}

/**
 * @brief The comment text.
 */
@property (readonly, nonatomic) OFString *text;

Modified src/OFXMLElementBuilder.h from [9d586a1499] to [db177baac1].

98
99
100
101
102
103
104

105
106
107
108
109
110
111
112
113
114
115
116
 * @brief A class implementing the OFXMLParserDelegate protocol that can build
 * OFXMLElements from the document parsed by the OFXMLParser.
 *
 * It can also be used to build OFXMLElements from parts of the document by
 * first parsing stuff using the OFXMLParser with another delegate and then
 * setting the OFXMLElementBuilder as delegate for the parser.
 */

@interface OFXMLElementBuilder: OFObject <OFXMLParserDelegate>
{
	OFMutableArray OF_GENERIC(OFXMLElement *) *_stack;
	id <OFXMLElementBuilderDelegate> _Nullable _delegate;
	OF_RESERVE_IVARS(OFXMLElementBuilder, 4)
}

/**
 * @brief The delegate for the OFXMLElementBuilder.
 */
@property OF_NULLABLE_PROPERTY (assign, nonatomic)
    id <OFXMLElementBuilderDelegate> delegate;







>




<







98
99
100
101
102
103
104
105
106
107
108
109

110
111
112
113
114
115
116
 * @brief A class implementing the OFXMLParserDelegate protocol that can build
 * OFXMLElements from the document parsed by the OFXMLParser.
 *
 * It can also be used to build OFXMLElements from parts of the document by
 * first parsing stuff using the OFXMLParser with another delegate and then
 * setting the OFXMLElementBuilder as delegate for the parser.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFXMLElementBuilder: OFObject <OFXMLParserDelegate>
{
	OFMutableArray OF_GENERIC(OFXMLElement *) *_stack;
	id <OFXMLElementBuilderDelegate> _Nullable _delegate;

}

/**
 * @brief The delegate for the OFXMLElementBuilder.
 */
@property OF_NULLABLE_PROPERTY (assign, nonatomic)
    id <OFXMLElementBuilderDelegate> delegate;

Modified src/OFXMLProcessingInstruction.h from [2e0b3e7b02] to [2e0c868afb].

19
20
21
22
23
24
25

26
27
28
29
30
31
32
33
34
35
36

/**
 * @class OFXMLProcessingInstruction \
 *	  OFXMLProcessingInstruction.h ObjFW/OFXMLProcessingInstruction.h
 *
 * @brief A class for representing an XML processing instruction.
 */

@interface OFXMLProcessingInstruction: OFXMLNode
{
	OFString *_target, *_Nullable _text;
	OF_RESERVE_IVARS(OFXMLProcessingInstruction, 4)
}

/**
 * @brief The target of the processing instruction.
 */
@property (readonly, nonatomic) OFString *target;








>



<







19
20
21
22
23
24
25
26
27
28
29

30
31
32
33
34
35
36

/**
 * @class OFXMLProcessingInstruction \
 *	  OFXMLProcessingInstruction.h ObjFW/OFXMLProcessingInstruction.h
 *
 * @brief A class for representing an XML processing instruction.
 */
OF_SUBCLASSING_RESTRICTED
@interface OFXMLProcessingInstruction: OFXMLNode
{
	OFString *_target, *_Nullable _text;

}

/**
 * @brief The target of the processing instruction.
 */
@property (readonly, nonatomic) OFString *target;