How does one perform iteration over an ArrayList in Java, and could you provide a comprehensive explanation along with illustrative code examples or methods showcasing the effective techniques for iterating through elements within an ArrayList in the Java programming language?