Initial commit of OpenSPARC T2 architecture model.
[OpenSPARC-T2-SAM] / sam-t2 / devtools / amd64 / share / swig / 1.3.26 / java / enumsimple.swg
CommitLineData
920dae64
AT
1/* -----------------------------------------------------------------------------
2 * This file provides backwards compatible enum wrapping. SWIG versions 1.3.21
3 * and earlier wrapped global enums with constant integers in the module class
4 * or Constants interface. Enums declared within a C++ class were wrapped by
5 * constant integers in the Java proxy class.
6 * ----------------------------------------------------------------------------- */
7
8// const enum SWIGTYPE & typemaps
9%typemap(jni) const enum SWIGTYPE & "jint"
10%typemap(jtype) const enum SWIGTYPE & "int"
11%typemap(jstype) const enum SWIGTYPE & "int"
12
13%typemap(in) const enum SWIGTYPE & ($*1_ltype temp)
14%{ temp = ($*1_ltype)$input;
15 $1 = &temp; %}
16%typemap(out) const enum SWIGTYPE & %{ $result = (jint)*$1; %}
17
18%typemap(directorout,warning=SWIG_WARN_TYPEMAP_THREAD_UNSAFE) const enum SWIGTYPE &
19%{ static $*1_ltype temp = ($*1_ltype)$input;
20 $1 = &temp; %}
21%typemap(directorin, descriptor="I") const enum SWIGTYPE & "$input = (jint)$1_name;"
22%typemap(javadirectorin) const enum SWIGTYPE & "$jniinput"
23%typemap(javadirectorout) const enum SWIGTYPE & "$javacall"
24
25%typecheck(SWIG_TYPECHECK_INT32) const enum SWIGTYPE & ""
26
27%typemap(throws) const enum SWIGTYPE & %{
28 (void)$1;
29 SWIG_JavaThrowException(jenv, SWIG_JavaRuntimeException, "C++ $1_type exception thrown");
30%}
31
32%typemap(javain) const enum SWIGTYPE & "$javainput"
33%typemap(javaout) const enum SWIGTYPE & {
34 return $jnicall;
35 }
36
37
38// enum SWIGTYPE typemaps
39%typemap(jni) enum SWIGTYPE "jint"
40%typemap(jtype) enum SWIGTYPE "int"
41%typemap(jstype) enum SWIGTYPE "int"
42
43%typemap(in) enum SWIGTYPE %{ $1 = ($1_ltype)$input; %}
44%typemap(out) enum SWIGTYPE %{ $result = (jint)$1; %}
45
46%typemap(directorout) enum SWIGTYPE %{ $1 = ($1_ltype)$input; %}
47%typemap(directorin, descriptor="I") enum SWIGTYPE "$input = (jint) $1;"
48%typemap(javadirectorin) enum SWIGTYPE "$jniinput"
49%typemap(javadirectorout) enum SWIGTYPE "$javacall"
50
51%typecheck(SWIG_TYPECHECK_INT32) enum SWIGTYPE ""
52
53%typemap(throws) enum SWIGTYPE %{
54 (void)$1;
55 SWIG_JavaThrowException(jenv, SWIG_JavaRuntimeException, "C++ $1_type exception thrown");
56%}
57
58%typemap(javain) enum SWIGTYPE "$javainput"
59%typemap(javaout) enum SWIGTYPE {
60 return $jnicall;
61 }
62
63%typemap(javaclassmodifiers) enum SWIGTYPE ""
64%typemap(javabase) enum SWIGTYPE ""
65%typemap(javacode) enum SWIGTYPE ""
66%typemap(javaimports) enum SWIGTYPE ""
67%typemap(javainterfaces) enum SWIGTYPE ""
68%typemap(javabody) enum SWIGTYPE ""
69
70%javaenum(simple);
71