@java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { com.google.bigtable.admin.v2.ListTablesRequest parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (com.google.bigtable.admin.v2.ListTablesRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; }
/** * * * <pre> * The view to be applied to the returned tables' fields. * Defaults to `NAME_ONLY` if unspecified; no others are currently supported. * </pre> * * <code>.google.bigtable.admin.v2.Table.View view = 2;</code> */ public Builder setView(com.google.bigtable.admin.v2.Table.View value) { if (value == null) { throw new NullPointerException(); } view_ = value.getNumber(); onChanged(); return this; } /**
/** * Lists all tables served from a specified instance. * * <p>Sample code: * * <pre><code> * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient = BaseBigtableTableAdminClient.create()) { * InstanceName parent = InstanceName.of("[PROJECT]", "[INSTANCE]"); * for (Table element : baseBigtableTableAdminClient.listTables(parent).iterateAll()) { * // doThingsWith(element); * } * } * </code></pre> * * @param parent The unique name of the instance for which tables should be listed. Values are of * the form `projects/<project>/instances/<instance>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final ListTablesPagedResponse listTables(InstanceName parent) { ListTablesRequest request = ListTablesRequest.newBuilder().setParent(parent == null ? null : parent.toString()).build(); return listTables(request); }
/** * Lists all tables served from a specified instance. * * <p>Sample code: * * <pre><code> * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient = BaseBigtableTableAdminClient.create()) { * InstanceName parent = InstanceName.of("[PROJECT]", "[INSTANCE]"); * for (Table element : baseBigtableTableAdminClient.listTables(parent.toString()).iterateAll()) { * // doThingsWith(element); * } * } * </code></pre> * * @param parent The unique name of the instance for which tables should be listed. Values are of * the form `projects/<project>/instances/<instance>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final ListTablesPagedResponse listTables(String parent) { ListTablesRequest request = ListTablesRequest.newBuilder().setParent(parent).build(); return listTables(request); }
public Builder mergeFrom(com.google.bigtable.admin.v2.ListTablesRequest other) { if (other == com.google.bigtable.admin.v2.ListTablesRequest.getDefaultInstance()) return this; if (!other.getParent().isEmpty()) { parent_ = other.parent_; onChanged(); } if (other.view_ != 0) { setViewValue(other.getViewValue()); } if (other.getPageSize() != 0) { setPageSize(other.getPageSize()); } if (!other.getPageToken().isEmpty()) { pageToken_ = other.pageToken_; onChanged(); } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; }
/** * * * <pre> * The view to be applied to the returned tables' fields. * Defaults to `NAME_ONLY` if unspecified; no others are currently supported. * </pre> * * <code>.google.bigtable.admin.v2.Table.View view = 2;</code> */ public Builder setView(com.google.bigtable.admin.v2.Table.View value) { if (value == null) { throw new NullPointerException(); } view_ = value.getNumber(); onChanged(); return this; } /**
/** * * * <pre> * The unique name of the instance for which tables should be listed. * Values are of the form `projects/<project>/instances/<instance>`. * </pre> * * <code>string parent = 1;</code> */ public Builder setParentBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); parent_ = value; onChanged(); return this; }
/** * * * <pre> * The unique name of the instance for which tables should be listed. * Values are of the form `projects/<project>/instances/<instance>`. * </pre> * * <code>string parent = 1;</code> */ public Builder setParent(java.lang.String value) { if (value == null) { throw new NullPointerException(); } parent_ = value; onChanged(); return this; } /**
/** {@inheritDoc} */ @Override public ListenableFuture<List<String>> listTablesAsync() { ListTablesRequest request = ListTablesRequest.newBuilder() .setParent(instanceName.toString()) .build(); ListenableFuture<ListTablesResponse> response = adminClient.listTablesAsync(request); return Futures.transform(response, new Function<ListTablesResponse, List<String>>() { @Override public List<String> apply(ListTablesResponse input) { ImmutableList.Builder<String> tableIdsBuilder = ImmutableList.builder(); for(com.google.bigtable.admin.v2.Table tableProto : input.getTablesList()){ tableIdsBuilder.add(instanceName.toTableId(tableProto.getName())); } return tableIdsBuilder.build(); } }, MoreExecutors.directExecutor()); }
/** * <pre> * The unique name of the instance for which tables should be listed. * Values are of the form projects/<project>/instances/<instance> * </pre> * * <code>string parent = 1;</code> */ public Builder setParent( java.lang.String value) { if (value == null) { throw new NullPointerException(); } parent_ = value; onChanged(); return this; } /**
/** * * * <pre> * The value of `next_page_token` returned by a previous call. * </pre> * * <code>string page_token = 3;</code> */ public Builder setPageToken(java.lang.String value) { if (value == null) { throw new NullPointerException(); } pageToken_ = value; onChanged(); return this; } /**
/** * <pre> * The value of `next_page_token` returned by a previous call. * </pre> * * <code>string page_token = 3;</code> */ public Builder setPageTokenBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); pageToken_ = value; onChanged(); return this; } public final Builder setUnknownFields(
/** * * * <pre> * The value of `next_page_token` returned by a previous call. * </pre> * * <code>string page_token = 3;</code> */ public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); pageToken_ = value; onChanged(); return this; }
/** * <pre> * The unique name of the instance for which tables should be listed. * Values are of the form projects/<project>/instances/<instance> * </pre> * * <code>string parent = 1;</code> */ public Builder setParentBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); parent_ = value; onChanged(); return this; }
/** * <pre> * The value of `next_page_token` returned by a previous call. * </pre> * * <code>string page_token = 3;</code> */ public Builder setPageToken( java.lang.String value) { if (value == null) { throw new NullPointerException(); } pageToken_ = value; onChanged(); return this; } /**
public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { com.google.bigtable.admin.v2.ListTablesRequest parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (com.google.bigtable.admin.v2.ListTablesRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; }
@java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { com.google.bigtable.admin.v2.ListTablesRequest parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (com.google.bigtable.admin.v2.ListTablesRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; }
/** * * * <pre> * Maximum number of results per page. * CURRENTLY UNIMPLEMENTED AND IGNORED. * </pre> * * <code>int32 page_size = 4;</code> */ public Builder setPageSize(int value) { pageSize_ = value; onChanged(); return this; } /**