C++ to Java


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 3 of 3

Thread: C++ to Java

Hybrid View

  1. #1
    Alice and Cristina Guest

    C++ to Java


    We're making a program in java, and we have the source code in c++, so we
    just have to translate this code to Java, and we have a problem, one of the
    files we have in c++ is a tree implementation, and we don't know how to make
    a pointer in java.
    If anyone of you has a tree implemented in Java, or knows the answer to our
    problem, please send it to us!
    It's very important!!!!
    Thanks a lot,
    Alice and Cristina

  2. #2
    Paul Clapham Guest

    Re: C++ to Java

    For trees, see the tutorial at
    http://java.sun.com/docs/books/tutor...nts/tree.html. You
    don't need pointers in Java. Objects are implemented by references that act
    the same way as pointers.

    Alice and Cristina <alice@jet.es> wrote in message
    news:39a2ac54$1@news.devx.com...
    >
    > We're making a program in java, and we have the source code in c++, so we
    > just have to translate this code to Java, and we have a problem, one of

    the
    > files we have in c++ is a tree implementation, and we don't know how to

    make
    > a pointer in java.
    > If anyone of you has a tree implemented in Java, or knows the answer to

    our
    > problem, please send it to us!
    > It's very important!!!!
    > Thanks a lot,
    > Alice and Cristina




  3. #3
    Ruchi Dhar Guest

    Re: C++ to Java


    I don't understand what do you mean by there is no pointer in java. For tree
    implementation you don't require any memory access. You can easily implements
    the linkage and pointer to next node using simple arrays and Vectors. Remember
    all objects references are nothing but pointers. There are lots of books
    available for datastructures in java you can have a look at them.

    "Alice and Cristina" <alice@jet.es> wrote:
    >
    >We're making a program in java, and we have the source code in c++, so we
    >just have to translate this code to Java, and we have a problem, one of

    the
    >files we have in c++ is a tree implementation, and we don't know how to

    make
    >a pointer in java.
    >If anyone of you has a tree implemented in Java, or knows the answer to

    our
    >problem, please send it to us!
    >It's very important!!!!
    >Thanks a lot,
    >Alice and Cristina



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center