|
|
@ -4,15 +4,15 @@ import javax.swing.AbstractListModel; |
|
|
|
|
|
|
|
|
|
|
|
public class ArrayListModel extends AbstractListModel { |
|
|
|
public class ArrayListModel extends AbstractListModel { |
|
|
|
private Object[] array; |
|
|
|
private Object[] array; |
|
|
|
|
|
|
|
|
|
|
|
public ArrayListModel() { |
|
|
|
public ArrayListModel() { |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public ArrayListModel(Object[] array) { |
|
|
|
public ArrayListModel(Object[] array) { |
|
|
|
this.array = array; |
|
|
|
this.array = array; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public Object getElementAt(int index) { |
|
|
|
public Object getElementAt(int index) { |
|
|
|
return array != null ? array[index] : null; |
|
|
|
return array != null ? array[index] : null; |
|
|
|
} |
|
|
|
} |
|
|
|