actionscript 3 - Get Enum from String in ActionScript3 -


Is there a way in Action Script 3 to get an input from string value? Like I have enum

  public last class day {public stable position Monday: day = new day (); Public static payments today: day = new day (); Public stable command Wednesday: day = new day (); Mass Static Treaty Today: Day = New Day (); Public static const Friday: day = new day (); Public stable concept Saturday: Day = New Day (); Public Static Institution Sunday: Day = New Day (); }  

And I want Man Day. From Monday to "Monday"

Similar to action code in obj.prop obj ["prop"] - has just been confirmed that it also applies to static properties so you can see it like this:

  trace ( Day ["Monday"]);  

Comments

Popular posts from this blog

java - Is there an object like a "Set" that can contain only unique string values, but also contain a count on the number of occurrences of the string value? -

iphone - How do I make a UIPickerView in a UIActionSheet -