// Path: library/src/main/java/com/smartnsoft/droid4me/download/DownloadContracts.java
// public interface Bitmapable
// {
// 
//   /**
//    * @return the underlying bitmap size expressed in bytes
//    */
//   int getSizeInBytes();
// 
//   /**
//    * Should release the memory hold by the underlying bitmap, when reclaimed.
//    */
//   void recycle();
// 
// }
// 
// Path: library/src/main/java/com/smartnsoft/droid4me/download/DownloadContracts.java
// public interface Viewable
// {
// 
//   /**
//    * @return a tag object associated to the underlying view.
//    */
//   Object getTag();
// 
//   /**
//    * Sets the tag object associated to the underlying view.
//    *
//    * @param tag
//    */
//   void setTag(Object tag);
// 
//   /**
//    * The identifier returned here is just use for logging purposes.
//    *
//    * @return the unique identifier of the underlying view: two physical different views should not have the same identifier
//    */
//   int getId();
// 
// }


import java.io.IOException;
import java.io.InputStream;
import android.view.View;
import android.widget.ImageView;
import com.smartnsoft.droid4me.download.DownloadContracts.Bitmapable;
import com.smartnsoft.droid4me.download.DownloadContracts.Viewable;
// The MIT License (MIT)
//
// Copyright (c) 2017 Smart&Soft
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in all
// copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.

package com.smartnsoft.droid4me.download;




/**
 * Gathers in one place the download instructions contracts used by {@link BitmapDownloader}.
 *
 * @author Édouard Mercier
 * @since 2011.07.03
 */
public class BasisDownloadInstructions
{

  /**
   * Enables the {@link CoreBitmapDownloader bitmap downloader} to know on how to handle a command.
   *
   * @since 2009.03.04
   */
// Path: library/src/main/java/com/smartnsoft/droid4me/download/DownloadContracts.java
// public interface Bitmapable
// {
// 
//   /**
//    * @return the underlying bitmap size expressed in bytes
//    */
//   int getSizeInBytes();
// 
//   /**
//    * Should release the memory hold by the underlying bitmap, when reclaimed.
//    */
//   void recycle();
// 
// }
// 
// Path: library/src/main/java/com/smartnsoft/droid4me/download/DownloadContracts.java
// public interface Viewable
// {
// 
//   /**
//    * @return a tag object associated to the underlying view.
//    */
//   Object getTag();
// 
//   /**
//    * Sets the tag object associated to the underlying view.
//    *
//    * @param tag
//    */
//   void setTag(Object tag);
// 
//   /**
//    * The identifier returned here is just use for logging purposes.
//    *
//    * @return the unique identifier of the underlying view: two physical different views should not have the same identifier
//    */
//   int getId();
// 
// }


// Path: library/src/main/java/com/smartnsoft/droid4me/download/BasisDownloadInstructions.java
import java.io.IOException;
import java.io.InputStream;
import android.view.View;
import android.widget.ImageView;
import com.smartnsoft.droid4me.download.DownloadContracts.Bitmapable;
import com.smartnsoft.droid4me.download.DownloadContracts.Viewable;

// The MIT License (MIT)
//
// Copyright (c) 2017 Smart&Soft
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in all
// copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.

package com.smartnsoft.droid4me.download;




/**
 * Gathers in one place the download instructions contracts used by {@link BitmapDownloader}.
 *
 * @author Édouard Mercier
 * @since 2011.07.03
 */
public class BasisDownloadInstructions
{

  /**
   * Enables the {@link CoreBitmapDownloader bitmap downloader} to know on how to handle a command.
   *
   * @since 2009.03.04
   */
  public interface Instructions<BitmapClass extends Bitmapable, ViewClass extends Viewable>