summaryrefslogtreecommitdiffstats
path: root/adapters/mso-catalog-db-adapter/src/main/java
diff options
context:
space:
mode:
authormarcinrzepeckiwroc <marcin.rzepecki@nokia.com>2020-06-25 14:03:00 +0200
committermarcinrzepeckiwroc <marcin.rzepecki@nokia.com>2020-06-29 14:32:09 +0200
commit595c7829b0ede975fffe4db0a7c8ec9c2affb688 (patch)
tree172b4f869159a523b34bdfed989792c1307150f2 /adapters/mso-catalog-db-adapter/src/main/java
parent4e708254b1914cee9b3a375374b9b1e486625c1b (diff)
Replace lambda with a method reference
Issue-ID: SO-1841 Signed-off-by: marcinrzepeckiwroc <marcin.rzepecki@nokia.com> Change-Id: Idafac15166c6077895f645d1b9df1be7409ba5f1
Diffstat (limited to 'adapters/mso-catalog-db-adapter/src/main/java')
-rw-r--r--adapters/mso-catalog-db-adapter/src/main/java/org/onap/so/adapters/catalogdb/CatalogDbRepositoryConfiguration.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/adapters/mso-catalog-db-adapter/src/main/java/org/onap/so/adapters/catalogdb/CatalogDbRepositoryConfiguration.java b/adapters/mso-catalog-db-adapter/src/main/java/org/onap/so/adapters/catalogdb/CatalogDbRepositoryConfiguration.java
index fdec7cf5d6..4d8f55e220 100644
--- a/adapters/mso-catalog-db-adapter/src/main/java/org/onap/so/adapters/catalogdb/CatalogDbRepositoryConfiguration.java
+++ b/adapters/mso-catalog-db-adapter/src/main/java/org/onap/so/adapters/catalogdb/CatalogDbRepositoryConfiguration.java
@@ -20,8 +20,8 @@
package org.onap.so.adapters.catalogdb;
-import java.util.stream.Collectors;
import javax.persistence.EntityManager;
+import javax.persistence.metamodel.Type;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Configuration;
import org.springframework.data.rest.core.config.RepositoryRestConfiguration;
@@ -35,8 +35,8 @@ public class CatalogDbRepositoryConfiguration extends RepositoryRestConfigurerAd
@Override
public void configureRepositoryRestConfiguration(RepositoryRestConfiguration config) {
- config.exposeIdsFor(entityManager.getMetamodel().getEntities().stream().map(e -> e.getJavaType())
- .collect(Collectors.toList()).toArray(new Class[0]));
+ config.exposeIdsFor(
+ entityManager.getMetamodel().getEntities().stream().map(Type::getJavaType).toArray(Class[]::new));
}
}