package de.ivu.elect.business.replikation.entity;

import java.io.File;

import de.ivu.elect.business.replikation.control.ReplikationExtractSequenznummer;

/**
 *  on 14.06.2016.
 */
@Deprecated // nicht für neue Sachen verwenden
public class FileInfo {

  private final File file;
  private final Long sequencenummer;

  public FileInfo(File file) {
    this.file = file;
    this.sequencenummer = ReplikationExtractSequenznummer.extractSequenznummer(file);
  }

  public File getFile() {
    return file;
  }

  @Override
  public String toString() {
    return "FileInfo{" +
        "file='" + file.getAbsolutePath() +"'"+
        '}';
  }

  public Long getSequencenummer() {
    return sequencenummer;
  }

  public boolean isSequencenummerVorhanden() {
    return sequencenummer!=null;
  }
}
