• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: TCP connection between Obj-C and java program
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: TCP connection between Obj-C and java program


  • Subject: Re: TCP connection between Obj-C and java program
  • From: Jens Alfke <email@hidden>
  • Date: Thu, 3 Jul 2008 21:37:40 -0700


On 3 Jul '08, at 6:57 PM, Wan, Nathan (CIV) wrote:
I need to make some TCP packet transfers from a mac mini to another computer somewhere else on the internet. [...] On the mac side, it seems like the appropriate class to use is NSStream, but seeing the CocoaEcho example, it seems they are using CFSocket where everything can be done in NSStream, as documented in http://developer.apple.com/documentation/Cocoa/Conceptual/Streams/Streams.html . Am I wrong? Is my entire approach flawed?


CocoaEcho uses CFSocket to run the listener socket that accepts incoming connections. But the TCP connections themselves are managed with NSStreams.


You might want to look at my MYNetwork micro-framework. It includes abstract classes TCPClient and TCPListener that you can subclass. (These were originally derived in part from CocoaEcho, but I've done a lot of work on them and I doubt many lines of the original code are left.)
http://mooseyard.com/projects/MYNetwork/


—Jens _______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >TCP connection between Obj-C and java program (From: "Wan, Nathan (CIV)" <email@hidden>)

  • Prev by Date: TCP connection between Obj-C and java program
  • Next by Date: iPhone: CFWriteStreamWrite
  • Previous by thread: TCP connection between Obj-C and java program
  • Next by thread: TCP connection between Obj-C and java program
  • Index(es):
    • Date
    • Thread