< prev index next >
test/hotspot/jtreg/vmTestbase/nsk/monitoring/share/server/ServerThreadMXBeanNew.java
Print this page
*** 1,7 ****
/*
! * Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
--- 1,7 ----
/*
! * Copyright (c) 2011, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*** 57,66 ****
--- 57,72 ----
return (Long) invokeMethod("getThreadAllocatedBytes",
new Object[] { id },
new String[] { long.class.getName() });
}
+ public long getCurrentThreadAllocatedBytes() {
+ return (Long) invokeMethod("getCurrentThreadAllocatedBytes",
+ new Object[] { },
+ new String[] { });
+ }
+
public void setThreadAllocatedMemoryEnabled(boolean enabled) {
setBooleanAttribute("ThreadAllocatedMemoryEnabled", enabled);
}
public boolean isThreadAllocatedMemorySupported() {
< prev index next >