请输入您要查询的百科知识:

 

词条 ArrayIndexOutOfBoundsException
释义

java.lang

类 ArrayIndexOutOfBoundsException

java.lang.Object

java.lang.Throwable

java.lang.Exception

java.lang.RuntimeException

java.lang.IndexOutOfBoundsException

java.lang.ArrayIndexOutOfBoundsException

所有已实现的接口:

java.io.Serializable

--------------------------------------------------------------------------------

public class ArrayIndexOutOfBoundsExceptionextends IndexOutOfBoundsException用非法索引访问数组时抛出的异常。如果索引为负或大于等于数组大小,则该索引为非法索引。

从以下版本开始:

JDK1.0

另请参见:

序列化表格

--------------------------------------------------------------------------------

构造方法摘要

ArrayIndexOutOfBoundsException()

构造不带详细消息的 ArrayIndexOutOfBoundsException。

ArrayIndexOutOfBoundsException(int index)

用指示非法索引的参数构造新的 ArrayIndexOutOfBoundsException 类。

ArrayIndexOutOfBoundsException(String s)

构造具有指定详细消息的 ArrayIndexOutOfBoundsException 类。

方法摘要

从类 java.lang.Throwable 继承的方法

fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString

从类 java.lang.Object 继承的方法

clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

构造方法详细信息

ArrayIndexOutOfBoundsException

public ArrayIndexOutOfBoundsException()构造不带详细消息的 ArrayIndexOutOfBoundsException。

--------------------------------------------------------------------------------

ArrayIndexOutOfBoundsException

public ArrayIndexOutOfBoundsException(int index)用指示非法索引的参数构造新的 ArrayIndexOutOfBoundsException 类。

参数:

index - 非法索引。

--------------------------------------------------------------------------------

ArrayIndexOutOfBoundsException

public ArrayIndexOutOfBoundsException(String s)构造具有指定详细消息的 ArrayIndexOutOfBoundsException 类。

参数:

s - 详细消息。

随便看

 

百科全书收录4421916条中文百科知识,基本涵盖了大多数领域的百科知识,是一部内容开放、自由的电子版百科全书。

 

Copyright © 2004-2023 Cnenc.net All Rights Reserved
更新时间:2025/2/7 15:51:32