Skip to content

Commit

Permalink
Add NamedIndividual to BuildParams class.
Browse files Browse the repository at this point in the history
  • Loading branch information
daveneiman committed Sep 14, 2017
1 parent 44b1dc4 commit f5dd9c2
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions src/main/java/org/ld4l/bib2lod/entitybuilders/BuildParams.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

import org.ld4l.bib2lod.entity.Entity;
import org.ld4l.bib2lod.ontology.DatatypeProp;
import org.ld4l.bib2lod.ontology.NamedIndividual;
import org.ld4l.bib2lod.ontology.ObjectProp;
import org.ld4l.bib2lod.ontology.Type;
import org.ld4l.bib2lod.records.Record;
Expand Down Expand Up @@ -35,6 +36,7 @@ public class BuildParams {
private List<RecordField> subfields;

private Type type;
private NamedIndividual namedIndividual;
private String value;

/**
Expand All @@ -48,6 +50,7 @@ public BuildParams() {
this.relationship = null;
this.subfields = new ArrayList<>();
this.type = null;
this.namedIndividual = null;
this.value = null;
}

Expand Down Expand Up @@ -202,6 +205,19 @@ public BuildParams setType(Type type) {
return this;
}

/**
* Returns null if no NamedIndividual has been set.
*/
public NamedIndividual getNamedIndividual() {
return namedIndividual;
}

public BuildParams setNamedIndividual(NamedIndividual namedIndividual) {
this.namedIndividual = namedIndividual;
// Return this for method chaining
return this;
}

/**
* Returns null if no value has been set.
*/
Expand Down

0 comments on commit f5dd9c2

Please sign in to comment.