@Generated public class SharesAPI extends Object
| Constructor and Description |
|---|
SharesAPI(ApiClient apiClient)
Regular-use constructor
|
SharesAPI(SharesService mock)
Constructor for mocks
|
| Modifier and Type | Method and Description |
|---|---|
ShareInfo |
create(CreateShare request)
Creates a new share for data objects.
|
void |
delete(DeleteShareRequest request)
Deletes a data object share from the metastore.
|
void |
delete(String name) |
ShareInfo |
get(GetShareRequest request)
Gets a data object share from the metastore.
|
ShareInfo |
get(String name) |
SharesService |
impl() |
Iterable<ShareInfo> |
list(ListSharesRequest request)
Gets an array of data object shares from the metastore.
|
Iterable<ShareInfo> |
list(String name) |
Iterable<ShareInfo> |
listShares(SharesListRequest request)
Gets an array of data object shares from the metastore.
|
GetSharePermissionsResponse |
sharePermissions(SharePermissionsRequest request)
Gets the permissions for a data share from the metastore.
|
GetSharePermissionsResponse |
sharePermissions(String name) |
ShareInfo |
update(UpdateShare request)
Updates the share with the changes and data objects in the request.
|
UpdateSharePermissionsResponse |
updatePermissions(UpdateSharePermissions request)
Updates the permissions for a data share in the metastore.
|
public SharesAPI(ApiClient apiClient)
public SharesAPI(SharesService mock)
public ShareInfo create(CreateShare request)
public void delete(String name)
public void delete(DeleteShareRequest request)
public ShareInfo get(GetShareRequest request)
public Iterable<ShareInfo> listShares(SharesListRequest request)
public GetSharePermissionsResponse sharePermissions(String name)
public GetSharePermissionsResponse sharePermissions(SharePermissionsRequest request)
public ShareInfo update(UpdateShare request)
When the caller is a metastore admin, only the __owner__ field can be updated.
In the case the share name is changed, **updateShare** requires that the caller is the owner of the share and has the CREATE_SHARE privilege.
If there are notebook files in the share, the __storage_root__ field cannot be updated.
For each table that is added through this method, the share owner must also have **SELECT** privilege on the table. This privilege must be maintained indefinitely for recipients to be able to access the table. Typically, you should use a group as the share owner.
Table removals through **update** do not require additional privileges.
public UpdateSharePermissionsResponse updatePermissions(UpdateSharePermissions request)
For new recipient grants, the user must also be the owner of the recipients. recipient revocations do not require additional privileges.
public SharesService impl()
public Iterable<ShareInfo> list(ListSharesRequest request)
Copyright © 2026. All rights reserved.