diff options
Diffstat (limited to 'document')
3 files changed, 0 insertions, 77 deletions
diff --git a/document/src/main/java/com/yahoo/document/DocumentTypeManager.java b/document/src/main/java/com/yahoo/document/DocumentTypeManager.java index af7c267c8c4..42bc27e485b 100644 --- a/document/src/main/java/com/yahoo/document/DocumentTypeManager.java +++ b/document/src/main/java/com/yahoo/document/DocumentTypeManager.java @@ -219,18 +219,6 @@ public class DocumentTypeManager { } /** - * @deprecated //TODO Will be package-private or removed on Vespa 8 - */ - @SuppressWarnings("deprecation") - @Deprecated - DataType getDataTypeAndReturnTemporary(int code, String detailedType) { - if (hasDataType(code)) { - return getDataType(code, detailedType); - } - return new TemporaryDataType(code, detailedType); - } - - /** * Register a data type of any sort, including document types. * @param type The datatype to register * TODO Give unique ids to document types @@ -247,9 +235,6 @@ public class DocumentTypeManager { @SuppressWarnings("deprecation") void registerSingleType(DataType type) { if (type instanceof TensorDataType) return; // built-in dynamic: Created on the fly - if (type instanceof TemporaryDataType) { - throw new IllegalArgumentException("TemporaryDataType no longer supported: " + type); - } if (type instanceof TemporaryStructuredDataType) { throw new IllegalArgumentException("TemporaryStructuredDataType no longer supported: " + type); } diff --git a/document/src/main/java/com/yahoo/document/TemporaryDataType.java b/document/src/main/java/com/yahoo/document/TemporaryDataType.java deleted file mode 100644 index 71f36ecde90..00000000000 --- a/document/src/main/java/com/yahoo/document/TemporaryDataType.java +++ /dev/null @@ -1,37 +0,0 @@ -// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. -package com.yahoo.document; - -import com.yahoo.document.datatypes.FieldValue; - -/** - * @author Einar M R Rosenvinge - * @deprecated will be removed soon - */ -@Deprecated -class TemporaryDataType extends DataType { - - private final String detailedType; - - TemporaryDataType(int dataTypeId, String detailedType) { - super("temporary_" + dataTypeId, dataTypeId); - this.detailedType = detailedType; - } - - @Override - public FieldValue createFieldValue() { - return null; - } - - @Override - public Class getValueClass() { - return null; - } - - @Override - public boolean isValueCompatible(FieldValue value) { - return false; - } - - String getDetailedType() { return detailedType; } - -} diff --git a/document/src/test/java/com/yahoo/document/TemporaryDataTypeTestCase.java b/document/src/test/java/com/yahoo/document/TemporaryDataTypeTestCase.java deleted file mode 100644 index 80154891d83..00000000000 --- a/document/src/test/java/com/yahoo/document/TemporaryDataTypeTestCase.java +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. -package com.yahoo.document; - -import com.yahoo.document.datatypes.StringFieldValue; -import org.junit.Test; - -import static org.junit.Assert.assertFalse; -import static org.junit.Assert.assertNull; - -/** - * @author Einar M R Rosenvinge - */ -@SuppressWarnings("deprecation") -public class TemporaryDataTypeTestCase { - - @Test - public void requireNulls() { - TemporaryDataType type = new TemporaryDataType(0, ""); - assertNull(type.createFieldValue(new Object())); - assertNull(type.createFieldValue()); - assertNull(type.getValueClass()); - assertFalse(type.isValueCompatible(new StringFieldValue(""))); - } - -} |