You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@uima.apache.org by sc...@apache.org on 2017/09/15 18:05:15 UTC
svn commit: r1808471 - in /uima/uv3/uimaj-v3/trunk/uimaj-core/src/main:
java/org/apache/uima/ java/org/apache/uima/cas/
java/org/apache/uima/cas/admin/ java/org/apache/uima/cas/impl/
resources/org/apache/uima/
Author: schor
Date: Fri Sep 15 18:05:15 2017
New Revision: 1808471
URL: http://svn.apache.org/viewvc?rev=1808471&view=rev
Log:
[UIMA-5574][UIMA-5573] finish partial update to exceptions, add new exception for lazy JCas setup.
Modified:
uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMARuntimeException.java
uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMA_IllegalArgumentException.java
uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMA_IllegalStateException.java
uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMA_UnsupportedOperationException.java
uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/cas/CASRuntimeException.java
uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/cas/admin/CASAdminException.java
uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/cas/impl/LowLevelException.java
uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/resources/org/apache/uima/UIMAException_Messages.properties
Modified: uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMARuntimeException.java
URL: http://svn.apache.org/viewvc/uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMARuntimeException.java?rev=1808471&r1=1808470&r2=1808471&view=diff
==============================================================================
--- uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMARuntimeException.java (original)
+++ uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMARuntimeException.java Fri Sep 15 18:05:15 2017
@@ -22,7 +22,7 @@ package org.apache.uima;
import java.util.Locale;
/**
- * This is the superclass for all checked exceptions in UIMA.
+ * This is the superclass for all unchecked exceptions in UIMA.
*
* It adds use of a "standard" bundle resource, if the subclasses don't define this.
*
@@ -236,6 +236,11 @@ public class UIMARuntimeException extend
mMessageBundle = messageBundle;
}
+ public UIMARuntimeException(Throwable aCause, String messageBundle, String messageKey, Object ... aArguments) {
+ this(aCause, messageKey, aArguments);
+ mMessageBundle = messageBundle;
+ }
+
/**
* Creates a new exception with the specified message and cause.
*
Modified: uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMA_IllegalArgumentException.java
URL: http://svn.apache.org/viewvc/uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMA_IllegalArgumentException.java?rev=1808471&r1=1808470&r2=1808471&view=diff
==============================================================================
--- uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMA_IllegalArgumentException.java (original)
+++ uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMA_IllegalArgumentException.java Fri Sep 15 18:05:15 2017
@@ -100,7 +100,7 @@ public class UIMA_IllegalArgumentExcepti
*/
public UIMA_IllegalArgumentException(String aResourceBundleName, String aMessageKey,
Object[] aArguments, Throwable aCause) {
- super(aResourceBundleName, aMessageKey, aArguments, aCause);
+ super(aCause, aResourceBundleName, aMessageKey, aArguments);
}
/**
@@ -133,6 +133,6 @@ public class UIMA_IllegalArgumentExcepti
* the original exception that caused this exception to be thrown, if any
*/
public UIMA_IllegalArgumentException(String aMessageKey, Object[] aArguments, Throwable aCause) {
- super(aMessageKey, aArguments, aCause);
+ super(aCause, aMessageKey, aArguments);
}
}
Modified: uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMA_IllegalStateException.java
URL: http://svn.apache.org/viewvc/uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMA_IllegalStateException.java?rev=1808471&r1=1808470&r2=1808471&view=diff
==============================================================================
--- uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMA_IllegalStateException.java (original)
+++ uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMA_IllegalStateException.java Fri Sep 15 18:05:15 2017
@@ -82,6 +82,11 @@ public class UIMA_IllegalStateException
public static final String CANNOT_SET_CAS_MANAGER = "cannot_set_cas_manager";
/**
+ * Cannot do feature accessing for JCas class {0}, because it is not associated with a committed UIMA Type, either because the type doesn''t exist, or hasn''t been committed.
+ */
+ public static final String JCAS_NO_TYPE = "JCAS_NO_TYPE";
+
+ /**
* Creates a new exception with a null message.
*/
public UIMA_IllegalStateException() {
@@ -135,7 +140,7 @@ public class UIMA_IllegalStateException
*/
public UIMA_IllegalStateException(String aResourceBundleName, String aMessageKey,
Object[] aArguments, Throwable aCause) {
- super(aResourceBundleName, aMessageKey, aArguments, aCause);
+ super(aCause, aResourceBundleName, aMessageKey, aArguments);
}
/**
@@ -168,6 +173,6 @@ public class UIMA_IllegalStateException
* the original exception that caused this exception to be thrown, if any
*/
public UIMA_IllegalStateException(String aMessageKey, Object[] aArguments, Throwable aCause) {
- super(aMessageKey, aArguments, aCause);
+ super(aCause, aMessageKey, aArguments);
}
}
Modified: uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMA_UnsupportedOperationException.java
URL: http://svn.apache.org/viewvc/uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMA_UnsupportedOperationException.java?rev=1808471&r1=1808470&r2=1808471&view=diff
==============================================================================
--- uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMA_UnsupportedOperationException.java (original)
+++ uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/UIMA_UnsupportedOperationException.java Fri Sep 15 18:05:15 2017
@@ -108,7 +108,7 @@ public class UIMA_UnsupportedOperationEx
*/
public UIMA_UnsupportedOperationException(String aResourceBundleName, String aMessageKey,
Object[] aArguments, Throwable aCause) {
- super(aResourceBundleName, aMessageKey, aArguments, aCause);
+ super(aCause, aResourceBundleName, aMessageKey, aArguments);
}
/**
Modified: uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/cas/CASRuntimeException.java
URL: http://svn.apache.org/viewvc/uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/cas/CASRuntimeException.java?rev=1808471&r1=1808470&r2=1808471&view=diff
==============================================================================
--- uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/cas/CASRuntimeException.java (original)
+++ uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/cas/CASRuntimeException.java Fri Sep 15 18:05:15 2017
@@ -333,7 +333,7 @@ public class CASRuntimeException extends
}
public CASRuntimeException(String aMessageKey, Object[] aArguments, Throwable aCause) {
- super(aMessageKey, aArguments, aCause);
+ super(aCause, aMessageKey, aArguments);
}
public CASRuntimeException(Throwable aCause, String aMessageKey, Object ... aArguments) {
@@ -346,7 +346,7 @@ public class CASRuntimeException extends
public CASRuntimeException(String aResourceBundleName, String aMessageKey, Object[] aArguments,
Throwable aCause) {
- super(aResourceBundleName, aMessageKey, aArguments, aCause);
+ super(aCause, aResourceBundleName, aMessageKey, aArguments);
}
/**
Modified: uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/cas/admin/CASAdminException.java
URL: http://svn.apache.org/viewvc/uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/cas/admin/CASAdminException.java?rev=1808471&r1=1808470&r2=1808471&view=diff
==============================================================================
--- uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/cas/admin/CASAdminException.java (original)
+++ uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/cas/admin/CASAdminException.java Fri Sep 15 18:05:15 2017
@@ -105,8 +105,7 @@ public class CASAdminException extends U
private String resourceBundleName = DEFAULT_RESOURCE_BUNDLE_NAME;
public CASAdminException(String aResourceBundleName, Throwable aCause, String aMessageKey, Object ... aArguments) {
- super(aCause, aMessageKey, aArguments);
- resourceBundleName = aResourceBundleName;
+ super(aCause, aResourceBundleName, aMessageKey, aArguments);
}
public CASAdminException(String aMessageKey, Object ... aArguments) {
Modified: uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/cas/impl/LowLevelException.java
URL: http://svn.apache.org/viewvc/uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/cas/impl/LowLevelException.java?rev=1808471&r1=1808470&r2=1808471&view=diff
==============================================================================
--- uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/cas/impl/LowLevelException.java (original)
+++ uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/java/org/apache/uima/cas/impl/LowLevelException.java Fri Sep 15 18:05:15 2017
@@ -103,7 +103,7 @@ public class LowLevelException extends U
public LowLevelException(String aMessageKey, Object[] aArguments, Throwable aCause) {
- super(aMessageKey, aArguments, aCause);
+ super(aCause, aMessageKey, aArguments);
}
/** @return The same as getMessage(), but prefixed with <code>"LowLevelException: "</code>. */
Modified: uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/resources/org/apache/uima/UIMAException_Messages.properties
URL: http://svn.apache.org/viewvc/uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/resources/org/apache/uima/UIMAException_Messages.properties?rev=1808471&r1=1808470&r2=1808471&view=diff
==============================================================================
--- uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/resources/org/apache/uima/UIMAException_Messages.properties (original)
+++ uima/uv3/uimaj-v3/trunk/uimaj-core/src/main/resources/org/apache/uima/UIMAException_Messages.properties Fri Sep 15 18:05:15 2017
@@ -529,6 +529,7 @@ JCAS_GETTER_SETTER_MISSING = Unable to f
JCAS_FEATURE_WRONG_TYPE = The JCAS range type {2} for feature {1} of type {0} does not match the CAS range type {3} for the feature.
TYPEORDER_UNKNOWN_TYPE = The type sort order cannot be built because type {0} is unknown.
MUST_COMMIT_TYPE_SYSTEM = Type system has not been committed. The base index cannot be created.
+JCAS_NO_TYPE = Cannot do feature accessing for JCas class {0}, because it is not associated with a committed UIMA Type, either because the type doesn''t exist, or hasn''t been committed.
#------------------------------------------------------------------------