/// <param name='operations'>
 /// Reference to the ZtherApiIntegration.API.IProductImages.
 /// </param>
 /// <param name='code'>
 /// Required.
 /// </param>
 /// <param name='color'>
 /// Required.
 /// </param>
 public static ImageList GetAllByProductAndColor(this IProductImages operations, string code, string color)
 {
     return(Task.Factory.StartNew((object s) =>
     {
         return ((IProductImages)s).GetAllByProductAndColorAsync(code, color);
     }
                                  , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
 /// <param name='operations'>
 /// Reference to the ZtherApiIntegration.API.IProductImages.
 /// </param>
 /// <param name='id'>
 /// Required.
 /// </param>
 /// <param name='model'>
 /// Required.
 /// </param>
 public static string UpdateAsync(this IProductImages operations, int id, ProductImageUpdate model)
 {
     return(Task.Factory.StartNew((object s) =>
     {
         return ((IProductImages)s).UpdateAsyncAsync(id, model);
     }
                                  , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
 /// <param name='operations'>
 /// Reference to the ZtherApiIntegration.API.IProductImages.
 /// </param>
 /// <param name='id'>
 /// Required.
 /// </param>
 public static ProductImage GetById(this IProductImages operations, int id)
 {
     return(Task.Factory.StartNew((object s) =>
     {
         return ((IProductImages)s).GetByIdAsync(id);
     }
                                  , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
Esempio n. 4
0
 public HomeController(ISubCategories subCategories, ITypeOfProducts type, IProducts products, IUsers users, IProducers producers, IProductImages productImages)
 {
     _products      = products;
     _users         = users;
     _producers     = producers;
     _productImages = productImages;
     _type          = type;
     _subCategories = subCategories;
 }
Esempio n. 5
0
 public BagController(IUsers users, IUserProfiles userProfiles, IReviews reviews, IDislikes dislikes, ILikes likes, IDeliveries deliveries, IProductOrders productOrders, ITypeOfProducts type, ISubCategories subCategories, IOrders orders, IDimensions dimensions, IProducts products, IProducers producers, IProductModels productModels, IProductImages productImages, IMaterials materials)
 {
     _products      = products;
     _producers     = producers;
     _productModels = productModels;
     _productImages = productImages;
     _materials     = materials;
     _dimensions    = dimensions;
     _orders        = orders;
     _type          = type;
     _subCategories = subCategories;
     _productOrders = productOrders;
     _deliveries    = deliveries;
     _dislikes      = dislikes;
     _likes         = likes;
     _reviews       = reviews;
     _userProfiles  = userProfiles;
     _users         = users;
 }
 /// <summary>
 /// Initializes a new instance of the LandauWebAPI class.
 /// </summary>
 /// <param name='rootHandler'>
 /// Optional. The http client handler used to handle http transport.
 /// </param>
 /// <param name='handlers'>
 /// Optional. The set of delegating handlers to insert in the http
 /// client pipeline.
 /// </param>
 public LandauWebAPI(HttpClientHandler rootHandler, params DelegatingHandler[] handlers)
     : base(rootHandler, handlers)
 {
     this._banners        = new Banners(this);
     this._brands         = new Brands(this);
     this._catalogs       = new Catalogs(this);
     this._colors         = new Colors(this);
     this._contactUs      = new ContactUsOperations(this);
     this._countries      = new Countries(this);
     this._groupOrders    = new GroupOrders(this);
     this._images         = new Images(this);
     this._productImages  = new ProductImages(this);
     this._productReviews = new ProductReviews(this);
     this._products       = new Products(this);
     this._questions      = new Questions(this);
     this._retailers      = new Retailers(this);
     this._seo            = new SeoOperations(this);
     this._signUps        = new SignUps(this);
     this._states         = new States(this);
     this._swatches       = new Swatches(this);
     this._baseUri        = new Uri("http://microsoft-apiapp5dcb282abbf74b72ad1667c2-staging.azurewebsites.net:80");
 }
 /// <summary>
 /// Initializes a new instance of the LandauPortalWebAPI class.
 /// </summary>
 /// <param name='rootHandler'>
 /// Optional. The http client handler used to handle http transport.
 /// </param>
 /// <param name='handlers'>
 /// Optional. The set of delegating handlers to insert in the http
 /// client pipeline.
 /// </param>
 public LandauPortalWebAPI(HttpClientHandler rootHandler, params DelegatingHandler[] handlers)
     : base(rootHandler, handlers)
 {
     this._banners        = new Banners(this);
     this._brands         = new Brands(this);
     this._cache          = new Cache(this);
     this._catalogs       = new Catalogs(this);
     this._colors         = new Colors(this);
     this._contactUs      = new ContactUsOperations(this);
     this._countries      = new Countries(this);
     this._emailFavorites = new EmailFavorites(this);
     this._groupOrders    = new GroupOrders(this);
     this._images         = new Images(this);
     this._productImages  = new ProductImages(this);
     this._productReviews = new ProductReviews(this);
     this._products       = new Products(this);
     this._questions      = new Questions(this);
     this._retailers      = new Retailers(this);
     this._seo            = new SeoOperations(this);
     this._signUps        = new SignUps(this);
     this._states         = new States(this);
     this._swatches       = new Swatches(this);
     this._baseUri        = new Uri(API_ENDPOINT);
 }
        /// <param name='operations'>
        /// Reference to the ZtherApiIntegration.API.IProductImages.
        /// </param>
        /// <param name='code'>
        /// Required.
        /// </param>
        /// <param name='primary'>
        /// Optional.
        /// </param>
        /// <param name='cancellationToken'>
        /// Cancellation token.
        /// </param>
        public static async Task <ImageList> GetAllByProductAsync(this IProductImages operations, string code, string primary = null, CancellationToken cancellationToken = default(System.Threading.CancellationToken))
        {
            Microsoft.Rest.HttpOperationResponse <ZtherApiIntegration.API.Models.ImageList> result = await operations.GetAllByProductWithOperationResponseAsync(code, primary, cancellationToken).ConfigureAwait(false);

            return(result.Body);
        }
        /// <param name='operations'>
        /// Reference to the ZtherApiIntegration.API.IProductImages.
        /// </param>
        /// <param name='cancellationToken'>
        /// Cancellation token.
        /// </param>
        public static async Task <string> CreateAsyncAsync(this IProductImages operations, CancellationToken cancellationToken = default(System.Threading.CancellationToken))
        {
            Microsoft.Rest.HttpOperationResponse <string> result = await operations.CreateAsyncWithOperationResponseAsync(cancellationToken).ConfigureAwait(false);

            return(result.Body);
        }
        /// <param name='operations'>
        /// Reference to the ZtherApiIntegration.API.IProductImages.
        /// </param>
        /// <param name='id'>
        /// Required.
        /// </param>
        /// <param name='cancellationToken'>
        /// Cancellation token.
        /// </param>
        public static async Task <ProductImage> GetByIdAsync(this IProductImages operations, int id, CancellationToken cancellationToken = default(System.Threading.CancellationToken))
        {
            Microsoft.Rest.HttpOperationResponse <ZtherApiIntegration.API.Models.ProductImage> result = await operations.GetByIdWithOperationResponseAsync(id, cancellationToken).ConfigureAwait(false);

            return(result.Body);
        }