From 0c4373663e22ffa18d953b2a9ee6f6b27d559bea Mon Sep 17 00:00:00 2001
From: Munir Ahmad <munir.ahmad@bell.ca>
Date: Wed, 7 Mar 2018 18:59:13 -0500
Subject: Make use of lambda

Change-Id: I482b874a3e7e686068450c7b5ddf45e2b8ae0d47
Issue-ID: SO-437
Signed-off-by: Munir Ahmad <munir.ahmad@bell.ca>
---
 .../mso/bpmn/core/plugins/LoggingAndURNMappingPlugin.java      | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)

(limited to 'bpmn/MSOCoreBPMN/src')

diff --git a/bpmn/MSOCoreBPMN/src/main/java/org/openecomp/mso/bpmn/core/plugins/LoggingAndURNMappingPlugin.java b/bpmn/MSOCoreBPMN/src/main/java/org/openecomp/mso/bpmn/core/plugins/LoggingAndURNMappingPlugin.java
index c346308e2b..730c1451d5 100644
--- a/bpmn/MSOCoreBPMN/src/main/java/org/openecomp/mso/bpmn/core/plugins/LoggingAndURNMappingPlugin.java
+++ b/bpmn/MSOCoreBPMN/src/main/java/org/openecomp/mso/bpmn/core/plugins/LoggingAndURNMappingPlugin.java
@@ -321,14 +321,8 @@ public class LoggingAndURNMappingPlugin extends AbstractProcessEnginePlugin {
 		}
 
 		private void loadFromDB(DelegateExecution execution, ProcessEngineConfigurationImpl processEngineConfiguration) {
-			Command<List<URNMapping>> command = new Command<List<URNMapping>>() {
-				@SuppressWarnings("unchecked")
-				@Override
-				public List<URNMapping> execute(CommandContext commandContext) {
-					return (List<URNMapping>) commandContext.getDbSqlSession().selectList(
-						"mso.urnMapping.selectAll", null);
-				}
-			};
+			Command<List<URNMapping>> command = commandContext -> (List<URNMapping>) commandContext.getDbSqlSession()
+				.selectList("mso.urnMapping.selectAll", null);
 
 			CustomMyBatisSessionFactory sessionFactory = new CustomMyBatisSessionFactory();
 			sessionFactory.initFromProcessEngineConfiguration(processEngineConfiguration,
-- 
cgit