diff options
author | Henning Baldersheim <balder@yahoo-inc.com> | 2017-06-07 00:05:28 +0200 |
---|---|---|
committer | Henning Baldersheim <balder@yahoo-inc.com> | 2017-06-07 09:50:24 +0200 |
commit | 834265f2357c41a60668780fa8ce15daf041f818 (patch) | |
tree | 86531034c29e99eabdeb2c9e9a9a02dac8c978ea /document | |
parent | 85e6d602d93f5e4e19043f7a829e72b554bef6a5 (diff) |
Hide the IdParseException a bit better.
Diffstat (limited to 'document')
-rw-r--r-- | document/src/tests/base/documentid_test.cpp | 1 | ||||
-rw-r--r-- | document/src/tests/documentupdatetestcase.cpp | 1 | ||||
-rw-r--r-- | document/src/vespa/document/base/idstring.cpp | 1 | ||||
-rw-r--r-- | document/src/vespa/document/base/idstring.h | 16 | ||||
-rw-r--r-- | document/src/vespa/document/base/idstringexception.h | 19 |
5 files changed, 23 insertions, 15 deletions
diff --git a/document/src/tests/base/documentid_test.cpp b/document/src/tests/base/documentid_test.cpp index adda311e01a..7f17685f84e 100644 --- a/document/src/tests/base/documentid_test.cpp +++ b/document/src/tests/base/documentid_test.cpp @@ -2,6 +2,7 @@ // Unit tests for documentid. #include <vespa/document/base/documentid.h> +#include <vespa/document/base/idstringexception.h> #include <vespa/vespalib/testkit/testapp.h> using namespace document; diff --git a/document/src/tests/documentupdatetestcase.cpp b/document/src/tests/documentupdatetestcase.cpp index baa777ceca1..e3cab489aab 100644 --- a/document/src/tests/documentupdatetestcase.cpp +++ b/document/src/tests/documentupdatetestcase.cpp @@ -24,6 +24,7 @@ #include <vespa/eval/tensor/tensor_factory.h> #include <vespa/vespalib/testkit/testapp.h> #include <vespa/vespalib/objects/nbostream.h> +#include <vespa/vespalib/util/exception.h> using namespace document::config_builder; using vespalib::tensor::Tensor; diff --git a/document/src/vespa/document/base/idstring.cpp b/document/src/vespa/document/base/idstring.cpp index d837f512637..4bdecf38996 100644 --- a/document/src/vespa/document/base/idstring.cpp +++ b/document/src/vespa/document/base/idstring.cpp @@ -1,6 +1,7 @@ // Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. #include "idstring.h" +#include "idstringexception.h" #include <vespa/document/bucket/bucketid.h> #include <vespa/vespalib/util/md5.h> #include <vespa/vespalib/util/stringfmt.h> diff --git a/document/src/vespa/document/base/idstring.h b/document/src/vespa/document/base/idstring.h index f1a96974cc9..5e09b9060b8 100644 --- a/document/src/vespa/document/base/idstring.h +++ b/document/src/vespa/document/base/idstring.h @@ -1,29 +1,15 @@ // Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. -/** - * @file idstring.h - * - * Contains the various URI schemes accepted in document identifiers. - */ #pragma once -#include <vespa/vespalib/util/exception.h> #include <vespa/vespalib/util/memory.h> #include <vespa/vespalib/objects/cloneable.h> #include <vespa/vespalib/stllike/string.h> +#include <cstdint> namespace document { /** - * \class document::IdParseException - * \ingroup base - * - * \brief Exception used to indicate failure to parse a %document identifier - * URI. - */ -VESPA_DEFINE_EXCEPTION(IdParseException, vespalib::Exception); - -/** * \class document::IdString * \ingroup base * diff --git a/document/src/vespa/document/base/idstringexception.h b/document/src/vespa/document/base/idstringexception.h new file mode 100644 index 00000000000..922876a8d6e --- /dev/null +++ b/document/src/vespa/document/base/idstringexception.h @@ -0,0 +1,19 @@ +// Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. + +#pragma once + +#include <vespa/vespalib/util/exception.h> + +namespace document { + +/** + * \class document::IdParseException + * \ingroup base + * + * \brief Exception used to indicate failure to parse a %document identifier + * URI. + */ + +VESPA_DEFINE_EXCEPTION(IdParseException, vespalib::Exception); + +} |