v.io/x/ref/lib/vdl/codegen/java: use new verror interface
Change-Id: Ia291ed7d5241deb6e61c308f78814fddbed5d6e2
diff --git a/lib/vdl/codegen/java/file_errors.go b/lib/vdl/codegen/java/file_errors.go
index cd43dff..ac2c49e 100644
--- a/lib/vdl/codegen/java/file_errors.go
+++ b/lib/vdl/codegen/java/file_errors.go
@@ -49,7 +49,7 @@
public static io.v.v23.verror.VException {{ $error.MethodName }}(io.v.v23.context.VContext _ctx{{ $error.MethodArgs}}) {
final java.lang.Object[] _params = new java.lang.Object[] { {{ $error.Params }} };
final java.lang.reflect.Type[] _paramTypes = new java.lang.reflect.Type[]{ {{ $error.ParamTypes }} };
- return io.v.v23.verror.VException.make({{ $error.Name }}, _ctx, _paramTypes, _params);
+ return new io.v.v23.verror.VException({{ $error.Name }}, _ctx, _paramTypes, _params);
}
{{ end }} {{/* range $file.Errors */}}
{{ end }} {{/* range .Files */}}
@@ -114,7 +114,7 @@
errors[j].ActionName = vdlutil.ToConstCase(err.RetryCode.String())
errors[j].EnglishFmt = err.English
errors[j].Formats = formats
- errors[j].MethodName = "make" + vdlutil.FirstRuneToUpper(err.Name)
+ errors[j].MethodName = "new" + vdlutil.FirstRuneToUpper(err.Name)
errors[j].MethodArgs = javaDeclarationArgStr(err.Params, env, true)
errors[j].Params = javaCallingArgStr(err.Params, false)
errors[j].ParamTypes = javaCallingArgTypeStr(err.Params, env)