summaryrefslogtreecommitdiffstats
path: root/config-model/src/main/java/com/yahoo/searchdefinition/document/SDDocumentType.java
diff options
context:
space:
mode:
authorHenning Baldersheim <balder@yahoo-inc.com>2018-10-31 23:02:45 +0100
committerHenning Baldersheim <balder@yahoo-inc.com>2018-10-31 23:02:45 +0100
commitfb6f2c5f01f615b16860b76ba7a39b5fa7d5518f (patch)
tree954fdf6ef08d341df4558273b9aa26a33af7fc63 /config-model/src/main/java/com/yahoo/searchdefinition/document/SDDocumentType.java
parent3db4288215479f38f7db9c1ddeeceb69a8ff93e5 (diff)
Deprecating a whole lot of body/header related methods that should have been done a long time ago.
Diffstat (limited to 'config-model/src/main/java/com/yahoo/searchdefinition/document/SDDocumentType.java')
-rw-r--r--config-model/src/main/java/com/yahoo/searchdefinition/document/SDDocumentType.java7
1 files changed, 4 insertions, 3 deletions
diff --git a/config-model/src/main/java/com/yahoo/searchdefinition/document/SDDocumentType.java b/config-model/src/main/java/com/yahoo/searchdefinition/document/SDDocumentType.java
index 98be4900ef6..0e9e09844d1 100644
--- a/config-model/src/main/java/com/yahoo/searchdefinition/document/SDDocumentType.java
+++ b/config-model/src/main/java/com/yahoo/searchdefinition/document/SDDocumentType.java
@@ -148,9 +148,10 @@ public class SDDocumentType implements Cloneable, Serializable {
* @param name The name of the new document type
* @param search check for type ID collisions in this search definition
*/
+ @SuppressWarnings("deprecation")
public SDDocumentType(String name, Search search) {
docType = new DocumentType(name);
- docType.getHeaderType().setCompressionConfig(new CompressionConfig());
+ docType.getContentType().setCompressionConfig(new CompressionConfig());
docType.getBodyType().setCompressionConfig(new CompressionConfig());
validateId(search);
inherit(VESPA_DOCUMENT);
@@ -163,8 +164,8 @@ public class SDDocumentType implements Cloneable, Serializable {
this.structType = structType;
inheritedTypes.clear();
} else {
- if (docType.getHeaderType() != null) {
- this.structType = docType.getHeaderType();
+ if (docType.getContentType() != null) {
+ this.structType = docType.getContentType();
inheritedTypes.clear();
} else {
throw new IllegalArgumentException("You can not set a null struct");