mirror of
https://repository.entgra.net/community/device-mgt-core.git
synced 2025-10-06 02:01:45 +00:00
Retuen int for operations
This commit is contained in:
parent
27279426f0
commit
25a8f60d74
@ -36,7 +36,7 @@ public interface OperationManager {
|
|||||||
* @throws OperationManagementException If some unusual behaviour is observed while adding the
|
* @throws OperationManagementException If some unusual behaviour is observed while adding the
|
||||||
* operation
|
* operation
|
||||||
*/
|
*/
|
||||||
public boolean addOperation(Operation operation, List<DeviceIdentifier> devices) throws OperationManagementException;
|
public int addOperation(Operation operation, List<DeviceIdentifier> devices) throws OperationManagementException;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Method to retrieve the list of all operations to a device.
|
* Method to retrieve the list of all operations to a device.
|
||||||
|
|||||||
@ -74,7 +74,7 @@ public class OperationManagerImpl implements OperationManager {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean addOperation(Operation operation,
|
public int addOperation(Operation operation,
|
||||||
List<DeviceIdentifier> deviceIds) throws OperationManagementException {
|
List<DeviceIdentifier> deviceIds) throws OperationManagementException {
|
||||||
|
|
||||||
if (log.isDebugEnabled()) {
|
if (log.isDebugEnabled()) {
|
||||||
@ -105,7 +105,7 @@ public class OperationManagerImpl implements OperationManager {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
OperationManagementDAOFactory.commitTransaction();
|
OperationManagementDAOFactory.commitTransaction();
|
||||||
return true;
|
return operationId;
|
||||||
} catch (OperationManagementDAOException e) {
|
} catch (OperationManagementDAOException e) {
|
||||||
try {
|
try {
|
||||||
OperationManagementDAOFactory.rollbackTransaction();
|
OperationManagementDAOFactory.rollbackTransaction();
|
||||||
|
|||||||
@ -495,7 +495,7 @@ public class DeviceManagementProviderServiceImpl implements DeviceManagementProv
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean addOperation(Operation operation, List<DeviceIdentifier> devices) throws
|
public int addOperation(Operation operation, List<DeviceIdentifier> devices) throws
|
||||||
OperationManagementException {
|
OperationManagementException {
|
||||||
return DeviceManagementDataHolder.getInstance().getOperationManager().addOperation(operation, devices);
|
return DeviceManagementDataHolder.getInstance().getOperationManager().addOperation(operation, devices);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user