1/**
2 * Licensed to the Apache Software Foundation (ASF) under one
3 * or more contributor license agreements.  See the NOTICE file
4 * distributed with this work for additional information
5 * regarding copyright ownership.  The ASF licenses this file
6 * to you under the Apache License, Version 2.0 (the
7 * "License"); you may not use this file except in compliance
8 * with the License.  You may obtain a copy of the License at
9 *
10 *     http://www.apache.org/licenses/LICENSE-2.0
11 *
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
17 */
18
19// Cell and KeyValue protos
20
21option java_package = "org.apache.hadoop.hbase.protobuf.generated";
22option java_outer_classname = "CellProtos";
23option java_generate_equals_and_hash = true;
24option optimize_for = SPEED;
25
26/**
27 * The type of the key in a Cell
28 */
29enum CellType {
30    MINIMUM = 0;
31    PUT = 4;
32
33    DELETE = 8;
34    DELETE_COLUMN = 12;
35    DELETE_FAMILY = 14;
36
37    // MAXIMUM is used when searching; you look from maximum on down.
38    MAXIMUM = 255;
39}
40
41/**
42 * Protocol buffer version of Cell.
43 */
44message Cell {
45  optional bytes row = 1;
46  optional bytes family = 2;
47  optional bytes qualifier = 3;
48  optional uint64 timestamp = 4;
49  optional CellType cell_type = 5;
50  optional bytes value = 6;
51  optional bytes tags = 7;
52}
53
54/**
55 * Protocol buffer version of KeyValue.
56 * It doesn't have those transient parameters
57 */
58message KeyValue {
59  required bytes row = 1;
60  required bytes family = 2;
61  required bytes qualifier = 3;
62  optional uint64 timestamp = 4;
63  optional CellType key_type = 5;
64  optional bytes value = 6;
65  optional bytes tags = 7;
66}
67