java.lang.ClassCastException: Object2 cannot be cast to Object1

Coderanch | Tom Landry | 4 years ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    Casting

    Coderanch | 4 years ago | Tom Landry
    java.lang.ClassCastException: Object2 cannot be cast to Object1

    Root Cause Analysis

    1. java.lang.ClassCastException

      Object2 cannot be cast to Object1

      at Object1.main()
    2. Unknown
      Object1.main
      1. Object1.main(Object1.java:21)
      1 frame