package org.texttechnologylab.project.gruppe_05_1.xml.speeches.Impls;

import org.texttechnologylab.project.gruppe_05_1.xml.speeches.Interfaces.LegislativePeriod;
import org.texttechnologylab.project.gruppe_05_1.xml.speeches.enums.MongoDBEntryType;


public class LegislativePeriod_File_Impl implements LegislativePeriod {
    private final int id;
    private final String startDate;
    private final String endDate;
    private final String constituency;

    @Override
    public int getId() {
        return id;
    }

    @Override
    public String getStartDate() {
        return startDate;
    }

    @Override
    public String getEndDate() {
        return endDate;
    }

    @Override
    public String getConstituency() {
        return constituency;
    }

    public LegislativePeriod_File_Impl(int id, String startDate, String endDate, String constituency) {
        this.id = id;
        this.startDate = startDate;
        this.endDate = endDate;
        this.constituency = constituency;
    }

    @Override
    public MongoDBEntryType getType() {
        return MongoDBEntryType.LEGISLATIVE_PERIOD;
    }

    @Override
    public String toHTML() {
        return "<div class='legislative-period'>"
                + "<h2>Legislative Period Details</h2>"
                + "<p><strong>ID:</strong> " + id + "</p>"
                + "<p><strong>Start Date:</strong> " + startDate + "</p>"
                + "<p><strong>End Date:</strong> " + endDate + "</p>"
                + "<p><strong>Constituency:</strong> " + constituency + "</p>"
                + "</div>";
    }
}
