code: func (r *Region) Contains(key []byte) bool {
  	return bytes.Compare(r.meta.GetStartKey(), key) <= 0 &&
  		(bytes.Compare(key, r.meta.GetEndKey()) < 0 || len(r.meta.GetEndKey()) == 0)
  }
docs: // Contains checks whether the key is in the region, for the maximum region endKey is empty.
  // startKey <= key < endKey.