FileDocCategorySizeDatePackage
Ch03_01.javaAPI DocExample807Thu Oct 23 13:07:54 BST 2003org.eclipsebook.ch03

Ch03_01

public class Ch03_01 extends Object
author
Steven Holzner To change the template for this generated type comment go to Window>Preferences>Java>Code Generation>Code and Comments

Fields Summary
private int[]
array
Constructors Summary
Methods Summary
public int[]allocate()

		array = new int[3];  
		array[0] = 0;
		array[1] = 1;
		array[2] = 2;	
		return array;
	
public intget(int index)

		return array[index];
	
public booleanset(int index, int value)

		if (index < array.length && index >= 0) {
			array[index] = value;
			return true;
		} else {
			return false;
		}