@Generated public class CatalogsAPI extends Object
In Unity Catalog, admins and data stewards manage users and their access to data centrally across all of the workspaces in a Databricks account. Users in different workspaces can share access to the same data, depending on privileges granted centrally in Unity Catalog.
| Constructor and Description |
|---|
CatalogsAPI(ApiClient apiClient)
Regular-use constructor
|
CatalogsAPI(CatalogsService mock)
Constructor for mocks
|
| Modifier and Type | Method and Description |
|---|---|
CatalogInfo |
create(CreateCatalog request)
Create a catalog.
|
CatalogInfo |
create(String name) |
void |
delete(DeleteCatalogRequest request)
Delete a catalog.
|
void |
delete(String name) |
CatalogInfo |
get(GetCatalogRequest request)
Get a catalog.
|
CatalogInfo |
get(String name) |
CatalogsService |
impl() |
Iterable<CatalogInfo> |
list(ListCatalogsRequest request)
List catalogs.
|
CatalogInfo |
update(String name) |
CatalogInfo |
update(UpdateCatalog request)
Update a catalog.
|
public CatalogsAPI(ApiClient apiClient)
public CatalogsAPI(CatalogsService mock)
public CatalogInfo create(String name)
public CatalogInfo create(CreateCatalog request)
Creates a new catalog instance in the parent metastore if the caller is a metastore admin or has the **CREATE_CATALOG** privilege.
public void delete(String name)
public void delete(DeleteCatalogRequest request)
Deletes the catalog that matches the supplied name. The caller must be a metastore admin or the owner of the catalog.
public CatalogInfo get(String name)
public CatalogInfo get(GetCatalogRequest request)
Gets the specified catalog in a metastore. The caller must be a metastore admin, the owner of the catalog, or a user that has the **USE_CATALOG** privilege set for their account.
public Iterable<CatalogInfo> list(ListCatalogsRequest request)
Gets an array of catalogs in the metastore. If the caller is the metastore admin, all catalogs will be retrieved. Otherwise, only catalogs owned by the caller (or for which the caller has the **USE_CATALOG** privilege) will be retrieved. There is no guarantee of a specific ordering of the elements in the array.
public CatalogInfo update(String name)
public CatalogInfo update(UpdateCatalog request)
Updates the catalog that matches the supplied name. The caller must be either the owner of the catalog, or a metastore admin (when changing the owner field of the catalog).
public CatalogsService impl()
Copyright © 2024. All rights reserved.