@@ -128,28 +128,6 @@ public RaiseException(RubyException exception, boolean nativeException) {
128
128
preRaise (exception .getRuntime ().getCurrentContext ());
129
129
}
130
130
131
- public RaiseException (Throwable cause , NativeException nativeException ) {
132
- super (nativeException .getMessageAsJavaString (), cause );
133
- providedMessage = super .getMessage (); // cause.getClass().getName() + ": " + message
134
- setException (nativeException , true );
135
- preRaise (nativeException .getRuntime ().getCurrentContext (), nativeException .getCause ().getStackTrace ());
136
- setStackTrace (RaiseException .javaTraceFromRubyTrace (exception .getBacktraceElements ()));
137
- }
138
-
139
- @ Deprecated
140
- public static RaiseException createNativeRaiseException (Ruby runtime , Throwable cause ) {
141
- return createNativeRaiseException (runtime , cause , null );
142
- }
143
-
144
- @ Deprecated
145
- public static RaiseException createNativeRaiseException (Ruby runtime , Throwable cause , Member target ) {
146
- NativeException nativeException = new NativeException (runtime , runtime .getNativeException (), cause );
147
-
148
- // FIXME: someday, add back filtering of reflection/handle methods between JRuby and target
149
-
150
- return new RaiseException (cause , nativeException );
151
- }
152
-
153
131
@ Override
154
132
public String getMessage () {
155
133
if (providedMessage == null ) {
@@ -243,4 +221,25 @@ public static StackTraceElement[] javaTraceFromRubyTrace(RubyStackTraceElement[]
243
221
}
244
222
return newTrace ;
245
223
}
224
+
225
+ @ Deprecated
226
+ public static RaiseException createNativeRaiseException (Ruby runtime , Throwable cause ) {
227
+ return createNativeRaiseException (runtime , cause , null );
228
+ }
229
+
230
+ @ Deprecated
231
+ public static RaiseException createNativeRaiseException (Ruby runtime , Throwable cause , Member target ) {
232
+ NativeException nativeException = new NativeException (runtime , runtime .getNativeException (), cause );
233
+
234
+ return new RaiseException (cause , nativeException );
235
+ }
236
+
237
+ @ Deprecated
238
+ public RaiseException (Throwable cause , NativeException nativeException ) {
239
+ super (nativeException .getMessageAsJavaString (), cause );
240
+ providedMessage = super .getMessage (); // cause.getClass().getName() + ": " + message
241
+ setException (nativeException , true );
242
+ preRaise (nativeException .getRuntime ().getCurrentContext (), nativeException .getCause ().getStackTrace ());
243
+ setStackTrace (RaiseException .javaTraceFromRubyTrace (exception .getBacktraceElements ()));
244
+ }
246
245
}
0 commit comments