C# Класс com.microsoft.dx.officewopi.Utils.WopiUtil

Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
GetActionUrl ( WopiAction action, FileModel file, string authority ) : string

Forms the correct action url for the file and host

GetDiscoveryInfo ( ) : Task>

Gets the discovery information from WOPI discovery and caches it appropriately

PopulateActions ( this file ) : System.Threading.Tasks.Task

Populates a file with action details from WOPI discovery based on the file extension

PopulateActions ( this files ) : System.Threading.Tasks.Task

Populates a list of files with action details from WOPI discovery

ValidateWopiProof ( HttpContext context ) : Task

Validates the WOPI Proof on an incoming WOPI request

Приватные методы

Метод Описание
getWopiProof ( HttpContext context ) : Task

Gets the WOPI proof details from the WOPI discovery endpoint and caches it appropriately

verifyProof ( byte expectedProof, string proofFromRequest, string proofFromDiscovery ) : bool

Verifies the proof against a specified key

Описание методов

GetActionUrl() публичный статический Метод

Forms the correct action url for the file and host
public static GetActionUrl ( WopiAction action, FileModel file, string authority ) : string
action com.microsoft.dx.officewopi.Models.Wopi.WopiAction
file com.microsoft.dx.officewopi.Models.FileModel
authority string
Результат string

GetDiscoveryInfo() публичный статический Метод

Gets the discovery information from WOPI discovery and caches it appropriately
public static GetDiscoveryInfo ( ) : Task>
Результат Task>

PopulateActions() публичный статический Метод

Populates a file with action details from WOPI discovery based on the file extension
public static PopulateActions ( this file ) : System.Threading.Tasks.Task
file this
Результат System.Threading.Tasks.Task

PopulateActions() публичный статический Метод

Populates a list of files with action details from WOPI discovery
public static PopulateActions ( this files ) : System.Threading.Tasks.Task
files this
Результат System.Threading.Tasks.Task

ValidateWopiProof() публичный статический Метод

Validates the WOPI Proof on an incoming WOPI request
public static ValidateWopiProof ( HttpContext context ) : Task
context System.Web.HttpContext
Результат Task