You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@avro.apache.org by "Hernan Otero (JIRA)" <ji...@apache.org> on 2013/05/08 19:07:15 UTC
[jira] [Created] (AVRO-1327) Having GenericEnumSymbol implement
Comparable (mimic'ing java's Enum)
Hernan Otero created AVRO-1327:
----------------------------------
Summary: Having GenericEnumSymbol implement Comparable (mimic'ing java's Enum)
Key: AVRO-1327
URL: https://issues.apache.org/jira/browse/AVRO-1327
Project: Avro
Issue Type: Improvement
Components: java
Affects Versions: 1.7.4
Reporter: Hernan Otero
Fix For: 1.7.5, 1.8.0
It would be great if we could have GenericEnumSymbol implementing Comparable (either using int or String rep).
This is mainly because GenericEnumSymbol is trying to mimic the java.lang.Enum and enums are inherently comparable that's why java.lang.Enum is Comparable.
Sorting Enum and GenericEnumSymbol is an action that we perform a lot. Making it Comparable frees us from explicit type checking and improves general code clarity and performance.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira