diff options
author | Tom Tromey <tromey@gcc.gnu.org> | 2007-01-09 19:58:05 +0000 |
---|---|---|
committer | Tom Tromey <tromey@gcc.gnu.org> | 2007-01-09 19:58:05 +0000 |
commit | 97b8365cafc3a344a22d3980b8ed885f5c6d8357 (patch) | |
tree | 996a5f57d4a68c53473382e45cb22f574cb3e4db /libjava/java/lang/management | |
parent | c648dedbde727ca3f883bb5fd773aa4af70d3369 (diff) | |
download | gcc-97b8365cafc3a344a22d3980b8ed885f5c6d8357.tar.gz |
Merged gcj-eclipse branch to trunk.
From-SVN: r120621
Diffstat (limited to 'libjava/java/lang/management')
18 files changed, 589 insertions, 12 deletions
diff --git a/libjava/java/lang/management/ClassLoadingMXBean.h b/libjava/java/lang/management/ClassLoadingMXBean.h new file mode 100644 index 00000000000..371b63d3dd0 --- /dev/null +++ b/libjava/java/lang/management/ClassLoadingMXBean.h @@ -0,0 +1,23 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_ClassLoadingMXBean__ +#define __java_lang_management_ClassLoadingMXBean__ + +#pragma interface + +#include <java/lang/Object.h> + +class java::lang::management::ClassLoadingMXBean : public ::java::lang::Object +{ + +public: + virtual jint getLoadedClassCount() = 0; + virtual jlong getTotalLoadedClassCount() = 0; + virtual jlong getUnloadedClassCount() = 0; + virtual jboolean isVerbose() = 0; + virtual void setVerbose(jboolean) = 0; + static ::java::lang::Class class$; +} __attribute__ ((java_interface)); + +#endif // __java_lang_management_ClassLoadingMXBean__ diff --git a/libjava/java/lang/management/CompilationMXBean.h b/libjava/java/lang/management/CompilationMXBean.h new file mode 100644 index 00000000000..bbd1e0a210e --- /dev/null +++ b/libjava/java/lang/management/CompilationMXBean.h @@ -0,0 +1,21 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_CompilationMXBean__ +#define __java_lang_management_CompilationMXBean__ + +#pragma interface + +#include <java/lang/Object.h> + +class java::lang::management::CompilationMXBean : public ::java::lang::Object +{ + +public: + virtual ::java::lang::String * getName() = 0; + virtual jboolean isCompilationTimeMonitoringSupported() = 0; + virtual jlong getTotalCompilationTime() = 0; + static ::java::lang::Class class$; +} __attribute__ ((java_interface)); + +#endif // __java_lang_management_CompilationMXBean__ diff --git a/libjava/java/lang/management/GarbageCollectorMXBean.h b/libjava/java/lang/management/GarbageCollectorMXBean.h new file mode 100644 index 00000000000..35222cab065 --- /dev/null +++ b/libjava/java/lang/management/GarbageCollectorMXBean.h @@ -0,0 +1,25 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_GarbageCollectorMXBean__ +#define __java_lang_management_GarbageCollectorMXBean__ + +#pragma interface + +#include <java/lang/Object.h> +#include <gcj/array.h> + + +class java::lang::management::GarbageCollectorMXBean : public ::java::lang::Object +{ + +public: + virtual jlong getCollectionCount() = 0; + virtual jlong getCollectionTime() = 0; + virtual JArray< ::java::lang::String * > * getMemoryPoolNames() = 0; + virtual ::java::lang::String * getName() = 0; + virtual jboolean isValid() = 0; + static ::java::lang::Class class$; +} __attribute__ ((java_interface)); + +#endif // __java_lang_management_GarbageCollectorMXBean__ diff --git a/libjava/java/lang/management/ManagementFactory.h b/libjava/java/lang/management/ManagementFactory.h new file mode 100644 index 00000000000..a315333be05 --- /dev/null +++ b/libjava/java/lang/management/ManagementFactory.h @@ -0,0 +1,57 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_ManagementFactory__ +#define __java_lang_management_ManagementFactory__ + +#pragma interface + +#include <java/lang/Object.h> +extern "Java" +{ + namespace javax + { + namespace management + { + class MBeanServer; + } + } +} + +class java::lang::management::ManagementFactory : public ::java::lang::Object +{ + + ManagementFactory(); +public: + static ::java::lang::management::OperatingSystemMXBean * getOperatingSystemMXBean(); + static ::java::lang::management::RuntimeMXBean * getRuntimeMXBean(); + static ::java::lang::management::ClassLoadingMXBean * getClassLoadingMXBean(); + static ::java::lang::management::ThreadMXBean * getThreadMXBean(); + static ::java::lang::management::MemoryMXBean * getMemoryMXBean(); + static ::java::lang::management::CompilationMXBean * getCompilationMXBean(); + static ::java::util::List * getMemoryPoolMXBeans(); + static ::java::util::List * getMemoryManagerMXBeans(); + static ::java::util::List * getGarbageCollectorMXBeans(); + static ::javax::management::MBeanServer * getPlatformMBeanServer(); + static ::java::lang::String * CLASS_LOADING_MXBEAN_NAME; + static ::java::lang::String * COMPILATION_MXBEAN_NAME; + static ::java::lang::String * GARBAGE_COLLECTOR_MXBEAN_DOMAIN_TYPE; + static ::java::lang::String * MEMORY_MANAGER_MXBEAN_DOMAIN_TYPE; + static ::java::lang::String * MEMORY_MXBEAN_NAME; + static ::java::lang::String * MEMORY_POOL_MXBEAN_DOMAIN_TYPE; + static ::java::lang::String * OPERATING_SYSTEM_MXBEAN_NAME; + static ::java::lang::String * RUNTIME_MXBEAN_NAME; + static ::java::lang::String * THREAD_MXBEAN_NAME; +private: + static ::java::lang::management::OperatingSystemMXBean * osBean; + static ::java::lang::management::RuntimeMXBean * runtimeBean; + static ::java::lang::management::ClassLoadingMXBean * classLoadingBean; + static ::java::lang::management::ThreadMXBean * threadBean; + static ::java::lang::management::MemoryMXBean * memoryBean; + static ::java::lang::management::CompilationMXBean * compilationBean; + static ::javax::management::MBeanServer * platformServer; +public: + static ::java::lang::Class class$; +}; + +#endif // __java_lang_management_ManagementFactory__ diff --git a/libjava/java/lang/management/ManagementPermission.h b/libjava/java/lang/management/ManagementPermission.h new file mode 100644 index 00000000000..4ac4a4fef4f --- /dev/null +++ b/libjava/java/lang/management/ManagementPermission.h @@ -0,0 +1,23 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_ManagementPermission__ +#define __java_lang_management_ManagementPermission__ + +#pragma interface + +#include <java/security/BasicPermission.h> + +class java::lang::management::ManagementPermission : public ::java::security::BasicPermission +{ + +public: + ManagementPermission(::java::lang::String *); + ManagementPermission(::java::lang::String *, ::java::lang::String *); +private: + static const jlong serialVersionUID = 1897496590799378737LL; +public: + static ::java::lang::Class class$; +}; + +#endif // __java_lang_management_ManagementPermission__ diff --git a/libjava/java/lang/management/MemoryMXBean.h b/libjava/java/lang/management/MemoryMXBean.h new file mode 100644 index 00000000000..2fb70add22e --- /dev/null +++ b/libjava/java/lang/management/MemoryMXBean.h @@ -0,0 +1,24 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_MemoryMXBean__ +#define __java_lang_management_MemoryMXBean__ + +#pragma interface + +#include <java/lang/Object.h> + +class java::lang::management::MemoryMXBean : public ::java::lang::Object +{ + +public: + virtual void gc() = 0; + virtual ::java::lang::management::MemoryUsage * getHeapMemoryUsage() = 0; + virtual ::java::lang::management::MemoryUsage * getNonHeapMemoryUsage() = 0; + virtual jint getObjectPendingFinalizationCount() = 0; + virtual jboolean isVerbose() = 0; + virtual void setVerbose(jboolean) = 0; + static ::java::lang::Class class$; +} __attribute__ ((java_interface)); + +#endif // __java_lang_management_MemoryMXBean__ diff --git a/libjava/java/lang/management/MemoryManagerMXBean.h b/libjava/java/lang/management/MemoryManagerMXBean.h new file mode 100644 index 00000000000..6509205a9b0 --- /dev/null +++ b/libjava/java/lang/management/MemoryManagerMXBean.h @@ -0,0 +1,23 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_MemoryManagerMXBean__ +#define __java_lang_management_MemoryManagerMXBean__ + +#pragma interface + +#include <java/lang/Object.h> +#include <gcj/array.h> + + +class java::lang::management::MemoryManagerMXBean : public ::java::lang::Object +{ + +public: + virtual JArray< ::java::lang::String * > * getMemoryPoolNames() = 0; + virtual ::java::lang::String * getName() = 0; + virtual jboolean isValid() = 0; + static ::java::lang::Class class$; +} __attribute__ ((java_interface)); + +#endif // __java_lang_management_MemoryManagerMXBean__ diff --git a/libjava/java/lang/management/MemoryNotificationInfo.h b/libjava/java/lang/management/MemoryNotificationInfo.h new file mode 100644 index 00000000000..07cfefff3bb --- /dev/null +++ b/libjava/java/lang/management/MemoryNotificationInfo.h @@ -0,0 +1,43 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_MemoryNotificationInfo__ +#define __java_lang_management_MemoryNotificationInfo__ + +#pragma interface + +#include <java/lang/Object.h> +extern "Java" +{ + namespace javax + { + namespace management + { + namespace openmbean + { + class CompositeData; + } + } + } +} + +class java::lang::management::MemoryNotificationInfo : public ::java::lang::Object +{ + +public: + MemoryNotificationInfo(::java::lang::String *, ::java::lang::management::MemoryUsage *, jlong); + static ::java::lang::management::MemoryNotificationInfo * from(::javax::management::openmbean::CompositeData *); + virtual jlong getCount(); + virtual ::java::lang::String * getPoolName(); + virtual ::java::lang::management::MemoryUsage * getUsage(); + static ::java::lang::String * MEMORY_THRESHOLD_EXCEEDED; + static ::java::lang::String * MEMORY_COLLECTION_THRESHOLD_EXCEEDED; +private: + ::java::lang::String * __attribute__((aligned(__alignof__( ::java::lang::Object)))) poolName; + ::java::lang::management::MemoryUsage * usage; + jlong count; +public: + static ::java::lang::Class class$; +}; + +#endif // __java_lang_management_MemoryNotificationInfo__ diff --git a/libjava/java/lang/management/MemoryPoolMXBean.h b/libjava/java/lang/management/MemoryPoolMXBean.h new file mode 100644 index 00000000000..4209d573a9d --- /dev/null +++ b/libjava/java/lang/management/MemoryPoolMXBean.h @@ -0,0 +1,38 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_MemoryPoolMXBean__ +#define __java_lang_management_MemoryPoolMXBean__ + +#pragma interface + +#include <java/lang/Object.h> +#include <gcj/array.h> + + +class java::lang::management::MemoryPoolMXBean : public ::java::lang::Object +{ + +public: + virtual ::java::lang::management::MemoryUsage * getCollectionUsage() = 0; + virtual jlong getCollectionUsageThreshold() = 0; + virtual jlong getCollectionUsageThresholdCount() = 0; + virtual JArray< ::java::lang::String * > * getMemoryManagerNames() = 0; + virtual ::java::lang::String * getName() = 0; + virtual ::java::lang::management::MemoryUsage * getPeakUsage() = 0; + virtual ::java::lang::management::MemoryType * getType() = 0; + virtual ::java::lang::management::MemoryUsage * getUsage() = 0; + virtual jlong getUsageThreshold() = 0; + virtual jlong getUsageThresholdCount() = 0; + virtual jboolean isCollectionUsageThresholdExceeded() = 0; + virtual jboolean isCollectionUsageThresholdSupported() = 0; + virtual jboolean isUsageThresholdExceeded() = 0; + virtual jboolean isUsageThresholdSupported() = 0; + virtual jboolean isValid() = 0; + virtual void resetPeakUsage() = 0; + virtual void setCollectionUsageThreshold(jlong) = 0; + virtual void setUsageThreshold(jlong) = 0; + static ::java::lang::Class class$; +} __attribute__ ((java_interface)); + +#endif // __java_lang_management_MemoryPoolMXBean__ diff --git a/libjava/java/lang/management/MemoryType.h b/libjava/java/lang/management/MemoryType.h new file mode 100644 index 00000000000..b93587d308a --- /dev/null +++ b/libjava/java/lang/management/MemoryType.h @@ -0,0 +1,28 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_MemoryType__ +#define __java_lang_management_MemoryType__ + +#pragma interface + +#include <java/lang/Enum.h> +#include <gcj/array.h> + + +class java::lang::management::MemoryType : public ::java::lang::Enum +{ + + MemoryType(::java::lang::String *, jint); +public: + static JArray< ::java::lang::management::MemoryType * > * values(); + static ::java::lang::management::MemoryType * valueOf(::java::lang::String *); + static ::java::lang::management::MemoryType * HEAP; + static ::java::lang::management::MemoryType * NON_HEAP; +private: + static JArray< ::java::lang::management::MemoryType * > * ENUM$VALUES; +public: + static ::java::lang::Class class$; +}; + +#endif // __java_lang_management_MemoryType__ diff --git a/libjava/java/lang/management/MemoryUsage.h b/libjava/java/lang/management/MemoryUsage.h new file mode 100644 index 00000000000..3b126f8183e --- /dev/null +++ b/libjava/java/lang/management/MemoryUsage.h @@ -0,0 +1,44 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_MemoryUsage__ +#define __java_lang_management_MemoryUsage__ + +#pragma interface + +#include <java/lang/Object.h> +extern "Java" +{ + namespace javax + { + namespace management + { + namespace openmbean + { + class CompositeData; + } + } + } +} + +class java::lang::management::MemoryUsage : public ::java::lang::Object +{ + +public: + MemoryUsage(jlong, jlong, jlong, jlong); + static ::java::lang::management::MemoryUsage * from(::javax::management::openmbean::CompositeData *); + virtual jlong getCommitted(); + virtual jlong getInit(); + virtual jlong getMax(); + virtual jlong getUsed(); + virtual ::java::lang::String * toString(); +private: + jlong __attribute__((aligned(__alignof__( ::java::lang::Object)))) init; + jlong used; + jlong committed; + jlong maximum; +public: + static ::java::lang::Class class$; +}; + +#endif // __java_lang_management_MemoryUsage__ diff --git a/libjava/java/lang/management/OperatingSystemMXBean.h b/libjava/java/lang/management/OperatingSystemMXBean.h new file mode 100644 index 00000000000..adb562cf516 --- /dev/null +++ b/libjava/java/lang/management/OperatingSystemMXBean.h @@ -0,0 +1,22 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_OperatingSystemMXBean__ +#define __java_lang_management_OperatingSystemMXBean__ + +#pragma interface + +#include <java/lang/Object.h> + +class java::lang::management::OperatingSystemMXBean : public ::java::lang::Object +{ + +public: + virtual ::java::lang::String * getArch() = 0; + virtual jint getAvailableProcessors() = 0; + virtual ::java::lang::String * getName() = 0; + virtual ::java::lang::String * getVersion() = 0; + static ::java::lang::Class class$; +} __attribute__ ((java_interface)); + +#endif // __java_lang_management_OperatingSystemMXBean__ diff --git a/libjava/java/lang/management/RuntimeMXBean.h b/libjava/java/lang/management/RuntimeMXBean.h new file mode 100644 index 00000000000..c2666744020 --- /dev/null +++ b/libjava/java/lang/management/RuntimeMXBean.h @@ -0,0 +1,34 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_RuntimeMXBean__ +#define __java_lang_management_RuntimeMXBean__ + +#pragma interface + +#include <java/lang/Object.h> + +class java::lang::management::RuntimeMXBean : public ::java::lang::Object +{ + +public: + virtual ::java::lang::String * getBootClassPath() = 0; + virtual ::java::lang::String * getClassPath() = 0; + virtual ::java::util::List * getInputArguments() = 0; + virtual ::java::lang::String * getLibraryPath() = 0; + virtual ::java::lang::String * getManagementSpecVersion() = 0; + virtual ::java::lang::String * getName() = 0; + virtual ::java::lang::String * getSpecName() = 0; + virtual ::java::lang::String * getSpecVendor() = 0; + virtual ::java::lang::String * getSpecVersion() = 0; + virtual jlong getStartTime() = 0; + virtual ::java::util::Map * getSystemProperties() = 0; + virtual jlong getUptime() = 0; + virtual ::java::lang::String * getVmName() = 0; + virtual ::java::lang::String * getVmVendor() = 0; + virtual ::java::lang::String * getVmVersion() = 0; + virtual jboolean isBootClassPathSupported() = 0; + static ::java::lang::Class class$; +} __attribute__ ((java_interface)); + +#endif // __java_lang_management_RuntimeMXBean__ diff --git a/libjava/java/lang/management/ThreadInfo.h b/libjava/java/lang/management/ThreadInfo.h new file mode 100644 index 00000000000..a06b99ce4cc --- /dev/null +++ b/libjava/java/lang/management/ThreadInfo.h @@ -0,0 +1,70 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_ThreadInfo__ +#define __java_lang_management_ThreadInfo__ + +#pragma interface + +#include <java/lang/Object.h> +#include <gcj/array.h> + +extern "Java" +{ + namespace javax + { + namespace management + { + namespace openmbean + { + class CompositeData; + class CompositeType; + class OpenType; + } + } + } +} + +class java::lang::management::ThreadInfo : public ::java::lang::Object +{ + + ThreadInfo(::java::lang::Thread *, jlong, jlong, ::java::lang::Object *, ::java::lang::Thread *, jlong, jlong, jboolean, jboolean, JArray< ::java::lang::StackTraceElement * > *); + ThreadInfo(jlong, ::java::lang::String *, ::java::lang::Thread$State *, jlong, jlong, ::java::lang::String *, jlong, ::java::lang::String *, jlong, jlong, jboolean, jboolean, JArray< ::java::lang::StackTraceElement * > *); +public: // actually package-private + static void checkAttribute(::javax::management::openmbean::CompositeType *, ::java::lang::String *, ::javax::management::openmbean::OpenType *); +public: + static ::java::lang::management::ThreadInfo * from(::javax::management::openmbean::CompositeData *); + virtual jlong getBlockedCount(); + virtual jlong getBlockedTime(); + virtual ::java::lang::String * getLockName(); + virtual jlong getLockOwnerId(); + virtual ::java::lang::String * getLockOwnerName(); + virtual JArray< ::java::lang::StackTraceElement * > * getStackTrace(); + virtual jlong getThreadId(); + virtual ::java::lang::String * getThreadName(); + virtual ::java::lang::Thread$State * getThreadState(); + virtual jlong getWaitedCount(); + virtual jlong getWaitedTime(); + virtual jboolean isInNative(); + virtual jboolean isSuspended(); + virtual ::java::lang::String * toString(); +private: + jlong __attribute__((aligned(__alignof__( ::java::lang::Object)))) threadId; + ::java::lang::String * threadName; + ::java::lang::Thread$State * threadState; + jlong blockedCount; + jlong blockedTime; + ::java::lang::String * lockName; + jlong lockOwnerId; + ::java::lang::String * lockOwnerName; + jlong waitedCount; + jlong waitedTime; + jboolean isInNative__; + jboolean isSuspended__; + JArray< ::java::lang::StackTraceElement * > * trace; + static ::java::lang::management::ThreadMXBean * bean; +public: + static ::java::lang::Class class$; +}; + +#endif // __java_lang_management_ThreadInfo__ diff --git a/libjava/java/lang/management/ThreadMXBean.h b/libjava/java/lang/management/ThreadMXBean.h new file mode 100644 index 00000000000..a160b088149 --- /dev/null +++ b/libjava/java/lang/management/ThreadMXBean.h @@ -0,0 +1,42 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_ThreadMXBean__ +#define __java_lang_management_ThreadMXBean__ + +#pragma interface + +#include <java/lang/Object.h> +#include <gcj/array.h> + + +class java::lang::management::ThreadMXBean : public ::java::lang::Object +{ + +public: + virtual JArray< jlong > * findMonitorDeadlockedThreads() = 0; + virtual JArray< jlong > * getAllThreadIds() = 0; + virtual jlong getCurrentThreadCpuTime() = 0; + virtual jlong getCurrentThreadUserTime() = 0; + virtual jint getDaemonThreadCount() = 0; + virtual jint getPeakThreadCount() = 0; + virtual jint getThreadCount() = 0; + virtual jlong getThreadCpuTime(jlong) = 0; + virtual ::java::lang::management::ThreadInfo * getThreadInfo(jlong) = 0; + virtual JArray< ::java::lang::management::ThreadInfo * > * getThreadInfo(JArray< jlong > *) = 0; + virtual ::java::lang::management::ThreadInfo * getThreadInfo(jlong, jint) = 0; + virtual JArray< ::java::lang::management::ThreadInfo * > * getThreadInfo(JArray< jlong > *, jint) = 0; + virtual jlong getThreadUserTime(jlong) = 0; + virtual jlong getTotalStartedThreadCount() = 0; + virtual jboolean isCurrentThreadCpuTimeSupported() = 0; + virtual jboolean isThreadContentionMonitoringEnabled() = 0; + virtual jboolean isThreadContentionMonitoringSupported() = 0; + virtual jboolean isThreadCpuTimeEnabled() = 0; + virtual jboolean isThreadCpuTimeSupported() = 0; + virtual void resetPeakThreadCount() = 0; + virtual void setThreadContentionMonitoringEnabled(jboolean) = 0; + virtual void setThreadCpuTimeEnabled(jboolean) = 0; + static ::java::lang::Class class$; +} __attribute__ ((java_interface)); + +#endif // __java_lang_management_ThreadMXBean__ diff --git a/libjava/java/lang/management/VMManagementFactory.h b/libjava/java/lang/management/VMManagementFactory.h new file mode 100644 index 00000000000..e712cbfc871 --- /dev/null +++ b/libjava/java/lang/management/VMManagementFactory.h @@ -0,0 +1,25 @@ + +// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- + +#ifndef __java_lang_management_VMManagementFactory__ +#define __java_lang_management_VMManagementFactory__ + +#pragma interface + +#include <java/lang/Object.h> +#include <gcj/array.h> + + +class java::lang::management::VMManagementFactory : public ::java::lang::Object +{ + +public: // actually package-private + VMManagementFactory(); + static JArray< ::java::lang::String * > * getMemoryPoolNames(); + static JArray< ::java::lang::String * > * getMemoryManagerNames(); + static JArray< ::java::lang::String * > * getGarbageCollectorNames(); +public: + static ::java::lang::Class class$; +}; + +#endif // __java_lang_management_VMManagementFactory__ diff --git a/libjava/java/lang/management/VMManagementFactory.java b/libjava/java/lang/management/VMManagementFactory.java index 6a906c730db..f10497014b4 100644 --- a/libjava/java/lang/management/VMManagementFactory.java +++ b/libjava/java/lang/management/VMManagementFactory.java @@ -54,10 +54,7 @@ final class VMManagementFactory * * @return a list of memory pool names. */ - static String[] getMemoryPoolNames() - { - return new String[0]; - } + static native String[] getMemoryPoolNames(); /** * Return a list of the names of the currently available @@ -66,10 +63,7 @@ final class VMManagementFactory * * @return a list of memory manager names. */ - static String[] getMemoryManagerNames() - { - return new String[0]; - } + static native String[] getMemoryManagerNames(); /** * Return a list of the names of the currently available @@ -77,8 +71,5 @@ final class VMManagementFactory * * @return a list of garbage collector names. */ - static String[] getGarbageCollectorNames() - { - return new String[0]; - } + static native String[] getGarbageCollectorNames(); } diff --git a/libjava/java/lang/management/natVMManagementFactory.cc b/libjava/java/lang/management/natVMManagementFactory.cc new file mode 100644 index 00000000000..35a418bb338 --- /dev/null +++ b/libjava/java/lang/management/natVMManagementFactory.cc @@ -0,0 +1,44 @@ +/* Copyright (C) 2006 Free Software Foundation + + This file is part of libgcj. + +This software is copyrighted work licensed under the terms of the +Libgcj License. Please consult the file "LIBGCJ_LICENSE" for +details. */ + +/** + * @author Andrew John Hughes <gnu_andrew@member.fsf.org> + * @date Tue 08 Aug 2006 */ +/* Implemented for our sole pool, the heap, and our sole memory + * manager/garbage collector, Boehm GC. + * Status: Believed complete and correct. + */ + +#include <config.h> + +#include <gcj/cni.h> +#include <java/lang/String.h> +#include <java/lang/management/VMManagementFactory.h> + +JArray< ::java::lang::String *> * +java::lang::management::VMManagementFactory::getMemoryPoolNames () +{ + return (JArray<jstring>*) + JvNewObjectArray(1, &java::lang::String::class$, JvNewStringLatin1("Heap")); +} + + +JArray< ::java::lang::String *> * +java::lang::management::VMManagementFactory::getMemoryManagerNames () +{ + return (JArray<jstring>*) + JvNewObjectArray(0, &java::lang::String::class$, NULL); +} + + +JArray< ::java::lang::String *> * +java::lang::management::VMManagementFactory::getGarbageCollectorNames () +{ + return (JArray<jstring>*) + JvNewObjectArray(1, &java::lang::String::class$, JvNewStringLatin1("BoehmGC")); +} |