| 1 | /* **************************************************************************** |
| 2 | Licensed under the Apache License, Version 2.0 (the "License"); |
| 3 | you may not use this file except in compliance with the License. |
| 4 | You may obtain a copy of the License at |
| 5 | |
| 6 | http://www.apache.org/licenses/LICENSE-2.0 |
| 7 | |
| 8 | Unless required by applicable law or agreed to in writing, software |
| 9 | distributed under the License is distributed on an "AS IS" BASIS, |
| 10 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 11 | See the License for the specific language governing permissions and |
| 12 | limitations under the License. |
| 13 | |
| 14 | See NOTICE file for details. |
| 15 | **************************************************************************** */ |
| 16 | package jpype.array; |
| 17 | |
| 18 | public class TestArray |
| 19 | { |
| 20 | |
| 21 | public TestArray() |
| 22 | { |
| 23 | |
| 24 | } |
| 25 | |
| 26 | public int[] i = |
| 27 | { |
| 28 | 12234, 1234, 234, 1324, 424, 234, 234, 142, 5, 251, 242, 35, 235, 62, 1235, 46, 245132, 51, 2, 3, 4 |
| 29 | }; |
| 30 | |
| 31 | public Object[] getSubClassArray() |
| 32 | { |
| 33 | return new Integer[] |
| 34 | { |
| 35 | 1, 2 |
| 36 | }; |
| 37 | } |
| 38 | |
| 39 | public Object getArrayAsObject() |
| 40 | { |
| 41 | return new String[] |
| 42 | { |
| 43 | "aaa", "bbb" |
| 44 | }; |
| 45 | } |
| 46 | |
| 47 | public char[] getCharArray() |
| 48 | { |
| 49 | return new char[] |
| 50 | { |
| 51 | 'a', 'v', 'c', 'd' |
| 52 | }; |
| 53 | } |
| 54 | |
| 55 | public byte[] getByteArray() |
| 56 | { |
| 57 | String s = "avcd"; |
| 58 | return s.getBytes(); |
| 59 | } |
| 60 | |
| 61 | public Object testObject(Object obj) |
| 62 | { |
| 63 | return obj; |
| 64 | } |
| 65 | |
| 66 | public Object testInt(int[] obj) |
| 67 | { |
| 68 | return obj; |
| 69 | } |
| 70 | } |