EnumSet: added getEnumerators(), getNames() and getValues() #65
  Add this suggestion to a batch that can be applied as a single commit.
  This suggestion is invalid because no changes were made to the code.
  Suggestions cannot be applied while the pull request is closed.
  Suggestions cannot be applied while viewing a subset of changes.
  Only one suggestion per line can be applied in a batch.
  Add this suggestion to a batch that can be applied as a single commit.
  Applying suggestions on deleted lines is not supported.
  You must change the existing code in this line in order to create a valid suggestion.
  Outdated suggestions cannot be applied.
  This suggestion has been applied or marked resolved.
  Suggestions cannot be applied from pending reviews.
  Suggestions cannot be applied on multi-line comments.
  Suggestions cannot be applied while the pull request is queued to merge.
  Suggestion cannot be applied right now. Please check back later.
  
    
  
    
see #62 Add methods to convert a set into an array
EnumSet::getEnumerators() : Enum[]EnumSet::getValues() : scalar[]EnumSet::getNames() : string[]@prolic I decided to use this names to be consistent with the already existing method
Enum::getEnumerators()and I also return it just as lists so the ordinal number will not be the array key. I analyzed all my use-cases and couldn't find any where the ordinal number as array key is required. On the other hand I have some use-cases where I actually require a simple list. Also it's still simple possible to just useiterator_to_array($set)to convert the set into an associative array with ordinal number to enumerator instance.PS: The same set of methods should also work on
EnumMapand onEnum(as static versions)