All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.sonar.l10n.delphi.rules.community-delphi.AttributeName.html Maven / Gradle / Ivy

There is a newer version: 1.12.1
Show newest version

Why is this an issue?

Code that follows a consistent naming convention is self-documenting. In Delphi, all custom attribute class names should be in PascalCase and end with Attribute. No prefix is required.

Custom attributes suffixed with Attribute may have the suffix omitted when used. This means that attributes can be defined with the same name (e.g. MyCustom and MyCustomAttribute), which may cause unexpected behaviour.

To safeguard against this, the Attribute suffix should be used consistently. The suffix is also recommended for clarity, as attribute classes should not be used in other ways or instantiated directly.

How to fix it

Rename the attribute class name to follow the convention.

Resources





© 2015 - 2024 Weber Informatics LLC | Privacy Policy