Skip to content

Fully infer object mapper without a class body #13

@stefankoppier

Description

@stefankoppier

Is your feature request related to a problem? Please describe.
When writing a mapper without any explicit mappings has a lot of boilerplate. For example, in

object MyMapper : ObjectMappie<Something, SomethingDto>() {
    override fun map(from: Something): SomethingDto = mapping()
}

the map function declaration is boilerplate.

Describe the solution you'd like
Writing object object MyMapper : ObjectMappie<Something, SomethingDto>() should be sufficient, and equivalent to a map body without any explicit mappings.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions