private void OnGetCollectionImages(GetCollectionImages collections, string customData) { if (collections != null) { Log.Debug("TestVisualRecognition", "Get Collections succeded!"); foreach (GetCollectionsBrief collection in collections.images) { Log.Debug("TestVisualRecognition", "imageID: {0} | image file: {1} | image metadataOnGetCollections: {2}", collection.image_id, collection.image_file, collection.metadata.ToString()); } } else { Log.Debug("TestVisualRecognition", "Get Collections failed!"); } Test(collections != null); m_ListImagesTested = true; }
public GetCollectionImages GetCollectionImages(string collectionId) { if (string.IsNullOrEmpty(collectionId)) { throw new ArgumentNullException(nameof(collectionId)); } GetCollectionImages result = null; try { result = this.Client.GetAsync($"{this.Endpoint}{string.Format(PATH_COLLECTION_IMAGES, collectionId)}") .WithArgument("api_key", ApiKey) .WithArgument("version", VERSION_DATE_2016_05_20) .As <GetCollectionImages>() .Result; } catch (AggregateException ae) { throw ae.Flatten(); } return(result); }