for (Map.Entry> entry : cells.entrySet()) {
Mutation m = new Mutation(ByteBufferUtil.toBytes(entry.getKey()));
<<<<<<< HEAD
addUpdatesToMutation(vizMap, m, entry.getValue());
=======
for (ColumnUpdate update : entry.getValue()) {
ColumnVisibility viz = EMPTY_VIS;
if (update.isSetColVisibility()) {
Text vizText = new Text(update.getColVisibility());
viz = vizMap.get(vizText);
if (viz == null) {
vizMap.put(vizText, viz = new ColumnVisibility(vizText));
}
}
byte[] value = new byte[0];
if (update.isSetValue())
value = update.getValue();
if (update.isSetTimestamp()) {
if (update.isSetDeleteCell() && update.isDeleteCell()) {
m.putDelete(update.getColFamily(), update.getColQualifier(), viz, update.getTimestamp());
} else {
m.put(new Text(update.getColFamily()), new Text(update.getColQualifier()), viz, update.getTimestamp(), new Value(value));
}
} else {
if (update.isSetDeleteCell() && update.isDeleteCell()) {
m.putDelete(new Text(update.getColFamily()), new Text(update.getColQualifier()), viz);
} else {
m.put(new Text(update.getColFamily()), new Text(update.getColQualifier()), viz, new Value(value));
}
}
}
>>>>>>> cfb832a1f1d7fa975bd837fbdbdb152aba4cf050
try {
bwpe.writer.addMutation(m);
} catch (MutationsRejectedException mre) { |