Xojo Conferences
MBSOct2019CologneDE

Platforms to show: All Mac Windows Linux Cross-Platform

Previous items

JavaVMMBS.NewIntArray(ref as JavaObjectMBS) as JavaIntArrayMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 8.3 Yes Yes Yes Yes No
Function: Creates a new array object based on the given java object.
Notes: This function is a convenience function to convert a java object array reference to a java array object in Xojo. It can crash if the java object used is not the array of the requested type.

See also:

Feedback, Comments & Corrections

JavaVMMBS.NewIntArray(size as Integer) as JavaIntArrayMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 4.3 Yes Yes Yes Yes No
Function: Creates a new array for integers with the given size.
Notes: Returns nil on any error.

See also:

Feedback, Comments & Corrections

JavaVMMBS.NewIntArray(values() as Int32) as JavaIntArrayMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 19.2 Yes Yes Yes Yes No
Function: Creates new Int32 array with given values.

See also:

Feedback, Comments & Corrections

JavaVMMBS.NewLongArray(ref as JavaObjectMBS) as JavaLongArrayMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 8.3 Yes Yes Yes Yes No
Function: Creates a new array object based on the given java object.
Notes: This function is a convenience function to convert a java object array reference to a java array object in Xojo. It can crash if the java object used is not the array of the requested type.

See also:

Feedback, Comments & Corrections

JavaVMMBS.NewLongArray(size as Integer) as JavaLongArrayMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 4.3 Yes Yes Yes Yes No
Function: Creates a new array for 64 bit integers with the given size.
Notes: Returns nil on any error.

See also:

Feedback, Comments & Corrections

JavaVMMBS.NewLongArray(values() as Int64) as JavaLongArrayMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 19.2 Yes Yes Yes Yes No
Function: Creates new Int64 array with given values.

See also:

Feedback, Comments & Corrections

JavaVMMBS.NewObjectArray(ref as JavaObjectMBS) as JavaObjectArrayMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 8.3 Yes Yes Yes Yes No
Function: Creates a new array object based on the given java object.
Notes: This function is a convenience function to convert a java object array reference to a java array object in Xojo. It can crash if the java object used is not the array of the requested type.

See also:

Feedback, Comments & Corrections

JavaVMMBS.NewObjectArray(size as Integer, TheClass as JavaClassMBS, InitialValue as JavaObjectMBS = nil) as JavaObjectArrayMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 4.3 Yes Yes Yes Yes No
Function: Constructs a new array holding objects in class elementClass.
Notes:
All elements are initially set to initialElement.
Returns nil on any error.

See also:

Feedback, Comments & Corrections

JavaVMMBS.NewObjectArray(values() as JavaObjectMBS) as JavaObjectArrayMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 19.2 Yes Yes Yes Yes No
Function: Creates a new Java object array with given size.

See also:

Feedback, Comments & Corrections

JavaVMMBS.NewShortArray(ref as JavaObjectMBS) as JavaShortArrayMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 8.3 Yes Yes Yes Yes No
Function: Creates a new array object based on the given java object.
Notes: This function is a convenience function to convert a java object array reference to a java array object in Xojo. It can crash if the java object used is not the array of the requested type.

See also:

Feedback, Comments & Corrections

JavaVMMBS.NewShortArray(size as Integer) as JavaShortArrayMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 4.3 Yes Yes Yes Yes No
Function: Creates a new array for shorts with the given size.
Notes: Returns nil on any error.

See also:

Feedback, Comments & Corrections

JavaVMMBS.NewShortArray(values() as Int16) as JavaShortArrayMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 19.2 Yes Yes Yes Yes No
Function: Creates new short array with given values.

See also:

Feedback, Comments & Corrections

JavaVMMBS.NewStringArray(size as integer, InitialValue as JavaStringMBS = nil) as JavaObjectArrayMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 19.2 Yes Yes Yes Yes No
Function: Creates a new Java string array with given size.

See also:

Feedback, Comments & Corrections

JavaVMMBS.NewStringArray(values() as String) as JavaObjectArrayMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 19.2 Yes Yes Yes Yes No
Function: Creates new string array with given values.

See also:

Feedback, Comments & Corrections

JavaVMMBS.NewStringUnicode(s as string) as JavaStringMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 4.3 Yes Yes Yes Yes No
Function: Creates a new string.
Notes: Preferres an Unicode encoded string.

Feedback, Comments & Corrections

JavaVMMBS.NewStringUTF8(s as string) as JavaStringMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 4.3 Yes Yes Yes Yes No
Function: Creates a new string.
Example:
// init Java
dim options() as string
dim javaVm as new JavaVMMBS(JavaVMMBS.JNI_VERSION_1_4, options, true)

// Get system class
Dim system As JavaClassMBS = javaVm.FindClass("java/lang/System")

If system <> Nil Then

// query method
dim transfomerGetPropertyId as JavaMethodMBS = system.GetStaticMethod("getProperty", "(Ljava/lang/String;)Ljava/lang/String;")
If transfomerGetPropertyId <> Nil Then

// make parameters
Dim keyString As JavaStringMBS = javaVm.NewStringUTF8("os.version")
dim m as New MemoryBlock(8)
m.long(0)=keyString.Handle

// run it
dim r as JavaObjectMBS = system.CallStaticObjectMethod(transfomerGetPropertyId, m)

if r<>Nil then
// show result
dim s as JavaStringMBS = JavaStringMBS(r)
MsgBox s.CopyStringUTF
end if

End If
End If
Notes: Preferres an UTF8 encoded string.

Feedback, Comments & Corrections

JavaVMMBS.Runtime as JavaRuntimeMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 8.5 Yes Yes Yes Yes No
Function: Returns the runtime object for the current VM so you can query the memory statistics.

Feedback, Comments & Corrections

JavaVMMBS.ToReflectedField(TheClass as JavaClassMBS, fieldID as JavaFieldMBS, isStatic as boolean) as JavaObjectMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 4.3 Yes Yes Yes Yes No
Function: Creates a new reflected field object for the given field.

Feedback, Comments & Corrections

JavaVMMBS.ToReflectedMethod(TheClass as JavaClassMBS, methodID as JavaMethodMBS, isStatic as boolean) as JavaObjectMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 4.3 Yes Yes Yes Yes No
Function: Creates a new reflected method object for the given method.

Feedback, Comments & Corrections

JavaVMMBS.Version as Integer
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Java MBS Java Plugin 4.3 Yes Yes Yes Yes No
Function: Returns the version of the java engine.
Notes:
Currently the plugin always uses version 1.4.

Returns the major version number in the higher 16 bits and the minor version number in the lower 16 bits.

In JDK1.1, GetVersion() returns 0x00010001.

Feedback, Comments & Corrections

Previous items

The items on this page are in the following plugins: MBS Java Plugin.

The biggest plugin in space...




Links
MBS Xojo Plugins