Path: blob/master/test/hotspot/jtreg/vmTestbase/nsk/jdi/ArrayReference/getValues/getvalues003a.java
41162 views
/*1* Copyright (c) 2002, 2018, Oracle and/or its affiliates. All rights reserved.2* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.3*4* This code is free software; you can redistribute it and/or modify it5* under the terms of the GNU General Public License version 2 only, as6* published by the Free Software Foundation.7*8* This code is distributed in the hope that it will be useful, but WITHOUT9* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or10* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License11* version 2 for more details (a copy is included in the LICENSE file that12* accompanied this code).13*14* You should have received a copy of the GNU General Public License version15* 2 along with this work; if not, write to the Free Software Foundation,16* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.17*18* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA19* or visit www.oracle.com if you need additional information or have any20* questions.21*/2223package nsk.jdi.ArrayReference.getValues;2425import nsk.share.*;26import nsk.share.jpda.*;27import nsk.share.jdi.*;282930public class getvalues003a {3132static getvalues003aClassToCheck testedObj = new getvalues003aClassToCheck();3334public static void main (String argv[]) {3536ArgumentHandler argHandler = new ArgumentHandler(argv);37Log log = new Log(System.err, argHandler);38IOPipe pipe = argHandler.createDebugeeIOPipe(log);3940pipe.println("ready");4142String instruction = pipe.readln();4344if ( instruction.equals("quit") ) {45log.display("DEBUGEE> \"quit\" signal recieved.");46log.display("DEBUGEE> completed succesfully.");47System.exit(getvalues003.TEST_FAILED + getvalues003.JCK_STATUS_BASE);48}49log.complain("DEBUGEE FAILURE> unexpected signal "50+ "(no \"quit\") - " + instruction);51log.complain("DEBUGEE FAILURE> TEST FAILED");52System.exit(getvalues003.TEST_FAILED + getvalues003.JCK_STATUS_BASE);53}54}5556class getvalues003aClassToCheck {57static int[] staticIntArr = {};58static Object[] staticObjArr = {};5960public int[] publicIntArrC;61protected int[] protecIntArrC;62private int[] privatIntArrC;6364public Object[] publicObjArrC;65protected Object[] protecObjArrC;66private Object[] privatObjArrC;6768public getvalues003aClassToCheck() {69publicIntArrC = createIntArray();70protecIntArrC = createIntArray();71privatIntArrC = createIntArray();7273publicObjArrC = createObjArray();74protecObjArrC = createObjArray();75privatObjArrC = createObjArray();76}7778static private int[] createIntArray() {79return new int[0];80}8182static private Object[] createObjArray() {83return new Object[0];84}8586}878889