[MDSAL-642] Improve DataObjectBuilder augmentation handling Created: 10/Nov/20 Updated: 16/Nov/20 Resolved: 16/Nov/20 |
|
| Status: | Resolved |
| Project: | mdsal |
| Component/s: | Binding codegen |
| Affects Version/s: | None |
| Fix Version/s: | 7.0.3 |
| Type: | Improvement | Priority: | Medium |
| Reporter: | Robert Varga | Assignee: | Tadey Bilan |
| Resolution: | Done | Votes: | 0 |
| Labels: | pt | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Description |
|
For copy builders we generate the following:
public SrAlgorithmBuilder(SrAlgorithm base) {
@SuppressWarnings("unchecked")
Map<Class<? extends Augmentation<SrAlgorithm>>, Augmentation<SrAlgorithm>> aug = base.augmentations();
if (!aug.isEmpty()) {
this.augmentation = new HashMap<>(aug);
}
this._algorithms = base.getAlgorithms();
}
Eclipse warns here that the @SuppressWarnings line is unnecessary and is very right about that. Remove this line. |