该任务将捕捉异常,并且正确地、清晰地向用户报告状态。
The task catches that exception and reports the state back properly and cleanly to the user.
在之前版本的。NET里,捕捉异常和抛出异常的线程一般是相同的。
In previous versions of.net exceptions were expected to be caught on the same thread that they were thrown on.
API契约方式需要定义抛出异常的客户机和捕捉异常的装置都需要知道的类。
The API-contract way is to define a class known to both the throwing client and the catching harness.
您应该对成员函数向您掷出的所有异常编制文档,以便其它程序员知道他们的代码将需要捕捉什么。
You should document any and all exceptions that a member function throws at you so that other programmers know what their code will need to catch.
我们在捕捉到异常时设置此错误。
首先,在本实例中,用户需要在选择的BPEL活动中添加故障处理程序,来捕捉其抛出的异常。
First, in this example, you need to add a fault handler on the selected BPEL activity to catch the exceptions it throws.
值得注意的是,除非您捕捉从构造函数抛出的异常,否则,如果php脚本未能连接到数据库,它将终止。
It's worth noting that, unless you catch exceptions that are thrown from the constructor, your PHP script will terminate if it could not connect to the database.
你可以捕捉这些异常,也可以让它停止执行。
You can handle these exceptions, or you can let them stop execution.
SOAP方法调用是在try-except块中执行的,一般来说,这种方式比较好,但这里我们这样做只是捕捉 SOAP.faultType异常。
The SOAP method call is performed within a try - except block, which is generally good style, but here we do it specifically to catch a SOAP.faultType exception.
这就是——如您所期待的——一个异常处理器,它现在将会捕捉如果mkdir不能创建请求的目录而被抛出的E739错误。
This is — as you might expect — an exception handler, which will now catch the E739 error that is thrown if mkdir is unable to create the requested directory.
命令bean被实例化,trycatch块被用于捕捉由于重复的用户、无效的信用卡或未经认证的信用卡而产生的异常。
The command bean is instantiated and a try catch block is used to catch exceptions generated from a duplicate user, an invalid credit card, or an unauthorized credit card.
由于远程文件可能不存在,所以我们需要捕捉当我们试图去查看一个不存在的文件的时间戳的时候Net: SFTP抛出的异常。
Since the remote file may not exist yet, we need to catch the exception that Net: : SFTP will throw when we try to determine its timestamp.
MessageBrokerToolkit中的流调试器用于跟踪消息并捕捉任何安全性异常。
The flow debugger in the message Broker Toolkit is used to track messages and catch any security exceptions.
关于这个问题,有一点值得注意:尽管本系列中的示例使用 try-catch() 代码块来捕捉和处理异常,但这并不是必须的。
While on the subject, it's worth noting that although the examples in this series use try-catch() blocks to trap and handle exceptions, this isn't strictly necessary.
你可以使用一个下划线(Scala的标准通配符)作为占位符来捕捉任意类型的异常(不骗你,它可以匹配模式匹配表达式的任何case)。
You can use an underscore (Scala's standard wild card character) as a placeholder to catch any type of exception (really, to match any case in a pattern matching expression).
如果这个异常没有被捕捉到,它将立即关闭应用程序,并将一条错误消息和栈跟踪输出到控制台。
If this exception isn't caught, it will immediately kill the application with an error message and stack trace dumped to the console.
您可能希望捕捉所遇到的所有异常,然后输出这些异常以便调试。
You probably want to trap any exceptions that are encountered and output them for debugging purposes.
坦白说我希望任何情形这个异常都是不能被捕捉的。
Personally I'd prefer it not be catch-able in any circumstance.
您还能“捕捉(catch)”异常,以便使用错误捕获运算符(|)来管理Blue中的错误。
You can also "catch" exceptions to manage errors in Blue with the error-trapping operator (|).
如果内容不受支持,那么代码抛出一个异常,此异常由try - catch块捕捉到。
If the content isn't supported, the code throws an exception, which is caught by the try-catch block.
将出错的代码包装在一个try块中,并捕捉抛出的异常。
Wrap a try block around the offending code, and catch any exceptions that are thrown.
方法捕捉其他异常(比如MalformedURLException和IOException)并抛出定制的异常,让GWT客户机可以捕捉到它。
The method will catch other exceptions such as MalformedURLException and IOException and throw the custom exception so that it can be caught by the GWT client.
还要注意,Objectify的异常未经检查—这表示我无需担心捕捉到很多exception类型。
Also note that Objectify's exceptions are unchecked - which means I don't have to worry about catching a bunch of exception types.
一个替代的方法是,您也可以在代码中直接捕捉这个异常,并且用其他方式处理异常(例如,可能会与使用信息一起输出真正的错误消息)。
As an alternative, you can catch this exception directly in your code and handle it some other way (perhaps printing out the actual error message along with usage information, for instance).
委托不捕捉任何异常。
当catch()方法捕捉到一个NullPointerException 异常时,这个选项会产生一个系统转储文件
This option produces a system dump when a NullPointerException is caught by the catch() method
只捕捉要显式处理的异常。
几乎每个人都捕捉偶尔感冒,但有些人感冒相当频繁,和其他人生病往往留一个异常长的时间。
Nearly everyone catches colds occasionally, but some people catch colds quite frequently, and others tend to stay sick an unusually long time.
我想如果我要执行相同的动作捕捉每一个个体的异常类型?
Do I need to catch each individual exception type if I'm going to perform the same action?
它是坏的包装过程在捕捉运行时异常?
Is it bad to wrap a process around with a catch of runtime exception?
应用推荐