| 696 | } |
| 697 | |
| 698 | @Override |
| 699 | public boolean equals(Object o) { |
| 700 | if (this == o) return true; |
| 701 | if (!(o instanceof Index)) return false; |
| 702 | |
| 703 | Index index = (Index) o; |
| 704 | if (unique != index.unique) { |
| 705 | return false; |
| 706 | } |
| 707 | if (!columns.equals(index.columns)) { |
| 708 | return false; |
| 709 | } |
| 710 | if (!orders.equals(index.orders)) { |
| 711 | return false; |
| 712 | } |
| 713 | if (name.startsWith(Index.DEFAULT_PREFIX)) { |
| 714 | return index.name.startsWith(Index.DEFAULT_PREFIX); |
| 715 | } else { |
| 716 | return name.equals(index.name); |
| 717 | } |
| 718 | } |
| 719 | |
| 720 | @Override |
| 721 | public int hashCode() { |