@Override public int compareTo(TabletFragmentInfo o) { return tabletInfoImpl != null ? tabletInfoImpl.compareTo(o.tabletInfoImpl) : regionInfo.compareTo(o.regionInfo); }
public boolean containsRow(byte[] row) { return tabletInfoImpl != null ? tabletInfoImpl.containsRow(row) : regionInfo.containsRow(row); }
@Override public boolean equals(Object obj) { if (this == obj) { return true; } if (obj == null) { return false; } if (getClass() != obj.getClass()) { return false; } TabletFragmentInfo other = (TabletFragmentInfo) obj; if (regionInfo == null) { if (other.regionInfo != null) { return false; } } else if (!regionInfo.equals(other.regionInfo)) { return false; } if (tabletInfoImpl == null) { if (other.tabletInfoImpl != null) { return false; } } else if (!tabletInfoImpl.equals(other.tabletInfoImpl)) { return false; } return true; }
@Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + ((regionInfo == null) ? 0 : regionInfo.hashCode()); result = prime * result + ((tabletInfoImpl == null) ? 0 : tabletInfoImpl.hashCode()); return result; }
public byte[] getStartKey() { return tabletInfoImpl != null ? tabletInfoImpl.getStartRow() : regionInfo.getStartKey(); }
public byte[] getEndKey() { return tabletInfoImpl != null ? tabletInfoImpl.getStopRow() : regionInfo.getEndKey(); }
protected MapRDBSubScanSpec getSubScanSpec(final TabletFragmentInfo tfi) { // XXX/TODO check filter/Condition final JsonScanSpec spec = scanSpec; final String serverHostName = getRegionsToScan().get(tfi); QueryCondition condition = tfi.getTabletInfoImpl().getCondition(); byte[] startRow = condition == null ? null : ((ConditionImpl) condition).getRowkeyRanges().get(0).getStartRow(); byte[] stopRow = condition == null ? null : ((ConditionImpl) condition).getRowkeyRanges().get(0).getStopRow(); JsonSubScanSpec subScanSpec = new JsonSubScanSpec( spec.getTableName(), spec.getIndexDesc(), serverHostName, tfi.getTabletInfoImpl().getCondition(), spec.getCondition(), startRow, stopRow, getUserName()); return subScanSpec; }
@Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + ((regionInfo == null) ? 0 : regionInfo.hashCode()); result = prime * result + ((tabletInfoImpl == null) ? 0 : tabletInfoImpl.hashCode()); return result; }
public byte[] getStartKey() { return tabletInfoImpl != null ? tabletInfoImpl.getStartRow() : regionInfo.getStartKey(); }
public byte[] getEndKey() { return tabletInfoImpl != null ? tabletInfoImpl.getStopRow() : regionInfo.getEndKey(); }
protected MapRDBSubScanSpec getSubScanSpec(final TabletFragmentInfo tfi) { // XXX/TODO check filter/Condition final JsonScanSpec spec = scanSpec; final String serverHostName = getRegionsToScan().get(tfi); QueryCondition condition = tfi.getTabletInfoImpl().getCondition(); byte[] startRow = condition == null ? null : ((ConditionImpl) condition).getRowkeyRanges().get(0).getStartRow(); byte[] stopRow = condition == null ? null : ((ConditionImpl) condition).getRowkeyRanges().get(0).getStopRow(); JsonSubScanSpec subScanSpec = new JsonSubScanSpec( spec.getTableName(), spec.getIndexDesc(), serverHostName, tfi.getTabletInfoImpl().getCondition(), spec.getCondition(), startRow, stopRow, getUserName()); return subScanSpec; }
@Override public int compareTo(TabletFragmentInfo o) { return tabletInfoImpl != null ? tabletInfoImpl.compareTo(o.tabletInfoImpl) : regionInfo.compareTo(o.regionInfo); }
public boolean containsRow(byte[] row) { return tabletInfoImpl != null ? tabletInfoImpl.containsRow(row) : regionInfo.containsRow(row); }
@Override public boolean equals(Object obj) { if (this == obj) { return true; } if (obj == null) { return false; } if (getClass() != obj.getClass()) { return false; } TabletFragmentInfo other = (TabletFragmentInfo) obj; if (regionInfo == null) { if (other.regionInfo != null) { return false; } } else if (!regionInfo.equals(other.regionInfo)) { return false; } if (tabletInfoImpl == null) { if (other.tabletInfoImpl != null) { return false; } } else if (!tabletInfoImpl.equals(other.tabletInfoImpl)) { return false; } return true; }