Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

record-manager-ui#36 Implement export filtered records to excel #52

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,13 @@
<version>2.6</version>
</dependency>

<!-- Processing excel-->
<dependency>
<groupId>org.apache.poi</groupId>
<artifactId>poi-ooxml</artifactId>
<version>5.2.5</version>
</dependency>

<!-- Test dependencies -->
<dependency>
<groupId>org.hamcrest</groupId>
Expand Down
311 changes: 311 additions & 0 deletions src/main/java/cz/cvut/kbss/study/model/export/ExportRecord.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,311 @@
package cz.cvut.kbss.study.model.export;

import java.net.URI;
import java.util.Date;
import java.util.List;

public class ExportRecord {

private URI uri;


private Date created;

private Date modified;

private String label;

private String phase;

private String institution;

private String aircraftType;

private String fuselage;

private URI ac_comp;

private String ac_compName;


private List<String> path;

private String failDate;


private String flightHours;

private Integer numberOfAirframeOverhauls;

private String classificationOfOccurrence;

private String failureAscertainmentCircumstances;

private String repeatedFailure;

private String failureCause;

private String consequence;

private String mission;

private String repair;

private String repairDuration;

private Double averageNumberOfMenDuringRepairment;

private String failureDescription;

private String descriptionOfCorrectiveAction;

private String yearOfProductionOfDefectiveEquipment;

private Integer numberOfOverhaulsOfDefectiveEquipment;

private String serialNoOf;

private String notes;

private String fhaEvent;

public URI getUri() {
return uri;
}

public void setUri(URI uri) {
this.uri = uri;
}

public Date getCreated() {
return created;
}

public void setCreated(Date created) {
this.created = created;
}

public Date getModified() {
return modified;
}

public void setModified(Date modified) {
this.modified = modified;
}

public String getLabel() {
return label;
}

public void setLabel(String label) {
this.label = label;
}

public String getPhase() {
return phase;
}

public void setPhase(String phase) {
this.phase = phase;
}

public String getInstitution() {
return institution;
}

public void setInstitution(String institution) {
this.institution = institution;
}

public String getAircraftType() {
return aircraftType;
}

public void setAircraftType(String aircraftType) {
this.aircraftType = aircraftType;
}

public String getFuselage() {
return fuselage;
}

public void setFuselage(String fuselage) {
this.fuselage = fuselage;
}

public URI getAc_comp() {
return ac_comp;
}

public void setAc_comp(URI ac_comp) {
this.ac_comp = ac_comp;
}

public String getAc_compName() {
return ac_compName;
}

public void setAc_compName(String ac_compName) {
this.ac_compName = ac_compName;
}

public List<String> getPath() {
return path;
}

public void setPath(List<String> path) {
this.path = path;
}

public String getFailDate() {
return failDate;
}

public void setFailDate(String failDate) {
this.failDate = failDate;
}

public String getFlightHours() {
return flightHours;
}

public void setFlightHours(String flightHours) {
this.flightHours = flightHours;
}

public Integer getNumberOfAirframeOverhauls() {
return numberOfAirframeOverhauls;
}

public void setNumberOfAirframeOverhauls(Integer numberOfAirframeOverhauls) {
this.numberOfAirframeOverhauls = numberOfAirframeOverhauls;
}

public String getClassificationOfOccurrence() {
return classificationOfOccurrence;
}

public void setClassificationOfOccurrence(String classificationOfOccurrence) {
this.classificationOfOccurrence = classificationOfOccurrence;
}

public String getFailureAscertainmentCircumstances() {
return failureAscertainmentCircumstances;
}

public void setFailureAscertainmentCircumstances(String failureAscertainmentCircumstances) {
this.failureAscertainmentCircumstances = failureAscertainmentCircumstances;
}

public String getRepeatedFailure() {
return repeatedFailure;
}

public void setRepeatedFailure(String repeatedFailure) {
this.repeatedFailure = repeatedFailure;
}

public String getFailureCause() {
return failureCause;
}

public void setFailureCause(String failureCause) {
this.failureCause = failureCause;
}

public String getConsequence() {
return consequence;
}

public void setConsequence(String consequence) {
this.consequence = consequence;
}

public String getMission() {
return mission;
}

public void setMission(String mission) {
this.mission = mission;
}

public String getRepair() {
return repair;
}

public void setRepair(String repair) {
this.repair = repair;
}

public String getRepairDuration() {
return repairDuration;
}

public void setRepairDuration(String repairDuration) {
this.repairDuration = repairDuration;
}

public Double getAverageNumberOfMenDuringRepairment() {
return averageNumberOfMenDuringRepairment;
}

public void setAverageNumberOfMenDuringRepairment(Double averageNumberOfMenDuringRepairment) {
this.averageNumberOfMenDuringRepairment = averageNumberOfMenDuringRepairment;
}

public String getFailureDescription() {
return failureDescription;
}

public void setFailureDescription(String failureDescription) {
this.failureDescription = failureDescription;
}

public String getDescriptionOfCorrectiveAction() {
return descriptionOfCorrectiveAction;
}

public void setDescriptionOfCorrectiveAction(String descriptionOfCorrectiveAction) {
this.descriptionOfCorrectiveAction = descriptionOfCorrectiveAction;
}

public String getYearOfProductionOfDefectiveEquipment() {
return yearOfProductionOfDefectiveEquipment;
}

public void setYearOfProductionOfDefectiveEquipment(String yearOfProductionOfDefectiveEquipment) {
this.yearOfProductionOfDefectiveEquipment = yearOfProductionOfDefectiveEquipment;
}

public Integer getNumberOfOverhaulsOfDefectiveEquipment() {
return numberOfOverhaulsOfDefectiveEquipment;
}

public void setNumberOfOverhaulsOfDefectiveEquipment(Integer numberOfOverhaulsOfDefectiveEquipment) {
this.numberOfOverhaulsOfDefectiveEquipment = numberOfOverhaulsOfDefectiveEquipment;
}

public String getSerialNoOf() {
return serialNoOf;
}

public void setSerialNoOf(String serialNoOf) {
this.serialNoOf = serialNoOf;
}

public String getNotes() {
return notes;
}

public void setNotes(String notes) {
this.notes = notes;
}

public String getFhaEvent() {
return fhaEvent;
}

public void setFhaEvent(String fhaEvent) {
this.fhaEvent = fhaEvent;
}
}
23 changes: 23 additions & 0 deletions src/main/java/cz/cvut/kbss/study/model/export/NamedItem.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
package cz.cvut.kbss.study.model.export;

import cz.cvut.kbss.jopa.model.annotations.*;
import cz.cvut.kbss.study.model.AbstractEntity;

@SparqlResultSetMappings(value =
@SparqlResultSetMapping(name = "NamedItem", entities = {
@EntityResult(entityClass = NamedItem.class)
})
)
@OWLClass(iri = "http://named-item")
public class NamedItem extends AbstractEntity {
@OWLDataProperty(iri = "http://name")
private String name;

public String getName() {
return name;
}

public void setName(String name) {
this.name = name;
}
}
Loading
Loading