I want to use an custom annotation in a java project. Curretnly i'm having this:
@Parallel(synchronicity=Sync.SYNC, concurrency=Conc.MUTEX)
Sync and Conc are both enums.
This is a little too verbose. Its not that synchronicity is a long word, but that i have to specify the enum name. I would prefer to write it in one of the following ways:
@Parallel(synchronicity=SYNC, concurrency=MUTEX)
@Parallel(Sync.SYNC, Conc.MUTEX)
But both don't seem to be possible. Does anybody have an idea on how to make the usage of enums in an annotation less verbose?