BigtableInstanceName (Cloud Bigtable HBase Client for Java 1.12.0 API)

com.google.cloud.bigtable.grpc

Class BigtableInstanceName

  • All Implemented Interfaces:
    Serializable


    public class BigtableInstanceName
    extends Object
    implements Serializable
    This class encapsulates a Bigtable instance name. An instance name is of the form projects/(projectId)/instances/(instanceId). It also has convenience methods to create a tableName and a tableId. TableName is (instanceName)/tables/(tableId).
    Version:
    $Id: $Id
    Author:
    sduskis
    See Also:
    Serialized Form
    • Field Detail

      • BIGTABLE_V2_INSTANCE_FMT

        public static final String BIGTABLE_V2_INSTANCE_FMT
        Constant BIGTABLE_V2_INSTANCE_FMT="projects/%s/instances/%s"
        See Also:
        Constant Field Values
    • Constructor Detail

      • BigtableInstanceName

        public BigtableInstanceName(String projectId,
                                    String instanceId)
        Constructor for BigtableInstanceName.
        Parameters:
        projectId - a String object.
        instanceId - a String object.
    • Method Detail

      • toTableId

        public String toTableId(String tableName)
        Transforms a tableName within this instance of the form projects/(projectId)/instances/(instanceId)/tables/(tableId) to (tableId).
        Parameters:
        tableName - a String object.
        Returns:
        a String object.
      • toTableNameStr

        public String toTableNameStr(String tableId)
        toTableNameStr.
        Parameters:
        tableId - a String object.
        Returns:
        a String object.
      • getProjectId

        public String getProjectId()
        Returns:
        the projectId
      • getInstanceId

        public String getInstanceId()
        Returns:
        the instanceId
      • getInstanceName

        public String getInstanceName()
        Returns:
        the fully qualified instanceName with the form 'projects/{projectId}/instances/{instanceId}'.