ios - XMPPFramework - How to transfer image from one device to another? -
i have made one-to-one chat using xmpp protocol. now, send image , video in application. researched file transfer didn't find solution. have used code below socket connection.
please advice me on how can go doing this.
[turnsocket setproxycandidates:@[@"myserverhost-desktop"]]; xmppjid *jid = [xmppjid jidwithstring:@"1254225445@myserverhost-desktop"]; turnsocket *turnsocket = [[turnsocket alloc] initwithstream:[[self appdelegate]xmppstream] tojid:jid]; [app.turnsocketarray addobject:turnsocket]; [turnsocket startwithdelegate:self delegatequeue:dispatch_get_main_queue()]; [turnsocket release]; - (void)turnsocket:(turnsocket *)sender didsucceed:(gcdasyncsocket *)socket { } - (void)turnsocketdidfail:(turnsocket *)sender { }
every time connection fail method call..
thanks.
you need push image server , reveice url server .then can send url device xmpp protocol. in end. download image server received url.
xmpp can send image . that's big xml message xmpp server .that's not great solution.
Comments
Post a Comment