1 | import { _File } from "../files/types.js";
|
2 | import { emptyGuid } from "../types.js";
|
3 | import { SharingRole, } from "./types.js";
|
4 | _File.prototype.shareWith = async function (loginNames, role = SharingRole.View, requireSignin = false, emailData) {
|
5 | const item = await this.getItem();
|
6 | return item.shareWith(loginNames, role, requireSignin, emailData);
|
7 | };
|
8 | _File.prototype.getShareLink = async function (kind, expiration = null) {
|
9 | const item = await this.getItem();
|
10 | return item.getShareLink(kind, expiration);
|
11 | };
|
12 | _File.prototype.checkSharingPermissions = async function (recipients) {
|
13 | const item = await this.getItem();
|
14 | return item.checkSharingPermissions(recipients);
|
15 | };
|
16 |
|
17 |
|
18 | _File.prototype.getSharingInformation = async function (request = null, expands, selects) {
|
19 | const item = await this.getItem();
|
20 | return item.getSharingInformation(request, expands, selects);
|
21 | };
|
22 | _File.prototype.getObjectSharingSettings = async function (useSimplifiedRoles = true) {
|
23 | const item = await this.getItem();
|
24 | return item.getObjectSharingSettings(useSimplifiedRoles);
|
25 | };
|
26 | _File.prototype.unshare = async function () {
|
27 | const item = await this.getItem();
|
28 | return item.unshare();
|
29 | };
|
30 | _File.prototype.deleteSharingLinkByKind = async function (linkKind) {
|
31 | const item = await this.getItem();
|
32 | return item.deleteSharingLinkByKind(linkKind);
|
33 | };
|
34 | _File.prototype.unshareLink = async function unshareLink(linkKind, shareId = emptyGuid) {
|
35 | const item = await this.getItem();
|
36 | return item.unshareLink(linkKind, shareId);
|
37 | };
|
38 |
|
\ | No newline at end of file |