* Call frames for the current suspended state (from the innermost (top) frame to the main (bottom) frame)
*/
@NotNull
- Promise<CallFrame[]> getCallFrames();
+ Promise<CallFrame[]> getFrames();
/**
* @return a set of the breakpoints hit on VM suspension with which this
* will be called.
*/
@NotNull
- Promise<Void> suspend();
+ Promise<?> suspend();
@Nullable
SuspendContext getContext();
@NotNull
@Override
- public final Promise<Void> suspend() {
+ public final Promise<?> suspend() {
Promise<Void> callback = suspendCallback.get();
if (callback != null) {
return callback;
}
@NotNull
- protected abstract Promise<Void> doSuspend();
+ protected abstract Promise<?> doSuspend();
@Override
public boolean isContextObsolete(@NotNull SuspendContext context) {
return;
}
- suspendContext.getCallFrames().done(new ContextDependentAsyncResultConsumer<CallFrame[]>(suspendContext) {
+ suspendContext.getFrames().done(new ContextDependentAsyncResultConsumer<CallFrame[]>(suspendContext) {
@Override
protected void consume(CallFrame[] frames, @NotNull Vm vm) {
int count = frames.length - firstFrameIndex;
if (method.getAnnotation(JsonNullable.class) != null) {
nullable = true;
}
- else if (genericReturnType == String.class || genericReturnType == Enum.class) {
+ else if (genericReturnType == String.class || genericReturnType == Enum.class || (genericReturnType instanceof Class && !((Class)genericReturnType).isPrimitive())) {
JsonField jsonField = method.getAnnotation(JsonField.class);
if (jsonField != null) {
nullable = jsonField.optional() && !jsonField.allowAnyPrimitiveValue() && !jsonField.allowAnyPrimitiveValueAndMap();