diff options
author | Jon Marius Venstad <jvenstad@yahoo-inc.com> | 2017-09-15 15:41:32 +0200 |
---|---|---|
committer | Jon Marius Venstad <jvenstad@yahoo-inc.com> | 2017-09-15 15:41:32 +0200 |
commit | b2e303e8dde55fb2285a9be77afb7078505ca3a0 (patch) | |
tree | 512540c835d15a0adcc710e7c0783f19ccabd7bc /controller-api | |
parent | dcdb0188e4daf6b60c43b31b391fc32bc880f879 (diff) |
Add support for initial assignee for issues
Diffstat (limited to 'controller-api')
-rw-r--r-- | controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/Issues.java | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/Issues.java b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/Issues.java index 6b7464b9ed0..8f24b4e3ede 100644 --- a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/Issues.java +++ b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/Issues.java @@ -55,32 +55,36 @@ public interface Issues { private final String queue; private final String component; private final String label; + private final String assignee; - public Classification(String queue, String component, String label) { + public Classification(String queue, String component, String label, String assignee) { if (queue.isEmpty()) throw new IllegalArgumentException("Queue can not be empty!"); this.queue = queue; this.component = component; this.label = label; + this.assignee = assignee; } public Classification(String queue) { - this(queue, null, null); + this(queue, null, null, null); } - public Classification withComponent(String component) { return new Classification(queue, component, label); } - public Classification withLabel(String label) { return new Classification(queue, component, label); } + public Classification withComponent(String component) { return new Classification(queue, component, label, assignee); } + public Classification withLabel(String label) { return new Classification(queue, component, label, assignee); } + public Classification withAssignee(String assignee) { return new Classification(queue, component, label, assignee); } public String queue() { return queue; } public Optional<String> component() { return Optional.ofNullable(component); } public Optional<String> label() { return Optional.ofNullable(label); } + public Optional<String> assignee() { return Optional.ofNullable(assignee); } @Override public String toString() { - return - "Queue : " + queue() + "\n" + + return "Queue : " + queue() + "\n" + "Component : " + component() + "\n" + - "Label : " + label() + "\n"; + "Label : " + label() + "\n" + + "Assignee : " + assignee() + "\n"; } } |