English 中文(简体)
暂时无法拿到财产或方法时投掷物有什么例外?
原标题:What exception to throw when a property or a method being accessed is temporarily unavailable?

暂时无法找到财产或方法时,还有哪些例外(因为在物体的目前状态下没有意义)?

下面是我心目中的一个半可笑的例子,如果你发现问题本身,不会认为它过于严重。

Afraction <代码> 编号denominator改为-and-write nature and quotient读取的财产。 denominator<>/code> not equal 0 然后, >ient 即应交 序号/denominator。 否则,要提出一个例外,即对物的目前状况没有界定/可动用的财产价值(请不提供t >ArithmeticException或DivideByZeroException,问题并不涉及对面测量,而是更接近于有限的国家机器。

另一个例子是,如果计算尚未完成,则可以放弃例外。

我有兴趣回答 Java和网络平台。

最佳回答

java.lang.IllegalStateException

表明一种方法在非法或不适当的时候被援引。 换言之, Java环境或 Java应用在要求的行动中并不合适。

问题回答

暂无回答




相关问题
Spring Properties File

Hi have this j2ee web application developed using spring framework. I have a problem with rendering mnessages in nihongo characters from the properties file. I tried converting the file to ascii using ...

Logging a global ID in multiple components

I have a system which contains multiple applications connected together using JMS and Spring Integration. Messages get sent along a chain of applications. [App A] -> [App B] -> [App C] We set a ...

Java Library Size

If I m given two Java Libraries in Jar format, 1 having no bells and whistles, and the other having lots of them that will mostly go unused.... my question is: How will the larger, mostly unused ...

How to get the Array Class for a given Class in Java?

I have a Class variable that holds a certain type and I need to get a variable that holds the corresponding array class. The best I could come up with is this: Class arrayOfFooClass = java.lang....

SQLite , Derby vs file system

I m working on a Java desktop application that reads and writes from/to different files. I think a better solution would be to replace the file system by a SQLite database. How hard is it to migrate ...

热门标签