Commit c681b5af authored by Phuong Khanh Tran's avatar Phuong Khanh Tran
Browse files

Update Molecule.java

parent e0650809
Loading
Loading
Loading
Loading
+9 −2
Original line number Diff line number Diff line
@@ -69,11 +69,13 @@ public class Molecule implements Serializable {

        // Compare the number of elements
        if (!Arrays.equals(this.numElements, otherMolecule.numElements)) {
//            System.out.println("different numElements");
            return null; // Number of elements is different, molecules are not equal
        }

        // Compare the number of edges
        if (this.numEdges != otherMolecule.numEdges) {
//            System.out.println("different numEdges");
            return null; // Number of edges is different, molecules are not equal
        }

@@ -125,6 +127,7 @@ public class Molecule implements Serializable {
    }



    /**
     * Finds the Most Similar Molecule
     */
@@ -341,6 +344,7 @@ public class Molecule implements Serializable {
            }

        }

    }
    

@@ -351,6 +355,10 @@ public class Molecule implements Serializable {
        return numAtoms;
    }

    public ArrayList<Atom> getAtomArrayList() {
        return  atomArrayList;
    }

    class subGraphNode implements Serializable {
        public subGraphNode parent;
        public ArrayList<Atom> options;
@@ -362,6 +370,5 @@ public class Molecule implements Serializable {
        }
    };


}