Skip to content

Commit

Permalink
comments for future refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
Nodar Tchumbadze committed Jan 26, 2015
1 parent a33a7ea commit 80503e9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
Binary file modified bin/com/nodrex/datamatrix/DataMatrix.class
Binary file not shown.
12 changes: 5 additions & 7 deletions src/com/nodrex/datamatrix/DataMatrix.java
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,7 @@ protected IDataMatrix<Data> clone() throws CloneNotSupportedException {
* Removes id of this matrix form ids list.
*/
protected void finalize() throws Throwable {
if (this.id.equals(""))
return;
if (this.id.equals("")) return;
DataMatrix.ids.remove(this.id);
}

Expand Down Expand Up @@ -117,12 +116,9 @@ public String toString() {
*
* @return true if both matrixes have same dimension and same data,
* otherwise returns false.
* @throws NullPointerException
* if given parameter is null.
*/
public boolean equals(Object obj) throws NullPointerException {
if (obj == null)
throw new NullPointerException();
public boolean equals(Object obj) {
if (obj == null) return false;
if (obj instanceof DataMatrix) {
try {
@SuppressWarnings("unchecked")
Expand Down Expand Up @@ -726,6 +722,7 @@ public String getId() {
return new String(this.id);
}

//getData_s magivrad sxva rame unda gavaketo , romelic monacemebs daakopirebs. aman imena am obietis data unda daabrunos.
public Object[][] getData() {
//correct will be return this.data and other code should be commented
Object[][] newData = new Object[this.linedimension][this.columndimension];
Expand All @@ -744,6 +741,7 @@ public void setData(Data[]... data) throws NullPointerException {
for (int i = 0; i < data.length; i++) {
lengthList.add(data[i].length);
}
//TODO imis magivrad , rom mere maxi davutvalo pirvelive iteraciashive unda davitvalo maxi. am shemtxevashi listis shemnac ar iqneba sachiro
init(data.length, Collections.max(lengthList));
//i think here should be this.data = data;
//this.fill(data) should be commented.
Expand Down

0 comments on commit 80503e9

Please sign in to comment.