Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. JCPP
Forum Updated to NodeBB v4.3 + New Features

JCPP

Scheduled Pinned Locked Moved General and Desktop
5 Posts 3 Posters 1.3k Views 3 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    chacha
    wrote on last edited by
    #1

    I know it wont attract lots of fan but I have to try :)
    What if we incorporate such a project https://github.com/charb/jcpp within Qt ?
    I come from Java world and tried to do some C++. Qt was the best stuff out there, better than Boost.
    But I still find missing stuff, so I wrote that project to fill the gaps between Java world and C++.
    What do you think ?
    If you are a C++ purist, you would like to kill me, but if you try to think differently you might like what I did ...

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi and welcome to devnet,

      Do you mean your project to be an alternative to JNI ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • C Offline
        C Offline
        chacha
        wrote on last edited by
        #3

        No, not really. JNI does the bridge between the JVM/Java code and C++. So in the same process where you use JNI you have a JVM running and your C/C++ code.
        My project is developed using 100% C++ code and doesn't use any JNI code. The running process that will contain the code that I developed doesn't run any JVM and doesn't load any JDK class.
        For every Java class that you have withing the JDK I developed its equivalent in C++ using pure C++ library, and added the same features that you can find in JAVA : introspection, serialization, threading, ... and with the same API that you can find in Java.
        Hope it is clear

        1 Reply Last reply
        0
        • Chris KawaC Offline
          Chris KawaC Offline
          Chris Kawa
          Lifetime Qt Champion
          wrote on last edited by
          #4

          Hi, I can appreciate the obviously large amount of effort you put into this but what exactly is the purpose?

          If I understand correctly it basically allows to write Java (or rather Java-like) code in C++. As such the potential target group would be people migrating from Java to C++, but this transition usually takes a month or two after which the person either starts to love C++ for all the low level control it gives (like pointers) or hates its guts and grumpily goes back to Java.

          If you're just gonna write Java in C++... why not simply stay with Java?
          I don't see any sustainable value in it. Sorta like what C++/CLI tried to do with C++ and .Net and that didn't go so well.

          But don't get me wrong, I wish you well and might totally missed the point. It's late here ;)

          1 Reply Last reply
          0
          • C Offline
            C Offline
            chacha
            wrote on last edited by
            #5

            Hi thank you for your reply.

            The target is quite the opposite that you are describing. Developers and projects that are using C++ in huge project like myself. I come from a Java world and have a huge project to do in C++. I agree with you that the language allow very powerful low level control, but I dont need that 99% of the time.
            With time I found that most of the Java open source projects are more readable than the rare ones in C++ (sorry for the fans and all people working to make it different).
            Plus in my case, I had the very famous issue about serialization cross language. It is a way to solve it. Of course there are lots of projects that try to solve the problem, but I found with this way I wont limit the objects that I use in Java or in C++

            If we have all our projects in Java, this project is useless.
            If we have all our projects in C++, it might be useful for the following:

            • we need to interact with Java objects via RPC for example. It is the best way without any limitations
            • we need rich open sources or features like the ones we have in Java

            Most of my experience was spent in company with huge legacy code developed in C++ that can't easily be redeveloped in Java.

            1 Reply Last reply
            0

            • Login

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved