Results 1 to 8 of 8
  1. #1
    biebo is offline Member
    Join Date
    Mar 2010
    Posts
    1
    Rep Power
    0

    Talking java server and c client ?????????

    hi all.
    I want to create a java service, which listens for UDP or TCP datagrams.
    Is it will possible what the client which is sending data be written in c/c++ or any other language not in java.

    Thanks

  2. #2
    PhQ's Avatar
    PhQ
    PhQ is offline Senior Member
    Join Date
    Mar 2010
    Location
    Lithuania
    Posts
    358
    Rep Power
    5

    Default

    Yes, I think it is, read this:
    Java / C++ socket class
    I'm not sure if it is right, I googled it.

  3. #3
    iluxa is offline Senior Member
    Join Date
    Mar 2010
    Posts
    266
    Rep Power
    5

    Default

    Absolutely. TCP/IP and UDP dont depend on your language. As long as your C++ and Java programs have an understanding of what bytes they send to each other, it will work.

  4. #4
    FallenBlade is offline Member
    Join Date
    Mar 2010
    Posts
    31
    Rep Power
    0

    Default

    Really possible. I'm working on a project right now for university, where I have a Java server and 2 clients. One in C and one in C++.

    I'm using a TCP connection and it doesn't matter what language you write your server or clients in as long as they expect the same inputs/outputs in the right order.

  5. #5
    Eranga's Avatar
    Eranga is offline Moderator
    Join Date
    Jul 2007
    Location
    Colombo, Sri Lanka
    Posts
    11,372
    Blog Entries
    1
    Rep Power
    20

    Default

    Quote Originally Posted by biebo View Post
    hi all.
    I want to create a java service, which listens for UDP or TCP datagrams.
    Is it will possible what the client which is sending data be written in c/c++ or any other language not in java.

    Thanks
    First of all, there is nothing specifically call something Java Service. As your title says seems it's about server/client application.

    All about sockets, nothing else. Did you read/know anything related to that? Same concepts are applied in C/C++ as well as in Java.

  6. #6
    rav
    rav is offline Member
    Join Date
    Jul 2010
    Posts
    16
    Rep Power
    0

    Default

    Hiya, I am also doing the same, I want to send a file in java to a client in c++ and the client will return a value in c++ to java, is that possible, if so could I have an example or some guidance.

    Thanks

  7. #7
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    SW Missouri
    Posts
    17,332
    Rep Power
    25

    Default

    I don't know that a byte or bytes sent by java to a c++ or visa versa is different from any other byte sent by any other program.

    For sample java programs do a Search on the forum.

  8. #8
    Eranga's Avatar
    Eranga is offline Moderator
    Join Date
    Jul 2007
    Location
    Colombo, Sri Lanka
    Posts
    11,372
    Blog Entries
    1
    Rep Power
    20

    Default

    Quote Originally Posted by Norm View Post
    I don't know that a byte or bytes sent by java to a c++ or visa versa is different from any other byte sent by any other program.

    For sample java programs do a Search on the forum.
    Very clear point to the OP.

Similar Threads

  1. Java Server/C Client
    By FallenBlade in forum Networking
    Replies: 13
    Last Post: 03-10-2011, 11:22 PM
  2. Java Message Server/Client help
    By sari in forum Networking
    Replies: 3
    Last Post: 03-20-2010, 11:17 PM
  3. Java Server Client with database
    By cliff in forum Networking
    Replies: 2
    Last Post: 02-08-2010, 11:17 PM
  4. Java Server, Flash Client
    By matbuckland in forum New To Java
    Replies: 3
    Last Post: 09-01-2009, 09:58 AM
  5. java server-client comm
    By Manas Das in forum Networking
    Replies: 2
    Last Post: 01-28-2009, 04:58 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •