KickJava   Java API By Example, From Geeks To Geeks.

Java > Java SE, EE, ME > java > lang > ArrayIndexOutOfBoundsException

java.lang
Class ArrayIndexOutOfBoundsException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by java.lang.RuntimeException
              extended by java.lang.IndexOutOfBoundsException
                  extended by java.lang.ArrayIndexOutOfBoundsException
All Implemented Interfaces:
Serializable
See Also:
Top Examples, Source Code

public ArrayIndexOutOfBoundsException()
Geek's Notes:
Description  Add your codes or notes  Search More Java Examples  


public ArrayIndexOutOfBoundsException(int index)
Geek's Notes:
Description  Add your codes or notes  Search More Java Examples  


public ArrayIndexOutOfBoundsException(String s)
Geek's Notes:
Description  Add your codes or notes  Search More Java Examples  


[1154]Catch ArrayIndexOutOfBoundsException
By Anonymous on 2004/11/29 19:12:41  Rate
class ArrayIndexOutOfBoundsException extends Exception {  }  
  
  
 class SimpleException 
  {  
   public void f (  )  throws ArrayIndexOutOfBoundsException 
      {  
       System.out.println ( "Zglaszam wyjatek ArrayIndexOutOfBoundsException w metodzie f (  ) " ) ; 
       throw new ArrayIndexOutOfBoundsException (  ) ; 
      }  
    
   public static void main ( String [  ]  args )  
      {  
       SimpleException bad = new SimpleException (  ) ; 
       try 
          {  
           bad.f (  ) ; 
          }   
       catch ( ArrayIndexOutOfBoundsException e )   
          {  
           System.err.println ( "Wyjatek przechwocony!" ) ; 
          }  
      }  
  } 

Popular Tags