Package org.kiji.schema.avro

Examples of org.kiji.schema.avro.RowKeyEncoding


   */
  public static JsonEntityIdParser create(
      final EntityId entityId,
      final KijiTableLayout layout) throws IOException {
    final Object keysFormat = layout.getDesc().getKeysFormat();
    final RowKeyEncoding encoding = getEncoding(keysFormat);
    // Either we are dealing with a hash_prefix entity_id in which case it's not wildcarded
    // and it's a single component entity_id. If we are dealing with a formatted entity_id
    // then either the materialization of the rowkey was suppressed (in which case it's as good as
    // a hashed rowkey) or it's a normal componentized rowkey.
    switch (encoding) {
View Full Code Here


   * Ensure a row key format (version 1) specified in a layout file is sane.
   * @param format The RowKeyFormat created from the layout file for a table.
   * @throws InvalidLayoutException If the format is invalid.
   */
  private void isValidRowKeyFormat1(RowKeyFormat format) throws InvalidLayoutException {
    RowKeyEncoding rowKeyEncoding = format.getEncoding();
    if (rowKeyEncoding != RowKeyEncoding.RAW
        && rowKeyEncoding != RowKeyEncoding.HASH
        && rowKeyEncoding != RowKeyEncoding.HASH_PREFIX) {
      throw new InvalidLayoutException("RowKeyFormat only supports encodings"
          + "of type RAW, HASH and HASH_PREFIX. Use RowKeyFormat2 instead");
View Full Code Here

TOP

Related Classes of org.kiji.schema.avro.RowKeyEncoding

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.