Add sendStanza to XMPPConnection
This commit is contained in:
parent
3f2a22140e
commit
4bdf81b429
2 changed files with 8 additions and 2 deletions
|
@ -40,4 +40,5 @@
|
|||
|
||||
- (void)connect;
|
||||
- (void)handleConnection;
|
||||
- (void)sendStanza: (OFXMLElement*)elem;
|
||||
@end
|
||||
|
|
|
@ -79,6 +79,11 @@
|
|||
}
|
||||
}
|
||||
|
||||
- (void)sendStanza: (OFXMLElement*)elem
|
||||
{
|
||||
[sock writeString: [elem stringValue]];
|
||||
}
|
||||
|
||||
- (void)parser: (OFXMLParser*)p
|
||||
didStartElement: (OFString*)name
|
||||
withPrefix: (OFString*)prefix
|
||||
|
@ -130,7 +135,7 @@
|
|||
[authTag addChild: [OFXMLElement elementWithCharacters:
|
||||
[message stringByBase64Encoding]]];
|
||||
|
||||
[sock writeString: [authTag stringValue]];
|
||||
[self sendStanza: authTag];
|
||||
}
|
||||
|
||||
- (void)_sendResourceBind
|
||||
|
@ -139,7 +144,7 @@
|
|||
[iq addChild: [OFXMLElement elementWithName: @"bind"
|
||||
namespace: NS_BIND]];
|
||||
|
||||
[sock writeString: [iq stringValue]];
|
||||
[self sendStanza: iq];
|
||||
}
|
||||
|
||||
- (void)_handleFeatures: (OFXMLElement*)elem
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue