
package de.ivu.elect.presentation.staat.exchange;

import java.util.List;

import javax.inject.Inject;
import javax.inject.Named;

import de.ivu.elect.business.datei.entity.DateiImportBerichtCustomData;
import de.ivu.elect.business.exchange.control.AbstractImporter;
import de.ivu.elect.business.exchange.control.NoContext;
import de.ivu.elect.business.security.UseCasePermission;
import de.ivu.elect.business.staat.boundary.StaatImporter;
import de.ivu.elect.business.staat.entity.Staat;
import de.ivu.elect.presentation.View;
import de.ivu.elect.presentation.exchange.AbstractImportSearchView;
import de.ivu.elect.presentation.exchange.ImportDescription;

@Named(StaatImportSearchView.COMPONENT_NAME)
@View(viewId = StaatImportSearchView.VIEW_ID, useCase = UseCasePermission.STAATEN_IMPORTIEREN)
public class StaatImportSearchView extends AbstractImportSearchView<List<Staat>, NoContext> {

  public static final String COMPONENT_NAME = "staatImportSearchView";

  public static final String VIEW_ID = "/staat/staat-import-search.xhtml";

  @Inject
  private StaatImporter staatImporter;

  @Inject
  private StaatImportDescription staatImportDescription;

  public StaatImportSearchView() {
    super();
  }

  @Override
  protected AbstractImporter<List<Staat>, NoContext, ? > getImporter() {
    return staatImporter;
  }

  @Override
  protected ImportDescription getImportDescription() {
    return staatImportDescription;
  }

  @Override
  protected NoContext getContext() {
    return NoContext.NO_CONTEXT;
  }

  @Override
  protected DateiImportBerichtCustomData createNewDateiImportBerichtCustomData() {
    return new DateiImportBerichtCustomData();
  }
}
