Exemplo n.º 1
0
        // call API call helper function to retrieve file metadata hash
        // currently retrieves size rather than metadata hash
        public async Task <string> GetMetadataHash(string registryAddress, string fileId)
        {
            string Url = $"{Constants.MicrosoftGraphBaseEndpoint}{DriveUrls.MetadataHash(registryAddress, fileId)}";

            string metadataHash = await ApiCaller.CallWebApiAndProcessResultAsync(Url, Token);

            return(metadataHash);
        }
Exemplo n.º 2
0
        // use API call helper function to retrieve data about a file
        public async Task <File> GetFile(string registryAddress, string fileId)
        {
            string Url = $"{Constants.MicrosoftGraphBaseEndpoint}{DriveUrls.File(registryAddress, fileId)}";

            File file = await ApiCaller.CallWebApiFileAndProcessResultAsync(Url, Token);

            return(file);
        }
Exemplo n.º 3
0
        // use API call helper function to retrieve file list
        public async Task <FileList> GetFileList(string registryAddress)
        {
            string Url = $"{Constants.MicrosoftGraphBaseEndpoint}{DriveUrls.FileList(registryAddress)}";

            FileList list = await ApiCaller.CallWebApiFileListAndProcessResultAsync(Url, Token);

            return(list);
        }
Exemplo n.º 4
0
        ////////////////////////////////////////////////////////


        // use API call helper function to retrieve current user's name
        public async Task <string> GetMe()
        {
            string Url = $"{Constants.MicrosoftGraphBaseEndpoint}{DriveUrls.Me()}";

            string me = await ApiCaller.CallWebApiAndProcessResultAsync(Url, Token);

            return(me);
        }