aboutsummaryrefslogtreecommitdiffstats
path: root/config-model/src/main/java/com/yahoo/schema/document/annotation/TemporaryAnnotationReferenceDataType.java
blob: de9bd9778230b639c0c9bb8780b471a9fb689fec (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.schema.document.annotation;

import com.yahoo.document.annotation.AnnotationReferenceDataType;
import com.yahoo.document.annotation.AnnotationType;

/**
 * @author Einar M R Rosenvinge
 */
public class TemporaryAnnotationReferenceDataType extends AnnotationReferenceDataType {

    private final String target;

    public TemporaryAnnotationReferenceDataType(String target) {
        this.target = target;
    }

    public String getTarget() {
        return target;
    }

    @Override
    public void setAnnotationType(AnnotationType type) {
        super.setName("annotationreference<" + type.getName() + ">");
        super.setAnnotationType(type);
    }

}