/// <summary> /// This method is responsible for retrieving a public project from the user, by id from the JsFiddle API. /// </summary> /// <param name="identifier">The identifier which will be used to retrieve the correct project.</param> /// <returns>This method throws a not supported by external API exception.</returns> public async Task <Project> GetPublicProjectById(string identifier) { JsFiddleDataSourceResourceResult jsFiddleSource = await FetchPublicFiddleById(identifier); Project project = mapper.Map <JsFiddleDataSourceResourceResult, Project>(jsFiddleSource); return(project); }
/// <summary> /// This method is responsible for retrieving a public project from a uri, from the JsFiddle API. /// </summary> /// <param name="sourceUri">The source uri which will be used to retrieve the correct project.</param> /// <returns>This method throws a not supported by external API exception.</returns> public async Task <Project> GetPublicProjectFromUri(Uri sourceUri) { JsFiddleDataSourceResourceResult jsFiddleSource = await FetchPublicFiddleFromUri(sourceUri); Project project = mapper.Map <JsFiddleDataSourceResourceResult, Project>(jsFiddleSource); return(project); }