class ThemisCpUtil {

  public static Pair<List<KeyValue>, List<KeyValue>> seperateLockAndWriteKvs(List<KeyValue> kvs) {
    List<KeyValue> lockKvs = new ArrayList<KeyValue>();
    List<KeyValue> writeKvs = new ArrayList<KeyValue>();
    if (kvs != null) {
      for (KeyValue kv : kvs) {
        if (ColumnUtil.isLockColumn(kv.getFamily(), kv.getQualifier())) {
          lockKvs.add(kv);
        } else if (ColumnUtil.isWriteColumn(kv.getFamily(), kv.getQualifier())) {
          writeKvs.add(kv);
        }
      }
    }
    return new Pair<List<KeyValue>, List<KeyValue>>(lockKvs, writeKvs);
  }

}