OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [libjava/] [java/] [io/] [natVMObjectStreamClass.cc] - Blame information for rev 761

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 758 jeremybenn
// natVMObjectStreamClass.cc - Native part of VMObjectStreamClass class.
2
 
3
/* Copyright (C) 2003  Free Software Foundation
4
 
5
   This VMObjectStreamClass is part of libgcj.
6
 
7
This software is copyrighted work licensed under the terms of the
8
Libgcj License.  Please consult the ObjectInputStream "LIBGCJ_LICENSE" for
9
details.  */
10
 
11
#include <gcj/cni.h>
12
#include <jvm.h>
13
 
14
#include <java/io/VMObjectStreamClass.h>
15
#include <java/lang/Class.h>
16
#include <java/lang/reflect/Field.h>
17
 
18
using namespace java::lang::reflect;
19
 
20
jboolean
21
java::io::VMObjectStreamClass::hasClassInitializer (jclass klass)
22
{
23
  if (klass->isPrimitive())
24
    return false;
25
  _Jv_Method *meth = _Jv_GetMethodLocal(klass, gcj::clinit_name,
26
                                               gcj::void_signature);
27
  return (meth != NULL);
28
}
29
 
30
void
31
java::io::VMObjectStreamClass::setDoubleNative (Field *f, jobject obj,
32
                                                jdouble val)
33
{
34
  f->setDouble (NULL, obj, val, false);
35
}
36
 
37
void
38
java::io::VMObjectStreamClass::setFloatNative (Field *f, jobject obj,
39
                                               jfloat val)
40
{
41
  f->setFloat (NULL, obj, val, false);
42
}
43
 
44
void
45
java::io::VMObjectStreamClass::setLongNative (Field *f, jobject obj, jlong val)
46
{
47
  f->setLong (NULL, obj, val, false);
48
}
49
 
50
void
51
java::io::VMObjectStreamClass::setIntNative (Field *f, jobject obj, jint val)
52
{
53
  f->setInt (NULL, obj, val, false);
54
}
55
 
56
void
57
java::io::VMObjectStreamClass::setShortNative (Field *f, jobject obj,
58
                                               jshort val)
59
{
60
  f->setShort (NULL, obj, val, false);
61
}
62
 
63
void
64
java::io::VMObjectStreamClass::setCharNative (Field *f, jobject obj, jchar val)
65
{
66
  f->setChar (NULL, obj, val, false);
67
}
68
 
69
void
70
java::io::VMObjectStreamClass::setByteNative (Field *f, jobject obj, jbyte val)
71
{
72
  f->setByte (NULL, obj, val, false);
73
}
74
 
75
void
76
java::io::VMObjectStreamClass::setBooleanNative (Field *f, jobject obj,
77
                                                 jboolean val)
78
{
79
  f->setBoolean (NULL, obj, val, false);
80
}
81
 
82
void
83
java::io::VMObjectStreamClass::setObjectNative (Field *f, jobject obj,
84
                                                jobject val)
85
{
86
  f->set (NULL, obj, val, f->getType(), false);
87
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.