You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by da...@apache.org on 2018/02/28 13:40:26 UTC

[isis] branch master updated: fixes compile issues from merge

This is an automated email from the ASF dual-hosted git repository.

danhaywood pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
     new 59da0e2  fixes compile issues from merge
59da0e2 is described below

commit 59da0e20757556290eb362b3842591b237eb77d4
Author: Dan Haywood <da...@haywood-associates.co.uk>
AuthorDate: Wed Feb 28 13:39:56 2018 +0000

    fixes compile issues from merge
---
 .../services/exceprecog/ExceptionRecognizerAbstract.java     |  8 ++++----
 .../services/exceprecog/ExceptionRecognizerForType.java      |  3 +--
 .../schema/utils/jaxbadapters/PersistentEntitiesAdapter.java | 12 ++++--------
 3 files changed, 9 insertions(+), 14 deletions(-)

diff --git a/core/applib/src/main/java/org/apache/isis/applib/services/exceprecog/ExceptionRecognizerAbstract.java b/core/applib/src/main/java/org/apache/isis/applib/services/exceprecog/ExceptionRecognizerAbstract.java
index 0962c7f..ca73163 100644
--- a/core/applib/src/main/java/org/apache/isis/applib/services/exceprecog/ExceptionRecognizerAbstract.java
+++ b/core/applib/src/main/java/org/apache/isis/applib/services/exceprecog/ExceptionRecognizerAbstract.java
@@ -26,18 +26,18 @@ import java.util.function.Predicate;
 import javax.annotation.PostConstruct;
 import javax.annotation.PreDestroy;
 
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
 import org.apache.isis.applib.annotation.Programmatic;
 import org.apache.isis.applib.internal.exceptions._Exceptions;
 import org.apache.isis.applib.services.i18n.TranslatableString;
 import org.apache.isis.applib.services.i18n.TranslationService;
-import org.junit.internal.Throwables;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
 
 /**
  * Abstract implementation of {@link ExceptionRecognizer} that looks 
  * exceptions meeting the {@link Predicate} supplied in the constructor
- * and, if found anywhere in the {@link Throwables#getCausalChain(Throwable) causal chain},
+ * and, if found anywhere in the causal chain,
  * then returns a non-null message indicating that the exception has been recognized.
  * 
  * <p>
diff --git a/core/applib/src/main/java/org/apache/isis/applib/services/exceprecog/ExceptionRecognizerForType.java b/core/applib/src/main/java/org/apache/isis/applib/services/exceprecog/ExceptionRecognizerForType.java
index 86c2360..2435fb7 100644
--- a/core/applib/src/main/java/org/apache/isis/applib/services/exceprecog/ExceptionRecognizerForType.java
+++ b/core/applib/src/main/java/org/apache/isis/applib/services/exceprecog/ExceptionRecognizerForType.java
@@ -25,12 +25,11 @@ import java.util.function.Predicate;
 import javax.jdo.JDODataStoreException;
 
 import org.apache.isis.applib.internal.exceptions._Exceptions;
-import org.junit.internal.Throwables;
 
 /**
  * An specific implementation of {@link ExceptionRecognizer} that looks for an
  * exception of the type provided in the constructor
- * and, if found anywhere in the {@link Throwables#getCausalChain(Throwable) causal chain},
+ * and, if found anywhere in the causal chain,
  * then returns a non-null message indicating that the exception has been recognized.
  * 
  * <p>
diff --git a/core/applib/src/main/java/org/apache/isis/schema/utils/jaxbadapters/PersistentEntitiesAdapter.java b/core/applib/src/main/java/org/apache/isis/schema/utils/jaxbadapters/PersistentEntitiesAdapter.java
index a09c56b..b976212 100644
--- a/core/applib/src/main/java/org/apache/isis/schema/utils/jaxbadapters/PersistentEntitiesAdapter.java
+++ b/core/applib/src/main/java/org/apache/isis/schema/utils/jaxbadapters/PersistentEntitiesAdapter.java
@@ -25,26 +25,25 @@ import com.google.common.collect.Lists;
 
 import org.apache.isis.applib.services.bookmark.Bookmark;
 import org.apache.isis.applib.services.bookmark.BookmarkService;
-import org.apache.isis.applib.services.bookmark.BookmarkService2;
 import org.apache.isis.schema.common.v1.OidDto;
 import org.apache.isis.schema.common.v1.OidsDto;
 
 public class PersistentEntitiesAdapter extends XmlAdapter<OidsDto, List<Object>> {
 
     @Override
-    public List<Object> unmarshal(final OidsDto oidsDto) throws Exception {
+    public List<Object> unmarshal(final OidsDto oidsDto) {
 
         List<Object> domainObjects = Lists.newArrayList();
         for (final OidDto oidDto : oidsDto.getOid()) {
             final Bookmark bookmark = Bookmark.from(oidDto);
-            Object domainObject = bookmarkService.lookup(bookmark, BookmarkService2.FieldResetPolicy.DONT_RESET);
+            Object domainObject = bookmarkService.lookup(bookmark, BookmarkService.FieldResetPolicy.DONT_RESET);
             domainObjects.add(domainObject);
         }
         return domainObjects;
     }
 
     @Override
-    public OidsDto marshal(final List<Object> domainObjects) throws Exception {
+    public OidsDto marshal(final List<Object> domainObjects) {
         if(domainObjects == null) {
             return null;
         }
@@ -56,9 +55,6 @@ public class PersistentEntitiesAdapter extends XmlAdapter<OidsDto, List<Object>>
         return oidsDto;
     }
 
-    private static String coalesce(final String first, final String second) {
-        return first != null? first: second;
-    }
 
 
     protected BookmarkService getBookmarkService() {
@@ -66,5 +62,5 @@ public class PersistentEntitiesAdapter extends XmlAdapter<OidsDto, List<Object>>
     }
 
     @Inject
-    BookmarkService2 bookmarkService;
+    BookmarkService bookmarkService;
 }

-- 
To stop receiving notification emails like this one, please contact
danhaywood@apache.org.