Option to check annotations by shortname or qualifier #11

Closed
opened 2022-12-21 14:23:34 +01:00 by Dutch · 1 comment
Owner

Checking if e.g. a class has a certain annotation can be done in 2 ways:

  1. ShortName
    So only the annotation name like for example: EntityEx
  2. QualifiedName
    So the complete name like e.g.: de.unicorntech.roomex.models.EntityEx

The disadvantage of the 1st variant is that theoretically there can be several annotations with the same name, e.g. from other libraries. Thus a comparison would not be 100% safe.

The disadvantage with the 2nd variant is that the actual data type must be resolved for some declerations, which slows down the compilation phase. For it the comparison is however to 99% safe. Unless a developer publishes annotations under a different package name.

So there should be an option to switch between option 1 and 2.

Checking if e.g. a class has a certain annotation can be done in 2 ways: 1. ShortName So only the annotation name like for example: EntityEx 2. QualifiedName So the complete name like e.g.: de.unicorntech.roomex.models.EntityEx The disadvantage of the 1st variant is that theoretically there can be several annotations with the same name, e.g. from other libraries. Thus a comparison would not be 100% safe. The disadvantage with the 2nd variant is that the actual data type must be resolved for some declerations, which slows down the compilation phase. For it the comparison is however to 99% safe. Unless a developer publishes annotations under a different package name. So there should be an option to switch between option 1 and 2.
Dutch self-assigned this 2022-12-21 14:23:34 +01:00
Dutch added this to the Release v1.0 project 2022-12-21 14:23:34 +01:00
Dutch added this to the v1.0 milestone 2022-12-21 15:35:43 +01:00
Author
Owner

Wont fix.
The current processors are fast enough so that the impact would only be minimal

Wont fix. The current processors are fast enough so that the impact would only be minimal
Dutch closed this issue 2023-01-06 14:48:36 +01:00
Commenting is not possible because the repository is archived.
No labels
No milestone
No project
No assignees
1 participant
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Dutch/RoomEx#11
No description provided.