|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.ObjectAssertExamples
public class AssertExamples
The AssertExamples Java application demonstrates the Java assert statement.
| Constructor Summary | |
|---|---|
AssertExamples()
|
|
| Method Summary | |
|---|---|
static void |
main(java.lang.String[] args)
The main method demonstrates calls to maxOf3 and maxOfArray . |
static int |
maxOf3(int a,
int b,
int c)
Returns the largest of three int values. |
static int |
maxOfArray(int[] a)
Returns the largest value in an array |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AssertExamples()
| Method Detail |
|---|
public static void main(java.lang.String[] args)
public static int maxOf3(int a,
int b,
int c)
a - any int valueb - any int valuec - any int value
public static int maxOfArray(int[] a)
a - an array of int valuesjava.lang.ArrayIndexOutOfBounds - Indicates that a.length <= 0.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||