Skip to content

Package: DeviceManagementOperationQueryImpl

DeviceManagementOperationQueryImpl

nameinstructionbranchcomplexitylinemethod
DeviceManagementOperationQueryImpl(KapuaId)
M: 6 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 3 C: 0
0%
M: 1 C: 0
0%
getDefaultSortCriteria()
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) 2017, 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.device.management.registry.operation.internal;
14:
15: import org.eclipse.kapua.commons.model.query.AbstractKapuaQuery;
16: import org.eclipse.kapua.model.id.KapuaId;
17: import org.eclipse.kapua.model.query.KapuaSortCriteria;
18: import org.eclipse.kapua.model.query.SortOrder;
19: import org.eclipse.kapua.service.device.management.registry.operation.DeviceManagementOperationAttributes;
20: import org.eclipse.kapua.service.device.management.registry.operation.DeviceManagementOperationQuery;
21:
22: /**
23: * {@link DeviceManagementOperationQuery} implementation.
24: *
25: * @since 1.1.0
26: */
27: public class DeviceManagementOperationQueryImpl extends AbstractKapuaQuery implements DeviceManagementOperationQuery {
28:
29: /**
30: * Constructor.
31: *
32: * @since 1.1.0
33: */
34: private DeviceManagementOperationQueryImpl() {
35: super();
36: }
37:
38: /**
39: * Constructor.
40: *
41: * @param scopeId The {@link #getScopeId()}.
42: * @since 1.1.0
43: */
44: public DeviceManagementOperationQueryImpl(KapuaId scopeId) {
45: this();
46:
47: setScopeId(scopeId);
48: }
49:
50: @Override
51: public KapuaSortCriteria getDefaultSortCriteria() {
52: return fieldSortCriteria(DeviceManagementOperationAttributes.STARTED_ON, SortOrder.ASCENDING);
53: }
54: }