How to make switch case accept multiple data types in Java?

Posted by Starx on Stack Overflow See other posts from Stack Overflow or by Starx
Published on 2010-06-07T06:49:19Z Indexed on 2010/06/07 6:52 UTC
Read the original article Hit count: 126

Filed under:
|

While using Java's switch case, it excepts only char and int, but I want to provide string cases. How to make this possible?

© Stack Overflow or respective owner

Related posts about java

Related posts about switch-statement