import { SharePointQueryable } from "./sharepointqueryable"; import { EmailProperties } from "./types"; import { ODataBatch } from "./batch"; import { ICachingOptions } from "../odata/caching"; import { File } from "./files"; import { PrincipalInfo, PrincipalType, PrincipalSource, WikiPageCreationInformation } from "./types"; /** * Public interface for the utility methods to limit SharePointQueryable method exposure */ export interface UtilityMethods { usingCaching(options?: ICachingOptions): this; inBatch(batch: ODataBatch): this; sendEmail(props: EmailProperties): Promise; getCurrentUserEmailAddresses(): Promise; resolvePrincipal(email: string, scopes: PrincipalType, sources: PrincipalSource, inputIsEmailOnly: boolean, addToUserInfoList: boolean, matchUserInfoList?: boolean): Promise; searchPrincipals(input: string, scopes: PrincipalType, sources: PrincipalSource, groupName: string, maxCount: number): Promise; createEmailBodyForInvitation(pageAddress: string): Promise; expandGroupsToPrincipals(inputs: string[], maxCount?: number): Promise; createWikiPage(info: WikiPageCreationInformation): Promise; } /** * Allows for calling of the static SP.Utilities.Utility methods by supplying the method name */ export declare class UtilityMethod extends SharePointQueryable implements UtilityMethods { private static getBaseUrl(candidate); /** * Creates a new instance of the Utility method class * * @param baseUrl The parent url provider * @param methodName The static method name to call on the utility class */ constructor(baseUrl: string | SharePointQueryable, methodName: string); excute(props: any): Promise; /** * Sends an email based on the supplied properties * * @param props The properties of the email to send */ sendEmail(props: EmailProperties): Promise; getCurrentUserEmailAddresses(): Promise; resolvePrincipal(input: string, scopes: PrincipalType, sources: PrincipalSource, inputIsEmailOnly: boolean, addToUserInfoList: boolean, matchUserInfoList?: boolean): Promise; searchPrincipals(input: string, scopes: PrincipalType, sources: PrincipalSource, groupName: string, maxCount: number): Promise; createEmailBodyForInvitation(pageAddress: string): Promise; expandGroupsToPrincipals(inputs: string[], maxCount?: number): Promise; createWikiPage(info: WikiPageCreationInformation): Promise; } export interface CreateWikiPageResult { data: any; file: File; }