Signed-off-by: Tomek Grabiec <tgrab...@gmail.com>
---
 include/vm/object.h |   30 ++++++++++++++++++++++++++++++
 1 files changed, 30 insertions(+), 0 deletions(-)

diff --git a/include/vm/object.h b/include/vm/object.h
index 899e741..d4d68c9 100644
--- a/include/vm/object.h
+++ b/include/vm/object.h
@@ -150,30 +150,60 @@ array_set_field_byte(struct vm_object *obj, int index, 
uint8_t value)
        *(uint8_t *) &obj->fields[index * get_vmtype_size(J_BYTE)] = value;
 }
 
+static inline void
+array_set_field_boolean(struct vm_object *obj, int index, jboolean value)
+{
+       *(jboolean *) &obj->fields[index * get_vmtype_size(J_BOOLEAN)] = value;
+}
+
 static inline jboolean
 array_get_field_boolean(struct vm_object *obj, int index)
 {
        return *(jboolean *) &obj->fields[index * get_vmtype_size(J_BOOLEAN)];
 }
 
+static inline void
+array_set_field_short(struct vm_object *obj, int index, jshort value)
+{
+       *(jshort *) &obj->fields[index * get_vmtype_size(J_SHORT)] = value;
+}
+
 static inline jshort
 array_get_field_short(struct vm_object *obj, int index)
 {
        return *(jshort *) &obj->fields[index * get_vmtype_size(J_SHORT)];
 }
 
+static inline void
+array_set_field_int(struct vm_object *obj, int index, jint value)
+{
+       *(jint *) &obj->fields[index * get_vmtype_size(J_INT)] = value;
+}
+
 static inline jint
 array_get_field_int(struct vm_object *obj, int index)
 {
        return *(jint *) &obj->fields[index * get_vmtype_size(J_INT)];
 }
 
+static inline void
+array_set_field_long(struct vm_object *obj, int index, jlong value)
+{
+       *(jlong *) &obj->fields[index * get_vmtype_size(J_LONG)] = value;
+}
+
 static inline jlong
 array_get_field_long(struct vm_object *obj, int index)
 {
        return *(jlong *) &obj->fields[index * get_vmtype_size(J_LONG)];
 }
 
+static inline void
+array_set_field_float(struct vm_object *obj, int index, jfloat value)
+{
+       *(jfloat *) &obj->fields[index * get_vmtype_size(J_FLOAT)] = value;
+}
+
 static inline float
 array_get_field_float(struct vm_object *obj, int index)
 {
-- 
1.6.0.6


------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Jatovm-devel mailing list
Jatovm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jatovm-devel

Reply via email to