Reference documentation and code samples for the Discovery Engine V1 API class Google::Cloud::DiscoveryEngine::V1::SchemaService::Rest::Client.
REST client for the SchemaService service.
Service for managing {::Google::Cloud::DiscoveryEngine::V1::Schema Schema}s.
Inherits
- Object
Methods
.configure
def self.configure() { |config| ... } -> Client::Configuration
Configure the SchemaService Client class.
See Configuration for a description of the configuration fields.
- (config) — Configure the Client client.
- config (Client::Configuration)
# Modify the configuration for all SchemaService clients ::Google::Cloud::DiscoveryEngine::V1::SchemaService::Rest::Client.configure do |config| config.timeout = 10.0 end
#configure
def configure() { |config| ... } -> Client::Configuration
Configure the SchemaService Client instance.
The configuration is set to the derived mode, meaning that values can be changed, but structural changes (adding new fields, etc.) are not allowed. Structural changes should be made on Client.configure.
See Configuration for a description of the configuration fields.
- (config) — Configure the Client client.
- config (Client::Configuration)
#create_schema
def create_schema(request, options = nil) -> ::Gapic::Operation
def create_schema(parent: nil, schema: nil, schema_id: nil) -> ::Gapic::Operation
Creates a Schema.
def create_schema(request, options = nil) -> ::Gapic::Operation
create_schema
via a request object, either of type
CreateSchemaRequest or an equivalent Hash.
- request (::Google::Cloud::DiscoveryEngine::V1::CreateSchemaRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
def create_schema(parent: nil, schema: nil, schema_id: nil) -> ::Gapic::Operation
create_schema
via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
parent (::String) — Required. The parent data store resource name, in the format of
projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}
. - schema (::Google::Cloud::DiscoveryEngine::V1::Schema, ::Hash) — Required. The Schema to create.
-
schema_id (::String) — Required. The ID to use for the
Schema, which will become the
final component of the
Schema.name.
This field should conform to RFC-1034 standard with a length limit of 63 characters.
- (result, operation) — Access the result along with the TransportOperation object
- result (::Gapic::Operation)
- operation (::Gapic::Rest::TransportOperation)
- (::Gapic::Operation)
- (::Google::Cloud::Error) — if the REST call is aborted.
#delete_schema
def delete_schema(request, options = nil) -> ::Gapic::Operation
def delete_schema(name: nil) -> ::Gapic::Operation
Deletes a Schema.
def delete_schema(request, options = nil) -> ::Gapic::Operation
delete_schema
via a request object, either of type
DeleteSchemaRequest or an equivalent Hash.
- request (::Google::Cloud::DiscoveryEngine::V1::DeleteSchemaRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
def delete_schema(name: nil) -> ::Gapic::Operation
delete_schema
via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
name (::String) — Required. The full resource name of the schema, in the format of
projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}
.
- (result, operation) — Access the result along with the TransportOperation object
- result (::Gapic::Operation)
- operation (::Gapic::Rest::TransportOperation)
- (::Gapic::Operation)
- (::Google::Cloud::Error) — if the REST call is aborted.
#get_schema
def get_schema(request, options = nil) -> ::Google::Cloud::DiscoveryEngine::V1::Schema
def get_schema(name: nil) -> ::Google::Cloud::DiscoveryEngine::V1::Schema
Gets a Schema.
def get_schema(request, options = nil) -> ::Google::Cloud::DiscoveryEngine::V1::Schema
get_schema
via a request object, either of type
GetSchemaRequest or an equivalent Hash.
- request (::Google::Cloud::DiscoveryEngine::V1::GetSchemaRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
def get_schema(name: nil) -> ::Google::Cloud::DiscoveryEngine::V1::Schema
get_schema
via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
name (::String) — Required. The full resource name of the schema, in the format of
projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}
.
- (result, operation) — Access the result along with the TransportOperation object
- result (::Google::Cloud::DiscoveryEngine::V1::Schema)
- operation (::Gapic::Rest::TransportOperation)
- (::Google::Cloud::Error) — if the REST call is aborted.
#initialize
def initialize() { |config| ... } -> Client
Create a new SchemaService REST client object.
- (config) — Configure the SchemaService client.
- config (Client::Configuration)
- (Client) — a new instance of Client
# Create a client using the default configuration client = ::Google::Cloud::DiscoveryEngine::V1::SchemaService::Rest::Client.new # Create a client using a custom configuration client = ::Google::Cloud::DiscoveryEngine::V1::SchemaService::Rest::Client.new do |config| config.timeout = 10.0 end
#list_schemas
def list_schemas(request, options = nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::DiscoveryEngine::V1::Schema>
def list_schemas(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::DiscoveryEngine::V1::Schema>
Gets a list of {::Google::Cloud::DiscoveryEngine::V1::Schema Schema}s.
def list_schemas(request, options = nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::DiscoveryEngine::V1::Schema>
list_schemas
via a request object, either of type
ListSchemasRequest or an equivalent Hash.
- request (::Google::Cloud::DiscoveryEngine::V1::ListSchemasRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
def list_schemas(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::DiscoveryEngine::V1::Schema>
list_schemas
via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
parent (::String) — Required. The parent data store resource name, in the format of
projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}
. -
page_size (::Integer) — The maximum number of Schemas to
return. The service may return fewer than this value.
If unspecified, at most 100 Schemas will be returned.
The maximum value is 1000; values above 1000 will be coerced to 1000.
-
page_token (::String) — A page token, received from a previous
SchemaService.ListSchemas
call. Provide this to retrieve the subsequent page.
When paginating, all other parameters provided to SchemaService.ListSchemas must match the call that provided the page token.
- (result, operation) — Access the result along with the TransportOperation object
- result (::Gapic::Rest::PagedEnumerable<::Google::Cloud::DiscoveryEngine::V1::Schema>)
- operation (::Gapic::Rest::TransportOperation)
- (::Gapic::Rest::PagedEnumerable<::Google::Cloud::DiscoveryEngine::V1::Schema>)
- (::Google::Cloud::Error) — if the REST call is aborted.
#location_client
def location_client() -> Google::Cloud::Location::Locations::Rest::Client
Get the associated client for mix-in of the Locations.
- (Google::Cloud::Location::Locations::Rest::Client)
#operations_client
def operations_client() -> ::Google::Cloud::DiscoveryEngine::V1::SchemaService::Rest::Operations
Get the associated client for long-running operations.
#update_schema
def update_schema(request, options = nil) -> ::Gapic::Operation
def update_schema(schema: nil, allow_missing: nil) -> ::Gapic::Operation
Updates a Schema.
def update_schema(request, options = nil) -> ::Gapic::Operation
update_schema
via a request object, either of type
UpdateSchemaRequest or an equivalent Hash.
- request (::Google::Cloud::DiscoveryEngine::V1::UpdateSchemaRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
def update_schema(schema: nil, allow_missing: nil) -> ::Gapic::Operation
update_schema
via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
- schema (::Google::Cloud::DiscoveryEngine::V1::Schema, ::Hash) — Required. The Schema to update.
-
allow_missing (::Boolean) — If set to true, and the Schema is
not found, a new Schema will be
created. In this situation,
update_mask
is ignored.
- (result, operation) — Access the result along with the TransportOperation object
- result (::Gapic::Operation)
- operation (::Gapic::Rest::TransportOperation)
- (::Gapic::Operation)
- (::Google::Cloud::Error) — if the REST call is aborted.