Skip to content

Package: StorableException

StorableException

nameinstructionbranchcomplexitylinemethod
StorableException(StorableErrorCodes)
M: 4 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 2 C: 0
0%
M: 1 C: 0
0%
StorableException(StorableErrorCodes, Object[])
M: 5 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 2 C: 0
0%
M: 1 C: 0
0%
StorableException(StorableErrorCodes, Throwable)
M: 7 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 2 C: 0
0%
M: 1 C: 0
0%
StorableException(StorableErrorCodes, Throwable, Object[])
M: 6 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 2 C: 0
0%
M: 1 C: 0
0%
getKapuaErrorMessagesBundle()
M: 2 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%

Coverage

1: /*******************************************************************************
2: * Copyright (c) 2020, 2022 Eurotech and/or its affiliates and others
3: *
4: * This program and the accompanying materials are made
5: * available under the terms of the Eclipse Public License 2.0
6: * which is available at https://www.eclipse.org/legal/epl-2.0/
7: *
8: * SPDX-License-Identifier: EPL-2.0
9: *
10: * Contributors:
11: * Eurotech - initial API and implementation
12: *******************************************************************************/
13: package org.eclipse.kapua.service.storable.exception;
14:
15: import org.eclipse.kapua.KapuaException;
16:
17: /**
18: * {@link StorableException} definition.
19: * <p>
20: * This is the base {@link KapuaException} for all detailed {@link Exception} of this module.
21: *
22: * @since 1.3.0
23: */
24: public class StorableException extends KapuaException {
25:
26: private static final String ELASTICSEARCH_CLIENT_ERROR_MESSAGES = "storable-error-messages";
27:
28: /**
29: * Constructor.
30: *
31: * @param code The {@link StorableErrorCodes}.
32: * @since 1.3.0
33: */
34: public StorableException(StorableErrorCodes code) {
35: super(code);
36: }
37:
38: /**
39: * Constructor.
40: *
41: * @param code The {@link StorableErrorCodes}.
42: * @param arguments Additional argument associated with the {@link StorableException}.
43: * @since 1.3.0
44: */
45: public StorableException(StorableErrorCodes code, Object... arguments) {
46: super(code, arguments);
47: }
48:
49: /**
50: * Constructor.
51: *
52: * @param code The {@link StorableErrorCodes}.
53: * @param cause The root {@link Throwable} of this {@link StorableException}.
54: * @param arguments Additional argument associated with the {@link StorableException}.
55: * @since 1.3.0
56: */
57: public StorableException(StorableErrorCodes code, Throwable cause, Object... arguments) {
58: super(code, cause, arguments);
59: }
60:
61:
62: /**
63: * Constructor
64: *
65: * @param code The {@link StorableErrorCodes}.
66: * @param cause The root {@link Throwable} of this {@link StorableException}.
67: * @since 1.3.0
68: */
69: public StorableException(StorableErrorCodes code, Throwable cause) {
70: super(code, cause);
71: }
72:
73: @Override
74: protected String getKapuaErrorMessagesBundle() {
75: return ELASTICSEARCH_CLIENT_ERROR_MESSAGES;
76: }
77: }