/*
 * <!--
 *   ~ Copyright 2015-2017 OpenCB
 *   ~
 *   ~ Licensed under the Apache License, Version 2.0 (the "License");
 *   ~ you may not use this file except in compliance with the License.
 *   ~ You may obtain a copy of the License at
 *   ~
 *   ~     http://www.apache.org/licenses/LICENSE-2.0
 *   ~
 *   ~ Unless required by applicable law or agreed to in writing, software
 *   ~ distributed under the License is distributed on an "AS IS" BASIS,
 *   ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 *   ~ See the License for the specific language governing permissions and
 *   ~ limitations under the License.
 *   -->
 *
 */

package org.opencb.biodata.models.clinical.interpretation;

import org.opencb.biodata.models.clinical.ClinicalAcmg;
import org.opencb.biodata.models.clinical.ClinicalDiscussion;
import org.opencb.biodata.models.clinical.ClinicalProperty;

import java.util.ArrayList;
import java.util.List;

import static org.opencb.biodata.models.clinical.ClinicalProperty.ClinicalSignificance;

public class ClinicalEvidenceReview {

    private boolean select;
    private String tier;
    private List<ClinicalAcmg> acmg;
    private ClinicalProperty.ClinicalSignificance clinicalSignificance;
    private ClinicalDiscussion discussion;

    public ClinicalEvidenceReview() {
        this.select = false;
        this.acmg = new ArrayList<>();
    }

    public ClinicalEvidenceReview(boolean select, String tier, List<ClinicalAcmg> acmg,
                                  ClinicalSignificance clinicalSignificance, ClinicalDiscussion discussion) {
        this.select = select;
        this.tier = tier;
        this.acmg = acmg;
        this.clinicalSignificance = clinicalSignificance;
        this.discussion = discussion;
    }

    @Override
    public String toString() {
        final StringBuilder sb = new StringBuilder("ClinicalEvidenceReview{");
        sb.append("select=").append(select);
        sb.append(", tier='").append(tier).append('\'');
        sb.append(", acmg=").append(acmg);
        sb.append(", clinicalSignificance=").append(clinicalSignificance);
        sb.append(", discussion='").append(discussion).append('\'');
        sb.append('}');
        return sb.toString();
    }

    public boolean isSelect() {
        return select;
    }

    public ClinicalEvidenceReview setSelect(boolean select) {
        this.select = select;
        return this;
    }

    public String getTier() {
        return tier;
    }

    public ClinicalEvidenceReview setTier(String tier) {
        this.tier = tier;
        return this;
    }

    public List<ClinicalAcmg> getAcmg() {
        return acmg;
    }

    public ClinicalEvidenceReview setAcmg(List<ClinicalAcmg> acmg) {
        this.acmg = acmg;
        return this;
    }

    public ClinicalSignificance getClinicalSignificance() {
        return clinicalSignificance;
    }

    public ClinicalEvidenceReview setClinicalSignificance(ClinicalSignificance clinicalSignificance) {
        this.clinicalSignificance = clinicalSignificance;
        return this;
    }

    public ClinicalDiscussion getDiscussion() {
        return discussion;
    }

    public ClinicalEvidenceReview setDiscussion(ClinicalDiscussion discussion) {
        this.discussion = discussion;
        return this;
    }
}

@@ -1284,16 +1284,47 @@
 cussion;
+%0A    private List%3CString%3E tags;
 %0A%0A    pu
@@ -1419,24 +1419,63 @@
 ayList%3C%3E();%0A
+        this.tags = new ArrayList%3C%3E();%0A
     %7D%0A%0A    p
@@ -1655,32 +1655,85 @@
 ssion discussion
+,%0A                                  List%3CString%3E tags
 ) %7B%0A        this
@@ -1890,32 +1890,58 @@
 n = discussion;%0A
+        this.tags = tags;%0A
     %7D%0A%0A    @Over
@@ -2307,17 +2307,16 @@
 cussion=
-'
 %22).appen
@@ -2328,28 +2328,58 @@
 cussion)
-.append('%5C''
+;%0A        sb.append(%22, tags=%22).append(tags
 );%0A     
@@ -3430,24 +3430,24 @@
 scussion) %7B%0A
-
         this
@@ -3498,11 +3498,192 @@
 s;%0A    %7D
+%0A%0A    public List%3CString%3E getTags() %7B%0A        return tags;%0A    %7D%0A%0A    public ClinicalEvidenceReview setTags(List%3CString%3E tags) %7B%0A        this.tags = tags;%0A        return this;%0A    %7D
 %0A%7D%0A

add list of tags to ClinicalEvidenceReview, #TASK-1194