#include <xmog_java_field.h>
Inheritance diagram for xmog_java_field:


Public Member Functions | |
| xmog_java_class * | clazz () |
| Returns the declaring class. | |
| virtual bool | get_bool (xmog_base *obj, xmog_java_values *args=NULL, xmog_localenv *env=NULL, xmog_flags flags=0) |
| Returns the value of a boolean field. | |
| virtual jbyte | get_byte (xmog_base *obj, xmog_java_values *args=NULL, xmog_localenv *env=NULL, xmog_flags flags=0) |
| Returns the value of a byte field. | |
| virtual jchar | get_char (xmog_base *obj, xmog_java_values *args=NULL, xmog_localenv *env=NULL, xmog_flags flags=0) |
| Returns the value of a char field. | |
| virtual jdouble | get_double (xmog_base *obj, xmog_java_values *args=NULL, xmog_localenv *env=NULL, xmog_flags flags=0) |
| Returns the value of a double field. | |
| jfieldID | get_fieldID () |
| Returns the field's ID. | |
| virtual jfloat | get_float (xmog_base *obj, xmog_java_values *args=NULL, xmog_localenv *env=NULL, xmog_flags flags=0) |
| Returns the value of a float field. | |
| virtual jint | get_int (xmog_base *obj, xmog_java_values *args=NULL, xmog_localenv *env=NULL, xmog_flags flags=0) |
| Returns the value of an int field. | |
| virtual jboolean | get_jboolean (xmog_base *obj, xmog_java_values *args=NULL, xmog_localenv *env=NULL, xmog_flags flags=0) |
| Returns the value of a boolean field. | |
| virtual jobject | get_jobject (xmog_base *obj, xmog_java_values *args=NULL, xmog_localenv *env=NULL, xmog_flags flags=xmog_base::GLOBAL) |
| Returns the value of an object field. | |
| virtual jlong | get_long (xmog_base *obj, xmog_java_values *args=NULL, xmog_localenv *env=NULL, xmog_flags flags=0) |
| Returns the value of a long field. | |
| virtual jshort | get_short (xmog_base *obj, xmog_java_values *args=NULL, xmog_localenv *env=NULL, xmog_flags flags=0) |
| Returns the value of a short field. | |
| virtual void | get_void (xmog_base *obj, xmog_java_values *args=NULL, xmog_localenv *env=NULL, xmog_flags flags=0) |
| Not implemented for this type. | |
| int | initializeFieldID (xmog_localenv *env) |
| Calculates the fieldID based on the information maintained by this instance. | |
| bool | is_static () const |
Returns true if the field is static, false otherwise. | |
| const char * | name () |
| Returns the field's name. | |
| xmog_java_field * | next () |
| Returns the next field declared by the same type. | |
| void | operator delete (void *) |
Overloaded operator delete that is safe to use for non heap-allocated instances. | |
| void * | operator new (size_t) |
Overloaded operator new that allows us to detect whether the instance is heap-allocated or not. | |
| virtual void | set_bool (xmog_base *obj, bool b, xmog_localenv *env=NULL) |
| Sets the value of a boolean field. | |
| virtual void | set_byte (xmog_base *obj, jbyte b, xmog_localenv *env=NULL) |
| Sets the value of a byte field. | |
| virtual void | set_char (xmog_base *obj, jchar ch, xmog_localenv *env=NULL) |
| Sets the value of a char field. | |
| virtual void | set_double (xmog_base *obj, jdouble d, xmog_localenv *env=NULL) |
| Sets the value of a double field. | |
| void | set_fieldID (jfieldID fid) |
| Sets the field's ID. | |
| virtual void | set_float (xmog_base *obj, jfloat f, xmog_localenv *env=NULL) |
| Sets the value of a float field. | |
| virtual void | set_int (xmog_base *obj, jint i, xmog_localenv *env=NULL) |
| Sets the value of an int field. | |
| virtual void | set_jboolean (xmog_base *obj, jboolean b, xmog_localenv *env=NULL) |
| Sets the value of a boolean field. | |
| virtual void | set_jobject (xmog_base *obj, jobject o, xmog_localenv *env=NULL) |
| Sets the value of an object field. | |
| virtual void | set_long (xmog_base *obj, jlong l, xmog_localenv *env=NULL) |
| Sets the value of a long field. | |
| virtual void | set_short (xmog_base *obj, jshort sh, xmog_localenv *env=NULL) |
| Sets the value of a short field. | |
| const char * | type () |
| Returns the field's type in internal form. | |
| xmog_java_field (xmog_java_class *clazz, const char *name, const char *type, bool bStatic=false) | |
The constructor that takes all information required to calculate a jfieldID as input. | |
| xmog_java_field (xmog_java_class *clazz, jfieldID fid, bool bStatic=false) | |
The constructor that takes an externally calculated jfieldID as input. | |
| ~xmog_java_field () | |
| Removes the field instance from the declaring class' list of fields. | |
Friends | |
| class | xmog_java_class |
This type is a specialization of the xmog_java_dynamic interface that knows how to get and set field values of Java instances. This type is a support type that is used by the actual proxy fields. Each declared field is represented by exactly one instance of an xmog_java_field. That instance is then used by a concrete field to access the underlying Java instance. The following snippet illustrates the infrastructure:
xmog_java_class clsContext( "javax/naming/Context", true ); xmog_java_field fPROVIDER_URL( &clsContext, "PROVIDER_URL", "Ljava/lang/String;", true );
and the following snippet illustrates how the generated code uses the infrastructure:
java::lang::String javax::naming::Context::PROVIDER_URL( NULL, &fPROVIDER_URL );
|
||||||||||||||||
|
The constructor that takes an externally calculated
This constructor allows us to create an easy to use wrapper instance for an existing
|
|
||||||||||||||||||||
|
The constructor that takes all information required to calculate a This constructor adds the field instance to the list of fields maintained by the declaring class.
|
|
||||||||||||||||||||
|
Returns the value of a boolean field.
Implements xmog_java_dynamic. |
|
||||||||||||||||||||
|
Returns the value of a byte field.
Implements xmog_java_dynamic. |
|
||||||||||||||||||||
|
Returns the value of a char field.
Implements xmog_java_dynamic. |
|
||||||||||||||||||||
|
Returns the value of a double field.
Implements xmog_java_dynamic. |
|
||||||||||||||||||||
|
Returns the value of a float field.
Implements xmog_java_dynamic. |
|
||||||||||||||||||||
|
Returns the value of an int field.
Implements xmog_java_dynamic. |
|
||||||||||||||||||||
|
Returns the value of a boolean field.
Implements xmog_java_dynamic. |
|
||||||||||||||||||||
|
Returns the value of an object field.
Implements xmog_java_dynamic. |
|
||||||||||||||||||||
|
Returns the value of a long field.
Implements xmog_java_dynamic. |
|
||||||||||||||||||||
|
Returns the value of a short field.
Implements xmog_java_dynamic. |
|
||||||||||||||||||||
|
Not implemented for this type.
There are no fields of type
Implements xmog_java_dynamic. |
|
|
Calculates the fieldID based on the information maintained by this instance.
|
|
||||||||||||||||
|
Sets the value of a boolean field.
Implements xmog_java_dynamic. |
|
||||||||||||||||
|
Sets the value of a byte field.
Implements xmog_java_dynamic. |
|
||||||||||||||||
|
Sets the value of a char field.
Implements xmog_java_dynamic. |
|
||||||||||||||||
|
Sets the value of a double field.
Implements xmog_java_dynamic. |
|
|
Sets the field's ID. This method is used when we perform bulk initialization of elements declared by a type in the remoting protocol. |
|
||||||||||||||||
|
Sets the value of a float field.
Implements xmog_java_dynamic. |
|
||||||||||||||||
|
Sets the value of an int field.
Implements xmog_java_dynamic. |
|
||||||||||||||||
|
Sets the value of a boolean field.
Implements xmog_java_dynamic. |
|
||||||||||||||||
|
Sets the value of an object field.
Implements xmog_java_dynamic. |
|
||||||||||||||||
|
Sets the value of a long field.
Implements xmog_java_dynamic. |
|
||||||||||||||||
|
Sets the value of a short field.
Implements xmog_java_dynamic. |
1.4.1