Skip to content

Package: DomainFactoryImpl

DomainFactoryImpl

nameinstructionbranchcomplexitylinemethod
DomainFactoryImpl()
M: 3 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
clone(Domain)
M: 5 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
newCreator(KapuaId)
M: 4 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
newCreator(String)
M: 5 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
newEntity(KapuaId)
M: 5 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
newListResult()
M: 4 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
newQuery(KapuaId)
M: 5 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) 2016, 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.authorization.domain.shiro;
14:
15: import org.apache.commons.lang.NotImplementedException;
16: import org.eclipse.kapua.locator.KapuaProvider;
17: import org.eclipse.kapua.model.id.KapuaId;
18: import org.eclipse.kapua.service.authorization.domain.Domain;
19: import org.eclipse.kapua.service.authorization.domain.DomainCreator;
20: import org.eclipse.kapua.service.authorization.domain.DomainFactory;
21: import org.eclipse.kapua.service.authorization.domain.DomainListResult;
22: import org.eclipse.kapua.service.authorization.domain.DomainQuery;
23:
24: /**
25: * {@link DomainFactory} implementation.
26: *
27: * @since 1.0.0
28: */
29: @KapuaProvider
30: public class DomainFactoryImpl implements DomainFactory {
31:
32: @Override
33: public DomainCreator newCreator(String name) {
34: return new DomainCreatorImpl(name);
35: }
36:
37: @Override
38: public DomainListResult newListResult() {
39: return new DomainListResultImpl();
40: }
41:
42: @Override
43: public DomainQuery newQuery(KapuaId scopeId) {
44: return new DomainQueryImpl(scopeId);
45: }
46:
47: @Override
48: public Domain newEntity(KapuaId scopeId) {
49: return new DomainImpl(scopeId);
50: }
51:
52: @Override
53: public DomainCreator newCreator(KapuaId scopeId) {
54: throw new NotImplementedException();
55: }
56:
57: @Override
58: public Domain clone(Domain domain) {
59: return new DomainImpl(domain);
60: }
61: }