summaryrefslogtreecommitdiffstats
path: root/document
diff options
context:
space:
mode:
authorTor Egge <Tor.Egge@broadpark.no>2018-04-05 21:12:48 +0200
committerTor Egge <Tor.Egge@broadpark.no>2018-04-05 21:59:02 +0200
commit7142d7ed1b19a760959d6adf8466e6cd8292e7d5 (patch)
treed8db8fa4fb15793b0913e5073d91a00cff380187 /document
parent6f968e2e3ff884f9087e770a15b8b17f7f4c77ee (diff)
Remove DocumentTypeRepo::UP typedef.
Remove unneeded includes.
Diffstat (limited to 'document')
-rw-r--r--document/src/tests/document_type_repo_factory/document_type_repo_factory_test.cpp1
-rw-r--r--document/src/vespa/document/fieldvalue/structfieldvalue.cpp4
-rw-r--r--document/src/vespa/document/repo/documenttyperepo.h1
-rw-r--r--document/src/vespa/document/serialization/vespadocumentserializer.cpp1
4 files changed, 2 insertions, 5 deletions
diff --git a/document/src/tests/document_type_repo_factory/document_type_repo_factory_test.cpp b/document/src/tests/document_type_repo_factory/document_type_repo_factory_test.cpp
index 2cd10225edd..091bca5fa8a 100644
--- a/document/src/tests/document_type_repo_factory/document_type_repo_factory_test.cpp
+++ b/document/src/tests/document_type_repo_factory/document_type_repo_factory_test.cpp
@@ -2,7 +2,6 @@
#include <vespa/document/datatype/documenttype.h>
#include <vespa/document/repo/configbuilder.h>
-#include <vespa/document/repo/documenttyperepo.h>
#include <vespa/document/repo/document_type_repo_factory.h>
#include <vespa/vespalib/stllike/string.h>
#include <vespa/vespalib/testkit/testapp.h>
diff --git a/document/src/vespa/document/fieldvalue/structfieldvalue.cpp b/document/src/vespa/document/fieldvalue/structfieldvalue.cpp
index 8f5e2d1dbe3..7f88229e1ba 100644
--- a/document/src/vespa/document/fieldvalue/structfieldvalue.cpp
+++ b/document/src/vespa/document/fieldvalue/structfieldvalue.cpp
@@ -193,7 +193,7 @@ StructFieldValue::getFieldValue(const Field& field) const
nbostream stream(buf.c_str(), buf.size());
FieldValue::UP value(field.getDataType().createFieldValue());
if ((_repo == NULL) && (_doc_type != NULL)) {
- DocumentTypeRepo::UP tmpRepo(new DocumentTypeRepo(*_doc_type));
+ std::unique_ptr<const DocumentTypeRepo> tmpRepo(new DocumentTypeRepo(*_doc_type));
createFV(*value, *tmpRepo, stream, *_doc_type, _version);
} else {
createFV(*value, *_repo, stream, *_doc_type, _version);
@@ -226,7 +226,7 @@ StructFieldValue::getFieldValue(const Field& field, FieldValue& value) const
if (buf.size() > 0) {
nbostream_longlivedbuf stream(buf.c_str(), buf.size());
if ((_repo == NULL) && (_doc_type != NULL)) {
- DocumentTypeRepo::UP tmpRepo(new DocumentTypeRepo(*_doc_type));
+ std::unique_ptr<const DocumentTypeRepo> tmpRepo(new DocumentTypeRepo(*_doc_type));
createFV(value, *tmpRepo, stream, *_doc_type, _version);
} else {
createFV(value, *_repo, stream, *_doc_type, _version);
diff --git a/document/src/vespa/document/repo/documenttyperepo.h b/document/src/vespa/document/repo/documenttyperepo.h
index ce54effe068..71410197405 100644
--- a/document/src/vespa/document/repo/documenttyperepo.h
+++ b/document/src/vespa/document/repo/documenttyperepo.h
@@ -23,7 +23,6 @@ class DocumentTypeRepo {
public:
using DocumenttypesConfig = const internal::InternalDocumenttypesType;
- typedef std::unique_ptr<DocumentTypeRepo> UP;
// This one should only be used for testing. If you do not have any config.
explicit DocumentTypeRepo(const DocumentType & docType);
diff --git a/document/src/vespa/document/serialization/vespadocumentserializer.cpp b/document/src/vespa/document/serialization/vespadocumentserializer.cpp
index d8d18969070..919f02a5fee 100644
--- a/document/src/vespa/document/serialization/vespadocumentserializer.cpp
+++ b/document/src/vespa/document/serialization/vespadocumentserializer.cpp
@@ -21,7 +21,6 @@
#include <vespa/document/fieldvalue/tensorfieldvalue.h>
#include <vespa/document/fieldvalue/referencefieldvalue.h>
#include <vespa/document/datatype/weightedsetdatatype.h>
-#include <vespa/document/repo/documenttyperepo.h>
#include <vespa/document/update/updates.h>
#include <vespa/document/update/fieldpathupdates.h>
#include <vespa/vespalib/data/slime/binary_format.h>