All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.flipkart.hbaseobjectmapper.HBRecord Maven / Gradle / Ivy

Go to download

HBase ORM is a light-weight, thread-safe and performant library that enables: [1] object-oriented access of HBase rows (Data Access Object) with minimal code and good testability [2] reading from and/or writing to HBase tables in Hadoop MapReduce jobs

There is a newer version: 1.19
Show newest version
package com.flipkart.hbaseobjectmapper;

import java.io.Serializable;
import java.math.BigDecimal;

/**
 * Entities that need to be mapped to HBase tables need to implement this generic interface
 *
 * @param  Data type of row key, which should be '{@link Comparable} with itself' and must be {@link Serializable} (e.g. {@link String}, {@link Integer}, {@link BigDecimal} etc. or your own POJO)
 */
public interface HBRecord> extends Serializable {

    /**
     * Composes the row key required for HBase from class variables
     *
     * @return Row key as {@link Serializable} data type
     */
    R composeRowKey();

    /**
     * Assigns the class variables from row key string (from HBase) provided
     *
     * @param rowKey Row key as {@link Serializable} data type
     */
    void parseRowKey(R rowKey);

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy