Esempio n. 1
0
  /**
   * Constructor FileTableRow
   *
   * @param status
   */
  public FileTableRow(SVNStatus status) {
    File statusFile = status.getFile();

    this.status = new String(getStatus(status));
    this.folder = statusFile.getParentFile();
    this.file = statusFile.getName();
    this.revision = status.getRevision().getNumber();
    this.committedRevision = status.getCommittedRevision().getNumber();

    int extIndex = file.lastIndexOf('.');

    if (statusFile.isFile() && (extIndex > 0)) {
      ext = file.substring(extIndex + 1);
    } else {
      ext = "";
    }

    long lastModified = statusFile.lastModified();

    if (lastModified > 0) {
      modified = new Date(lastModified);
    } else {
      modified = null;
    }

    if (status.getURL() != null) {
      location = new Location(statusFile, status.getURL().toString());
    } else {
      location = null;
    }
  }