/* ----------------------------------------
 * Origin  : GFI INFORMATIQUE 
 * Project : CDPP Propagation Tool 
 * ----------------------------------------
 * History 
 * Version : 25/08/2016 : SCA : V2.2.2
 * 	Creation
 * ----------------------------------------
 */
package fr.tlse.irap.pt.client.controller.tools.externalLinks;

import java.util.List;

import eu.omp.irap.vespa.epntapclient.granule.Granule;
import fr.tlse.irap.pt.client.component.DialogComponent;

public class ApisImagesDialogBox {

	private ApisImagesComponent apisImagesController;
	private String title;

	public ApisImagesDialogBox(String title) {
		this.title = title;
	}
	
	public ApisImagesComponent getApisImagesComponent() {
		if (apisImagesController == null) {
			apisImagesController = new ApisImagesComponent();
			new DialogComponent(apisImagesController, ApisComponent.dialog, title);

		}
		return apisImagesController;
	}

	/**
	 * Show Apis images list interface initialized with list of granules
	 * @param granules
	 */
	public void show(List<Granule> granules) {
		getApisImagesComponent().initComponentWith(granules);
	}

}