Menu

Home

Andreas Knoll

Welcome to your wiki!

This is the default page, edit it as you see fit. To add a new page simply reference it within brackets, e.g.: [SamplePage].

The wiki uses Markdown syntax.

Project Members:


Discussion

  • Andreas Knoll

    Andreas Knoll - 2016-05-05

    What is cppxb?

    My real favorite, using the Java-plattform, is JAXB. A hell of a xml binding framework. Flexible, fast, easy to use and with a lot of power.

    For sure, I love Java!
    (Ok, 8 years ago i'll kick every man who is saying such a terrible thing about me! But in fact: Java is cool!)

    But also, i'm in love with c++. My first love. So, i wish there was such a cool thing like JAXB in c++.

    There are a lot of xml-frameworks for c++. But nothing compares to JAXB. Ok, libxml with SAX or DOM are cool, too. But fiddling around SAX-Callbacks or drowing down using the DOM-API...aaaarg!

    I'll read some XML-Documents! Setup-Files, Object-Descriptors, maybe an JNLP-File...some sort of this things! And i'll get a c++-Object, describing the hole document. And i'm not interessted in such fooling things like comment-nodes.

    In JAXB, usually we are doing this like that:

    Object o = JaxbContext.newContext(...).unmarshall(someSource);

    And have to struggle with a lot instanceof statements. Not nice, but the object is unmarshalled!

    Ok, lets build our own "JAXB for C++"...let's call it cppxb.

     

    Last edit: Andreas Knoll 2016-05-10
  • Andreas Knoll

    Andreas Knoll - 2016-05-05

    What are the intensions of cppxb?

    Unmarshalling

    For now, i'll be focused on Unmarshalling. See the school.xml-Example inside the test-Folder.

    Unmarshalling is the big challange. In JAXB, we have a lot of annotations with runtime rentention, supporting the big beast. Using c++, we dont have such a foolish thing. After compile, we have machine dependend code. There is no place for annotations...

    Don't worry, there are other ways.
    Look at the "school-example" inside the test-folder. You'll see complete Unmarshalling. Including native data types (like some integer types), complex data types, collections of complex data types, aggregations of complex data types and base64 encoded byte arrays.

    Marshalling

    Ok, Marshalling will be important too. Thats the part, i'll work on after the complete unmarshalling game...

    Schema-Compiler

    One of the coolest features using JAXB! But, today i'm not planning such a thing. Maybe in the future....and maybe i'll using java to do so. Maybe

     

    Last edit: Andreas Knoll 2016-05-07
  • Andreas Knoll

    Andreas Knoll - 2016-05-06

    What do you need to use cppxb?

    My development environment is usual an ubuntu 15.10/16.04 operating system. On top of this OS, i'm using eclipse CDT as C++-IDE. It's easy to use.

    To compile and use cppxb, at least you have to install the libxml2-dev package:
    sudo apt-get install libxml2-dev

    I'm using a lot of cpp-11 constructs. So, you need an cpp-11-compliant compiler. On my box residents an g++ 5.2.1.

    Because i'm using eclipse-cdt, there are no Makefile-artefacts. Eclipse-CDT will generate them on demand. If you are planning to use cppxb without using eclipse-cdt, you have to create your own Makefiles. But this will be easy...

    Thats it.

     

    Last edit: Andreas Knoll 2016-05-07
  • Andreas Knoll

    Andreas Knoll - 2016-05-07

    cppxb licence

    cppxb is free software, it's under the GPL V3. So, everyone is free to use this software. Everyone is free to modify them. And everyone is free to include this software into own projects. Of course, under the definitions of GPLv3...

    If you are using this project, it will be nice to put a reference to this project page into your documentation. Thx.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.