Skip to content

Wrong decorator class name used when Decorator class is nested inside mapper interface #2021

Description

@xak2000

Example:

@Mapper
@DecoratedWith(MyMapper.Decorator.class)
public interface MyMapper {
    abstract class Decorator implements MyMapper {}
}

Generated implementation example:

public class MyMapperImpl extends Decorator implements MyMapper {
...
}

Here class Decorator is not imported and not qualified by it's outer class name (like MyMapper.Decorator), so implementation just doesn't compile.

The right implementation should be:

public class MyMapperImpl extends MyMapper.Decorator implements MyMapper {
...
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions