Translating array into vector in C++; supporting only List/ArrayList/list for Collect...
[iot2.git] / iotjava / iotrmi / Java / IoTRMITypes.java
index a72c38d87e43a65498ec02bcc189f775d9cfcfb9..9ae048551681d7c2c9f4fa826185e9dcebca8a34 100644 (file)
@@ -52,16 +52,16 @@ public class IoTRMITypes {
                "short",                // 2 bytes
                "int",                  // 4 bytes
                "int",                  // 4 bytes
-               "long",                 // 4 bytes
-               "long",                 // 4 bytes
+               "int64_t",              // 8 bytes
+               "int64_t",              // 8 bytes
                "float",                // 4 bytes
                "float",                // 4 bytes
                "double",               // 8 bytes
                "double",               // 8 bytes
                "bool",                 // 1 byte
                "bool",                 // 1 byte
-               "char",                 // 1 byte
-               "char",                 // 1 byte
+               "char",                 // 2 bytes - C++ is made to follow Java convention
+               "char",                 // 2 bytes -    i.e. 2 bytes for a char
                "string",               // indefinite
                "string",               // indefinite
                "void"                  // 0 byte
@@ -71,32 +71,37 @@ public class IoTRMITypes {
        /**
         * Primitive sizes in Java - Long is 8 bytes and char is 2 bytes
         */
-       public final static Integer[] primitivesJavaSizes = new Integer[] {
+       public final static Integer[] primitivesSizes = new Integer[] {
 
                1, 1, 2, 2, 4, 4, 8, 8, 4, 4, 8, 8, 1, 1, 2, 2, -1, -1, 0
        };
 
 
        /**
-        * Primitive sizes in Cplus - Long is 4 bytes and char is 1 byte
+        * Non-primitive Java data types
         */
-       public final static Integer[] primitivesCplusSizes = new Integer[] {
+       public final static String[] nonPrimitivesJava = new String[] {
 
-               1, 1, 2, 2, 4, 4, 4, 4, 4, 4, 8, 8, 1, 1, 1, 1, -1, -1, 0
+               //"Set",
+               //"HashSet",
+               //"Map",
+               //"HashMap",
+               "List",
+               "ArrayList"
        };
 
 
        /**
-        * Non-primitive Java data types
+        * Non-primitive Java libraries based on the list above
         */
-       public final static String[] nonPrimitivesJava = new String[] {
-
-               "Set",
-               "HashSet",
-               "Map",
-               "HashMap",
-               "List",
-               "ArrayList"
+       public final static String[] nonPrimitiveJavaLibs = new String[] {
+
+               //"java.util.Set",
+               //"java.util.HashSet",
+               //"java.util.Map",
+               //"java.util.HashMap",
+               "java.util.List",
+               "java.util.ArrayList"
        };
 
 
@@ -105,10 +110,10 @@ public class IoTRMITypes {
         */
        public final static String[] nonPrimitivesCplus = new String[] {
 
-               "set",
-               "unordered_set",
-               "map",
-               "unordered_map",
+               //"set",
+               //"unordered_set",
+               //"map",
+               //"unordered_map",
                "list",
                "list"
        };