Skip to content

UseNameSuffix for specific source and target #175

@Alysaar

Description

@Alysaar

Hi,
The documentation says that you can use UseNameSuffix and UseNamePattern for a specific source and target like so :

var anonSource = new { _PriceValue = default(double) };

Mapper.WhenMapping
    .From(anonSource)  // Apply to this anon type's mappings
    .ToANew<Product>() // Apply to Product creations
    .UseNamePattern("^_(.+)Value$"); // Match '_PriceValue' to 'Price'

However when I try it it does not seem to be implemented.

Here is an example of code that I expected to work but UseNameSuffix is not recognized :

Mapper.WhenMapping
                .From<object>()
                .To<object>()
                .UseNameSuffix("test");

Am I missing something ?
Thank you.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions