ColumnDescriptorAdapter (Cloud Bigtable HBase Client for Java 1.6.0 API)

com.google.cloud.bigtable.hbase.adapters.admin

Class ColumnDescriptorAdapter

  • java.lang.Object
    • com.google.cloud.bigtable.hbase.adapters.admin.ColumnDescriptorAdapter


  • public class ColumnDescriptorAdapter
    extends Object
    Adapt a single instance of an HBase HColumnDescriptor to an instance of ColumnFamily
    Version:
    $Id: $Id
    Author:
    sduskis
    • Field Detail

      • SUPPORTED_OPTION_KEYS

        public static final Set<String> SUPPORTED_OPTION_KEYS
        Configuration keys that we can support unconditionally and we provide a mapped version of the column descriptor to Bigtable.
      • IGNORED_OPTION_KEYS

        public static final Set<String> IGNORED_OPTION_KEYS
        Configuration keys that we ignore unconditionally
      • SUPPORTED_OPTION_VALUES

        public static final Map<String,String> SUPPORTED_OPTION_VALUES
        Configuration option values that we ignore as long as the value is the one specified below. Any other value results in an exception.
    • Constructor Detail

      • ColumnDescriptorAdapter

        public ColumnDescriptorAdapter()
    • Method Detail

      • getUnknownFeatures

        public static List<String> getUnknownFeatures(HColumnDescriptor columnDescriptor)
        Build a list of configuration keys that we don't know how to handle
        Parameters:
        columnDescriptor - a HColumnDescriptor object.
        Returns:
        a List object.
      • getUnsupportedFeatures

        public static Map<String,String> getUnsupportedFeatures(HColumnDescriptor columnDescriptor)
        Build a Map of configuration keys and values describing configuration values we don't support.
        Parameters:
        columnDescriptor - a HColumnDescriptor object.
        Returns:
        a Map object.
      • throwIfRequestingUnsupportedFeatures

        public static void throwIfRequestingUnsupportedFeatures(HColumnDescriptor columnDescriptor)
        Throw an UnsupportedOperationException if the column descriptor cannot be adapted due to it having configuration values that are not supported.
        Parameters:
        columnDescriptor - a HColumnDescriptor object.
      • buildGarbageCollectionRule

        public static com.google.bigtable.admin.v2.GcRule buildGarbageCollectionRule(HColumnDescriptor columnDescriptor)
        Construct an Bigtable GcRule from the given column descriptor.
        Parameters:
        columnDescriptor - a HColumnDescriptor object.
        Returns:
        a GcRule object.
      • processIntersection

        protected static void processIntersection(com.google.bigtable.admin.v2.GcRule gcRule,
                                                  HColumnDescriptor columnDescriptor)

        processIntersection.

        Parameters:
        gcRule - a GcRule object.
        columnDescriptor - a HColumnDescriptor object.
      • adapt

        public com.google.bigtable.admin.v2.ColumnFamily adapt(HColumnDescriptor columnDescriptor)

        Adapt a single instance of an HBase HColumnDescriptor to an instance of ColumnFamily.Builder.

        NOTE: This method does not set the name of the ColumnFamily.Builder. The assumption is that the CreateTableRequest or CreateColumFamilyRequest takes care of the naming. As of now (3/11/2015), the server insists on having a blank name.

        Parameters:
        columnDescriptor - a HColumnDescriptor object.
        Returns:
        a ColumnFamily.Builder object.


Was this page helpful? Let us know how we did:

Send feedback about...

Cloud Bigtable Documentation