在考虑何时提供错误消息时,有一些因素会发挥作用。
Several factors come into play as you consider when to provide error messages.
如果您没有提供错误消息文本字符串,则使用默认值。
If you do not supply an error message text string, the default is used.
在脚本中使用它来提供关于执行和错误的消息。
Use it in scripts to provide messages about execution and errors.
但是,我们还是必须向程序员提供奇怪的和不直观的错误消息。
But still, we would have to provide the programmer with weird and counter-intuitive error messages.
对于消费者,需要提供不涉及编程术语的、易读的错误消息;
For a consumer, you need to provide a readable error message that doesn't involve programming terms.
当断言失败时,非常有必要提供易于理解的错误消息。
When the assertions fail, it becomes very important to provide error messages that are easy to understand.
错误消息提示文件名被换行符分隔,这就给我们提供了线索。
The clue here is in the error message which shows that the filenames are separated by newline characters.
在我的系统设置中,error函数提供了最有用的结果:错误消息。
With my system setup, the error function provides the most useful result: the error message.
在多数情况下,LotusSametime并没有提供有意义的错误消息,因此您会感到困惑为什么不能加入会议。
In many cases, Lotus Sametime didn't provide you with meaningful error messages, leaving you confused as to why you were unable to join.
如果提供了错误的敲门序列(或根本没有敲门),会收到“Connectiontimed out”消息,SSH端口仍然完全关闭,看不出它是存在的。
If you provided a wrong sequence of knocks (or no knocks at all), you would receive a "Connection timed out" message, and the SSH port would remain completely closed with no sign of its existence.
我还提供了名为showsyserr的小实用程序(请参阅参考资料),它允许您查看系统错误消息。
I've also provided a small utility called showsyserr (see Resources), which allows you to see the system error messages.
错误消息还可以使用XPaths引用被验证的实例的值,提供更多引起违背的原因的信息。
The error message can also use XPaths to refer to values in the instance being validated to provide more information about what is causing the violation.
如果没有提供这些字段值,您可能得到错误消息,例如:Error 9508-CertificateSigningRequestcontainsemptyfield (s)。
If values for these fields are not provided, you might get an error message such as error 9508 - Certificate Signing Request contains empty field (s).
重定向页面也提供了有用的信息:基本的错误消息可能被记入日志,甚至自动为程序员生成bug报告,用于后续处理。
Even the redirect page carries useful information: the underlying error message which might be logged and even used to auto-generate a bug report for programmers to deal with later.
没有错误消息(各地的程序员请注意,异常堆栈跟踪不能当作真正的错误消息,有时,eXist甚至连堆栈跟踪都没有提供给您)。
Error messages are nonexistent. (Note to programmers everywhere: Exception stack traces don't count as decent error messages — and sometimes exist doesn't even give you those.)
此外,它还提供了一些其他的功能,如消息记录、使用数据库中的数据扩充消息、以及根据您的需要定制错误处理。
In addition, it provides functions such as message logging, augmenting messages with data from a database, and error processing that is tailored to your requirements.
一旦找到错误,它必须指出错误的真实原因,最好是提供人们能够理解的错误消息。
When it finds a mistake, it must point to the true reason for it, preferably with an error message that humans understand.
如果为参数提供的任何值是错的,或者此服务器关闭了,用户可能会看到下面的错误消息。
If any of the values provided against the parameters are wrong or if the server is down, then the user might see the following error message.
创建MQ消息传递提供程序资源时,一般情况下,管理名称和JNDI名称在创建它的范围中必须是唯一的,否则会产生错误消息。
When creating an MQ messaging provider resource, in general, the administrative name and JNDI name must be unique at the scope it is created, or an error message will result.
SQLSTATE消息可以提供关于导致错误或警告状况的原因的特定信息,这对于解决错误很有用。
SQLSTATE messages give specific information about what caused an error or warning condition, and are very useful for resolving errors.
服务请求程序通常会将请求发送到服务提供程序,服务提供程序会提供请求的解决方案(如果无法对请求进行处理,则为错误消息)来进行响应。
The service requesters usually send the request to a service provider, which responds with a solution to the request or an error message if the request cannot be processed.
如果一个程序提供详细的错误输出而且表现正常,那么不使用任何特权来运行这个程序,然后检查错误消息,看看它缺少哪些特权。
If a program were verbose and well behaved, it might be possible to simply run the program without privilege and have it complain about which privileges it lacks.
在这两种情况下,对提供合适的错误消息来说,上下文相关的信息至关重要。
In both cases, the contextual information is critical to provide a suitable error message.
jsp容器确保JS p页的语法正确,当遇到错误时会生成提供相关信息的错误消息。
The JSP container ensures that the syntax of the JSP page is correct, and generates informative error messages when it encounters errors.
如果连接未成功,则会显示错误消息,并提供GUI尝试连接的详细信息。
If the connection is unsuccessful, an error message will appear with the details of the connection the GUI tried to make.
它先将您的字符串参数写至标准错误(提供它用于定制消息),接下来写入一个冒号和一个空格,然后是系统错误消息,后面是新的一行。
It writes your string argument to stderr (standard error), followed by a colon and a space, then the system error message followed by a newline.
比如,清单16展示了如何在一个标注内的“appinfo”元素中包括一个定制的错误消息,并使用“documentation”提供有关该消息的额外信息。
For example, Listing 16 shows how to include a customized error message in the "appinfo" element inside an annotation and use "documentation" to provide additional information about the message.
管理控制台中的DeployNew菜单提供了无法部署的WAR文件的详细错误消息。
The deploy New menu in the administrative console provides a detailed error message for a WAR file that cannot deploy.
SpringDAO:JDBC DAO抽象层提供了有意义的异常层次结构,可用该结构来管理异常处理和不同数据库供应商抛出的错误消息。
Spring DAO: the Spring JDBC DAO abstraction layer offers a meaningful exception hierarchy for managing the exception handling and error messages thrown by different database vendors.
因此 CGI::Carp函数提供了一个fatalsToBrowser选项将致命错误消息(die()、confess())重新指向浏览器和Web服务器日志。
The CGI::Carp function therefore also provides a fatalsToBrowser option that redirects fatal error messages ( die(), confess() ) back to the browser, as well as to the web server log.
应用推荐