com.vaadin.v7.data.util.sqlcontainer.ReadOnlyRowId Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of vaadin-compatibility-server Show documentation
Show all versions of vaadin-compatibility-server Show documentation
Vaadin 7 compatibility package for Vaadin 8
/*
* Copyright (C) 2000-2024 Vaadin Ltd
*
* This program is available under Vaadin Commercial License and Service Terms.
*
* See for the full
* license.
*/
package com.vaadin.v7.data.util.sqlcontainer;
/**
* @deprecated As of 8.0, no replacement available.
*/
@Deprecated
public class ReadOnlyRowId extends RowId {
private static final long serialVersionUID = -2626764781642012467L;
private final Integer rowNum;
public ReadOnlyRowId(int rowNum) {
super();
this.rowNum = rowNum;
}
@Override
public int hashCode() {
return getRowNum();
}
@Override
public boolean equals(Object obj) {
if (obj == null || !(ReadOnlyRowId.class.equals(obj.getClass()))) {
return false;
}
return getRowNum() == (((ReadOnlyRowId) obj).getRowNum());
}
public int getRowNum() {
return rowNum;
}
@Override
public String toString() {
return String.valueOf(getRowNum());
}
}