/** * Sets the error messages. * * @param errorMessages the error messages, must not be <code>null</code> * @throws IllegalArgumentException if <code>errorMessages</code> are <code>null</code> */ public void setErrorMessages(List<String> errorMessages) { Assertion.notNull(errorMessages); this.errorMessages = errorMessages; }
public void addTechnicalEnvironment(String... technicalEnvironment) { Assertion.notNull(technicalEnvironment); for (String s : technicalEnvironment) { Assertion.notEmptyOrNull(s); this.technicalEnvironment.add(s); } }
/** * The URI representing the relationship type. * * @param relUri the URI in string form */ public void setRelUri(String relUri) { Assertion.notEmptyOrNull(relUri); this.relUri = relUri; }
/** * Set the identifier for the entity. * * @param id the identifier, must not be <code>null</code> * @throws IllegalArgumentException if <code>id</code> is <code>null</code> */ public void setId(String id) { Assertion.notEmptyOrNull(id); this.id = id; }
/** * Creates a DcsRelationship with a relationship type of <code>relUri</code> with <code>target</code>. See * {@link DcsRelationship} for supported relationship types. * * @param relUri the relationship type, must not be empty or <code>null</code> * @param target the target entity, must not be <code>null</code> */ public DcsRelation(String relUri, DcsEntityReference target) { Assertion.notEmptyOrNull(relUri); Assertion.notNull(target); this.relUri = relUri; this.ref = new DcsEntityReference(target); }
/** * Convenience constructor, constructing a reference to <code>ref</code> * * @param ref the reference */ public DcsEntityReference(String ref) { Assertion.notEmptyOrNull(ref); this.ref = ref; }
/** * Creates a DcsRelationship with a relationship type of <code>rel</code> with <code>target</code>. See * {@link DcsRelationship} for supported relationship types. * * @param rel the relationship type, must not be <code>null</code> * @param target the target entity, must not be empty or <code>null</code> */ public DcsRelation(DcsRelationship rel, String target) { Assertion.notNull(rel); Assertion.notEmptyOrNull(target); this.relUri = rel.asString(); this.ref = new DcsEntityReference(target); }
/** * Set the entity reference * * @param ref the entity reference, must not be empty or <code>null</code> * @throws IllegalArgumentException if <code>ref</code> is empty or <code>null</code> */ public void setRef(String ref) { Assertion.notEmptyOrNull(ref); this.ref = ref; }