Class: Google::Cloud::Bigtable::ColumnRange
- Inherits:
-
Object
- Object
- Google::Cloud::Bigtable::ColumnRange
- Defined in:
- lib/google/cloud/bigtable/column_range.rb
Overview
ColumnRange
Specifies a contiguous range of column qualifiers.
- Start qualifier bound : The qualifier at which to start the range. If neither field is set, interpreted as the empty string, inclusive.
- End qualifier bound: The qualifier at which to end the range. If neither field is set, interpreted as the infinite string qualifier, exclusive.
Instance Method Summary collapse
-
#between(from_qualifier, to_qualifier) ⇒ Google::Cloud::Bigtable::ColumnRange
Sets the column range with the inclusive upper and lower bound.
-
#family ⇒ String
Gets the column family name.
-
#family=(name) ⇒ Object
Sets the column family name.
-
#from(qualifier, inclusive: true) ⇒ Google::Cloud::Bigtable::ColumnRange
Sets the column range with the lower bound.
-
#initialize(family) ⇒ ColumnRange
constructor
Create qualifier range instance.
-
#of(from_qualifier, to_qualifier) ⇒ Google::Cloud::Bigtable::ColumnRange
Sets the column range with the inclusive upper and the exclusive lower bound.
-
#to(qualifier, inclusive: false) ⇒ Google::Cloud::Bigtable::ColumnRange
Sets the column range with the upper bound.
Constructor Details
#initialize(family) ⇒ ColumnRange
Create qualifier range instance.
58 59 60 |
# File 'lib/google/cloud/bigtable/column_range.rb', line 58 def initialize family @grpc = Google::Bigtable::V2::ColumnRange.new family_name: family end |
Instance Method Details
#between(from_qualifier, to_qualifier) ⇒ Google::Cloud::Bigtable::ColumnRange
Sets the column range with the inclusive upper and lower bound.
161 162 163 |
# File 'lib/google/cloud/bigtable/column_range.rb', line 161 def between from_qualifier, to_qualifier from(from_qualifier).to(to_qualifier, inclusive: true) end |
#family ⇒ String
Gets the column family name.
67 68 69 |
# File 'lib/google/cloud/bigtable/column_range.rb', line 67 def family @grpc.family_name end |
#family=(name) ⇒ Object
Sets the column family name.
76 77 78 |
# File 'lib/google/cloud/bigtable/column_range.rb', line 76 def family= name @grpc.family_name = name end |
#from(qualifier, inclusive: true) ⇒ Google::Cloud::Bigtable::ColumnRange
Sets the column range with the lower bound.
104 105 106 107 108 109 110 111 |
# File 'lib/google/cloud/bigtable/column_range.rb', line 104 def from qualifier, inclusive: true if inclusive @grpc.start_qualifier_closed = qualifier else @grpc.start_qualifier_open = qualifier end self end |
#of(from_qualifier, to_qualifier) ⇒ Google::Cloud::Bigtable::ColumnRange
Sets the column range with the inclusive upper and the exclusive lower bound.
180 181 182 |
# File 'lib/google/cloud/bigtable/column_range.rb', line 180 def of from_qualifier, to_qualifier from(from_qualifier).to(to_qualifier) end |
#to(qualifier, inclusive: false) ⇒ Google::Cloud::Bigtable::ColumnRange
Sets the column range with the upper bound.
137 138 139 140 141 142 143 144 |
# File 'lib/google/cloud/bigtable/column_range.rb', line 137 def to qualifier, inclusive: false if inclusive @grpc.end_qualifier_closed = qualifier else @grpc.end_qualifier_open = qualifier end self end |