The Artima Developer Community
Sponsored Link

Java Buzz Forum
Java: How To Use Enum in Switch

0 replies.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a flat view of this topic  Flat View
Previous Topic   Next Topic
Threaded View: This topic has 0 replies on 1 page
Angsuman Chakraborty

Posts: 19816
Nickname: angsuman
Registered: Dec, 2003

Angsuman Chakraborty is the CEO and Chief Architect at Taragana
Java: How To Use Enum in Switch Posted: Sep 23, 2008 9:10 AM
Reply to this message Reply

This post originated from an RSS feed registered with Java Buzz by Angsuman Chakraborty.
Original Post: Java: How To Use Enum in Switch
Feed Title: Simple Thoughts - Java and Web Technology Blog
Feed URL: http://tech.gaeatimes.com/index.php/feed/
Feed Description: News and views as a Software Architect and Entrepreneur on Java and Web Software.
Latest Java Buzz Posts
Latest Java Buzz Posts by Angsuman Chakraborty
Latest Posts From Simple Thoughts - Java and Web Technology Blog

When using enums in a switch, it is almost natural to assume they will be used like a regular switch. Unfortunately to accomodate enums, Java had to enhance its specification and enums in switch behave differently than regular switch statements in two significant and non-trivial ways. Sun's Javac says -"enum switch case label must be the [...]
Ads by Yahoo!

Read: Java: How To Use Enum in Switch


Topic: Android XML Weirdness Previous Topic   Next Topic Topic: Frustrating User Experiences: iPhone Dashboard Manipulation

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use