Exemplo n.º 1
0
 protected override void Configure()
 {
     SourceMemberNamingConvention = new PascalCaseNamingConvention();
     DestinationMemberNamingConvention = new LowerUnderscoreNamingConvention();
     CreateMap<SchemaField, SchemaFieldDto>();
     CreateMap<Schema, SchemaDto>();
 }
 public FormatterExpression(Func <Type, IValueFormatter> formatterCtor)
 {
     _formatterCtor = formatterCtor;
     SourceMemberNamingConvention      = new PascalCaseNamingConvention();
     DestinationMemberNamingConvention = new PascalCaseNamingConvention();
     RecognizePrefixes("Get");
     AllowNullDestinationValues = true;
 }
Exemplo n.º 3
0
 public FormatterExpression(Func <Type, IValueFormatter> formatterCtor)
 {
     _formatterCtor = formatterCtor;
     SourceMemberNamingConvention      = new PascalCaseNamingConvention();
     DestinationMemberNamingConvention = new PascalCaseNamingConvention();
     SourceMemberNameTransformer       = s => Regex.Replace(s, "(?:^Get)?(.*)", "$1");
     DestinationMemberNameTransformer  = s => s;
     AllowNullDestinationValues        = true;
 }
Exemplo n.º 4
0
 public FormatterExpression(Func <Type, IValueFormatter> formatterCtor)
 {
     _formatterCtor = formatterCtor;
     SourceMemberNamingConvention      = new PascalCaseNamingConvention();
     DestinationMemberNamingConvention = new PascalCaseNamingConvention();
     RecognizePrefixes("Get");
     AllowNullDestinationValues = true;
     ConstructorMappingEnabled  = true;
     IncludeSourceExtensionMethods(typeof(Enumerable).Assembly);
 }
Exemplo n.º 5
0
        protected Profile()
        {
            ProfileName = GetType().FullName;

            AddMemberConfiguration()
            .AddMember <NameSplitMember>()
            .AddName <PrePostfixName>(_ => _.AddStrings(p => p.Prefixes, "Get"));

            SourceMemberNamingConvention      = new PascalCaseNamingConvention();
            DestinationMemberNamingConvention = new PascalCaseNamingConvention();
        }
Exemplo n.º 6
0
        protected override void Configure()
        {
            SourceMemberNamingConvention = new LowerUnderscoreNamingConvention();
            DestinationMemberNamingConvention = new PascalCaseNamingConvention();
            CreateMap<TrueVaultResponseDto, TrueVaultResponse>();
            CreateMap<InnerErrorDto, InnerError>();
            CreateMap<ErrorResponseDto, ErrorResponse>();
            #region JSON Store
            CreateMap<DocumentSaveSuccessResponseDto, DocumentSaveSuccessResponse>();
            CreateMap<DocumentGetResponseDto, DocumentResponse>();
            CreateMap<MultiDocumentGetResponseDto, MultiDocumentResponse>();
            CreateMap<DocumentGetListResponseDto, DocumentGetListResponse>();
            CreateMap<DocumentGetListDataDto, DocumentGetListData>();
            CreateMap<DocumentGetListItemDto, DocumentGetListItem>();
            #endregion

            CreateMap<SchemaFieldDto, SchemaField>();
            //CreateMap<SchemaDto, Schema>();
            //CreateMap<SchemaGetResponseDto, SchemaGetResponse>();
            //CreateMap<SchemaGetListResponseDto, SchemaGetListResponse>();
            //CreateMap<SchemaSaveResponseDto, SchemaSaveResponse>();
            //CreateMap<SchemaSaveSuccessResponseDto, SchemaSaveSuccessResponse>();
        }
Exemplo n.º 7
0
 protected override void Configure()
 {
     base.Configure();
     SourceMemberNamingConvention = new LowerUnderscoreNamingConvention();
     DestinationMemberNamingConvention = new PascalCaseNamingConvention();
 }
 public NameSplitMember()
 {
     SourceMemberNamingConvention      = new PascalCaseNamingConvention();
     DestinationMemberNamingConvention = new PascalCaseNamingConvention();
 }