ObjXMPP  Diff

Differences From Artifact [6081227565]:

To Artifact [498b317e51]:


1
2

3
4

5
6
7
8
9
10
11
1
2
3
4

5
6
7
8
9
10
11
12


+

-
+







/*
 * Copyright (c) 2013, Florian Zeitz <florob@babelmonkeys.de>
 * Copyright (c) 2013, 2016, Jonathan Schleifer <js@heap.zone>
 *
 * https://webkeks.org/git/?p=objxmpp.git
 * https://heap.zone/git/?p=objxmpp.git
 *
 * Permission to use, copy, modify, and/or distribute this software for any
 * purpose with or without fee is hereby granted, provided that the above
 * copyright notice and this permission notice is present in all copies.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
22
23
24
25
26
27
28


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







+
+








#import "XMPPDiscoEntity.h"
#import "XMPPDiscoIdentity.h"
#import "XMPPIQ.h"
#import "namespaces.h"

@implementation XMPPDiscoEntity
@synthesize discoNodes = _discoNodes, capsNode = _capsNode;

+ (instancetype)discoEntityWithConnection: (XMPPConnection*)connection
{
	return [[[self alloc] initWithConnection: connection] autorelease];
}

+ (instancetype)discoEntityWithConnection: (XMPPConnection*)connection
				 capsNode: (OFString*)capsNode
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
71
72
73
74
75
76
77





78
79
80
81
82
83





84
85
86
87
88
89
90







-
-
-
-
-






-
-
-
-
-







{
	[_connection removeDelegate: self];
	[_discoNodes release];

	[super dealloc];
}

- (OFDictionary*)discoNodes;
{
	OF_GETTER(_discoNodes, true)
}

- (void)addDiscoNode: (XMPPDiscoNode*)node
{
	[_discoNodes setObject: node
			forKey: [node node]];
}

- (OFString*)capsNode
{
	OF_GETTER(_capsNode, true)
}

- (OFString*)capsHash
{
	OFEnumerator *enumerator;
	XMPPDiscoIdentity *identity;
	OFString *feature;
	OFMutableString *caps = [OFMutableString string];
	OFSHA1Hash *hash = [OFSHA1Hash hash];