com.newrelic.weave.violation.ENUM_NEW_FIELD.md Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of newrelic-weaver Show documentation
Show all versions of newrelic-weaver Show documentation
The Weaver of the Java agent.
## ENUM_NEW_FIELD ##
###Description###
This violation was raised because the @Weave enum cannot have new fields.
###Example###
####Original Class####
```
public enum Example {
FOO, BAR
}
```
####Bad####
```
@Weave
public enum Example {
FOO, BAR;
@NewField
int bad;
}
```
----------
####Good####
```
@Weave
public enum Example {
FOO, BAR
}
```
© 2015 - 2024 Weber Informatics LLC | Privacy Policy