equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 1999, 2003, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 1999, 2014, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * |
4 * |
5 * This code is free software; you can redistribute it and/or modify it |
5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as |
6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. Oracle designates this |
7 * published by the Free Software Foundation. Oracle designates this |
292 if (band == destinationBands[j]) { |
292 if (band == destinationBands[j]) { |
293 throw new IllegalArgumentException("Duplicate band value!"); |
293 throw new IllegalArgumentException("Duplicate band value!"); |
294 } |
294 } |
295 } |
295 } |
296 } |
296 } |
297 this.destinationBands = (int[])destinationBands.clone(); |
297 this.destinationBands = destinationBands.clone(); |
298 } |
298 } |
299 } |
299 } |
300 |
300 |
301 /** |
301 /** |
302 * Returns the set of band indices where data will be placed. |
302 * Returns the set of band indices where data will be placed. |
310 */ |
310 */ |
311 public int[] getDestinationBands() { |
311 public int[] getDestinationBands() { |
312 if (destinationBands == null) { |
312 if (destinationBands == null) { |
313 return null; |
313 return null; |
314 } else { |
314 } else { |
315 return (int[])(destinationBands.clone()); |
315 return destinationBands.clone(); |
316 } |
316 } |
317 } |
317 } |
318 |
318 |
319 /** |
319 /** |
320 * Returns <code>true</code> if this reader allows the source |
320 * Returns <code>true</code> if this reader allows the source |