package com.nedap.archie.rm.support.identification;

import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlType;

/**
 * Created by pieter.bos on 04/11/15.
 */
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "TERMINOLOGY_ID")
public class TerminologyId {
    private String value;

    public TerminologyId() {

    }

    public TerminologyId(String terminologyId, String terminologyVersion) {
        value = terminologyId + "(" + terminologyVersion + ")";
    }

    public String getValue() {
        return value;
    }

    public void setValue(String value) {
        this.value = value;
    }

    public String toString() {
        return value;
    }
}

@@ -486,62 +486,293 @@
     
-value = terminologyId + %22(%22 + terminologyVersion + %22)%22
+if (terminologyVersion == null %7C%7C terminologyVersion.isEmpty()) %7B%0A            value = terminologyId;%0A        %7D else %7B%0A            value = terminologyId + %22(%22 + terminologyVersion + %22)%22;%0A        %7D%0A    %7D%0A%0A    public TerminologyId(String terminologyId) %7B%0A        this(terminologyId, null)
 ;%0A  

Add ability to create TerminologyId without version