In a separate document (called ExploreMethods.pdf ), you will make a list of (at least) 5 methods
Fantastic news! We've Found the answer you've been seeking!
Question:
In a separate document (called ExploreMethods.pdf), you will make a list of (at least) 5 methods that you have used from other classes.
- For each method, you should identify the major components of the method definition, as well as the class that the method comes from.
- Be sure to explain the expected return values as well as the type.
- Think about what classes you may have used/imported (Scanner, String, Character, Integer, Random, Arrays, Math, ...)
- Use Java API Documentation for the classes/methods if you get stuck. (There is a search bar that I just discovered that should make life easier..)
- Be sure to list methods from at least 3 classes (not including equals() from String as it is used as an example below).
- An example description is provided here:
Method header: public boolean equals (Object obj) (defined in String class)
- Modifiers: public
- Return type: boolean
- true if argument matches the string that called the method
- false if not
- Method Name: equals
- Parameter List: Object obj (String str)
- Input expected is an Object, which can include Strings.
- Note to class:
- If you are confused by Object, remember that Strings aren't primitive types. They are considered objects, and are conceptually an array of chars.
- We'll revisit Objects later (but just keep in mind that Object here means that a String is an acceptable input).
- Signature: equals(Object obj)
Related Book For
Income Tax Fundamentals 2013
ISBN: 9781285586618
31st Edition
Authors: Gerald E. Whittenburg, Martha Altus Buller, Steven L Gill
Posted Date: