public void setValueAt(int x, int y, int value) { synchronized(array) { array[x][y]=value; } repaint(); }
public void multiplyValueWith(int x, int y, int value) { synchronized(array) { array[x][y]*=value; repaint(); } }
public void addValueTo(int x, int y, int value) { synchronized(array) { array[x][y]+=value; repaint(); } }
public void subtractValueFrom(int x, int y, int value) { synchronized(array) { array[x][y]-=value; repaint(); } }
public void divideValueBy(int x, int y, int value) { if(value == 0) return; synchronized(array) { array[x][y]/=value; repaint(); } }
public void clear() { synchronized(array) { for(int i=0; i < num_fields; i++) for(int j=0; j < num_fields; j++) array[i][j]=0; checksum=checksum(); repaint(); } }
public void update() { checksum=checksum(); repaint(); }
public void setState(Object new_state) { if(new_state == null) return; try { int[][] new_array=(int[][])new_state; synchronized(array) { clear(); for(int i=0; i < num_fields; i++) System.arraycopy(new_array[i], 0, array[i], 0, num_fields); checksum=checksum(); repaint(); } } catch(Exception e) { System.err.println(e); } }
public void addValueTo(int x, int y, int value) { synchronized(array) { array[x][y]+=value; repaint(); } }
public void divideValueBy(int x, int y, int value) { if(value == 0) return; synchronized(array) { array[x][y]/=value; repaint(); } }
public void multiplyValueWith(int x, int y, int value) { synchronized(array) { array[x][y]*=value; repaint(); } }
public void setValueAt(int x, int y, int value) { synchronized(array) { array[x][y]=value; } repaint(); }
public void multiplyValueWith(int x, int y, int value) { synchronized(array) { array[x][y]*=value; repaint(); } }
public void subtractValueFrom(int x, int y, int value) { synchronized(array) { array[x][y]-=value; repaint(); } }
public void divideValueBy(int x, int y, int value) { if(value == 0) return; synchronized(array) { array[x][y]/=value; repaint(); } }
public void addValueTo(int x, int y, int value) { synchronized(array) { array[x][y]+=value; repaint(); } }
public void setValueAt(int x, int y, int value) { synchronized(array) { array[x][y]=value; } repaint(); }
public void clear() { synchronized(array) { for(int i=0; i < num_fields; i++) for(int j=0; j < num_fields; j++) array[i][j]=0; checksum=checksum(); repaint(); } }
public void update() { checksum=checksum(); repaint(); }
public void clear() { synchronized(array) { for(int i=0; i < num_fields; i++) for(int j=0; j < num_fields; j++) array[i][j]=0; checksum=checksum(); repaint(); } }