public static async Task <ObservableCollection <ModelResult> > GetDesignTimeBoardDataAsync() { var jsonFile = await StorageFile.GetFileFromApplicationUriAsync(new Uri("ms-appx:///Assets/SampleData/ExampleBoardResponse.json")); string json = await FileIO.ReadTextAsync(jsonFile); var result = RemixBoardResponse.FromJson(json); return(new ObservableCollection <ModelResult>(result.Items.Results)); }
public async Task <RemixBoardResponse> GetModelsForBoardAsync(string boardId, string continuationUrl = null) { string json = string.Empty; if (string.IsNullOrEmpty(continuationUrl)) { // If starting from scratch for a new user json = await client.GetStringAsync($"{ApiRoot}/boards/{boardId}"); } else { // If this is a continuation, there is a continuation token already prepared for us. // ex. "continuationUri": "hXXp://api.remix3d.com:443/v3/boards/{boardId}?%24continuationToken=xxxxxxxxxx." json = await client.GetStringAsync(continuationUrl); } return(RemixBoardResponse.FromJson(json)); }