public Google.Apis.Drive.v3.Data.File GetFileDetails_NotUsed(string id) { if (CachedFiles.ContainsKey(id)) { return(CachedFiles[id]); } var request = DriveService.Files.Get(id); request.Fields = "id,name,parents,size"; var file = request.Execute(); CachedFiles[id] = file; return(file); }
public Google.Apis.Drive.v3.Data.File GetParent(string id) { if (CachedFiles.ContainsKey(id)) { return(CachedFiles[id]); } var request = DriveService.Files.Get(id); request.Fields = "id,name,parents"; var parent = request.Execute(); CachedFiles[id] = parent; return(parent); }