ListTablesRequest¶
- class borneo.ListTablesRequest[source]¶
Bases:
RequestRepresents the argument of a
NoSQLHandle.list_tables()operation which lists all available tables associated with the identity associated with the handle used for the operation. If the list is large it can be paged by using the start_index and limit parameters. The list is returned in a simple array inListTablesResult. Names are returned sorted in alphabetical order in order to facilitate paging.Methods Summary
Get the compartment id or name if set for the request.
Returns the maximum number of table names to return in the operation.
Returns the namespace to use for the list or None if not set.
Returns the index to use to start returning table names.
Returns the timeout to use for the operation, in milliseconds.
set_compartment(compartment)Sets the name or id of a compartment to be used for this operation.
set_limit(limit)Sets the maximum number of table names to return in the operation.
set_namespace(namespace)Sets the namespace to use for the list.
set_start_index(start_index)Sets the index to use to start returning table names.
set_timeout(timeout_ms)Sets the request timeout value, in milliseconds.
Methods Documentation
- get_compartment()¶
Get the compartment id or name if set for the request.
Cloud service only.
- Returns:
compartment id or name if set for the request, otherwise None if not set.
- Return type:
str
- get_limit()[source]¶
Returns the maximum number of table names to return in the operation. If not set (0) there is no application-imposed limit.
- Returns:
the maximum number of tables to return in a single request.
- Return type:
int
- get_namespace()[source]¶
Returns the namespace to use for the list or None if not set.
On-premise only.
- Returns:
the namespace.
- Return type:
str
- get_start_index()[source]¶
Returns the index to use to start returning table names. This is related to the
ListTablesResult.get_last_returned_index()from a previous request and can be used to page table names. If not set, the list starts at index 0.- Returns:
the start index.
- Return type:
int
- get_timeout()[source]¶
Returns the timeout to use for the operation, in milliseconds. A value of 0 indicates that the timeout has not been set.
- Returns:
the timeout value.
- Return type:
int
- set_compartment(compartment)[source]¶
Sets the name or id of a compartment to be used for this operation.
The compartment may be specified as either a name (or path for nested compartments) or as an id (OCID). A name (vs id) can only be used when authenticated using a specific user identity. It is not available if authenticated as an Instance Principal which can be done when calling the service from a compute instance in the Oracle Cloud Infrastructure. See
borneo.iam.SignatureProvider.create_with_instance_principal().Cloud service only.
- Parameters:
compartment (str) – the compartment name or id. If using a nested compartment, specify the full compartment path compartmentA.compartmentB, but exclude the name of the root compartment (tenant).
- Returns:
self.
- Raises:
IllegalArgumentException – raises the exception if compartment is not a str.
- set_limit(limit)[source]¶
Sets the maximum number of table names to return in the operation. If not set (0) there is no limit.
- Parameters:
limit (int) – the maximum number of tables.
- Returns:
self.
- Raises:
IllegalArgumentException – raises the exception if limit is a negative number.
- set_namespace(namespace)[source]¶
Sets the namespace to use for the list. If not set, all tables accessible to the user will be returned. If set, only tables in the namespace provided are returned.
On-premise only.
- Parameters:
namespace (str) – the namespace to use.
- Returns:
self.
- Raises:
IllegalArgumentException – raises the exception if namespace is not a string.
- set_start_index(start_index)[source]¶
Sets the index to use to start returning table names. This is related to the
ListTablesResult.get_last_returned_index()from a previous request and can be used to page table names. If not set, the list starts at index 0.- Parameters:
start_index (int) – the start index.
- Returns:
self.
- Raises:
IllegalArgumentException – raises the exception if start_index is a negative number.
- set_timeout(timeout_ms)[source]¶
Sets the request timeout value, in milliseconds. This overrides any default value set in
NoSQLHandleConfig. The value must be positive.- Parameters:
timeout_ms (int) – the timeout value, in milliseconds.
- Returns:
self.
- Raises:
IllegalArgumentException – raises the exception if the timeout value is less than or equal to 0.