You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 line
12 KiB
JavaScript
1 line
12 KiB
JavaScript
1 year ago
|
"use strict";(self.webpackChunkfurion=self.webpackChunkfurion||[]).push([[3201],{8231:(e,n,r)=>{r.r(n),r.d(n,{assets:()=>o,contentTitle:()=>d,default:()=>p,frontMatter:()=>i,metadata:()=>c,toc:()=>a});var t=r(5893),s=r(1151);const i={id:"object-mapper",title:"13. \u5bf9\u8c61\u6570\u636e\u6620\u5c04",sidebar_label:"13. \u5bf9\u8c61\u6570\u636e\u6620\u5c04 (Mapper)"},d=void 0,c={id:"object-mapper",title:"13. \u5bf9\u8c61\u6570\u636e\u6620\u5c04",description:"Furion \u6846\u67b6\u63d0\u4f9b\u4e86 Mapster \u7684\u62d3\u5c55 Furion.Extras.ObjectMapper.Mapster\uff0c\u5982\u9700\u4f7f\u7528\u7b2c\u4e09\u65b9\u5982 AutoMapper \u5219\u65e0\u9700\u5b89\u88c5\u6b64\u62d3\u5c55\u3002",source:"@site/docs/object-mapper.mdx",sourceDirName:".",slug:"/object-mapper",permalink:"/docs/object-mapper",draft:!1,unlisted:!1,editUrl:"https://gitee.com/dotnetchina/Furion/tree/v4/handbook/docs/object-mapper.mdx",tags:[],version:"current",lastUpdatedBy:"\u767e\u5c0f\u50e7",lastUpdatedAt:1695741411,formattedLastUpdatedAt:"Sep 26, 2023",frontMatter:{id:"object-mapper",title:"13. \u5bf9\u8c61\u6570\u636e\u6620\u5c04",sidebar_label:"13. \u5bf9\u8c61\u6570\u636e\u6620\u5c04 (Mapper)"},sidebar:"docs",previous:{title:"12. \u4f9d\u8d56\u6ce8\u5165/\u63a7\u5236\u53cd\u8f6c",permalink:"/docs/dependency-injection"},next:{title:"14. \u5206\u5e03\u5f0f\u7f13\u5b58",permalink:"/docs/cache"}},o={},a=[{value:"13.1 \u5bf9\u8c61\u6620\u5c04",id:"131-\u5bf9\u8c61\u6620\u5c04",level:2},{value:"13.2 \u5148\u770b\u4f8b\u5b50",id:"132-\u5148\u770b\u4f8b\u5b50",level:2},{value:"13.3 <code>Mapster</code> \u4f7f\u7528",id:"133-mapster-\u4f7f\u7528",level:2},{value:"13.3.1 \u5feb\u901f\u5165\u95e8",id:"1331-\u5feb\u901f\u5165\u95e8",level:3},{value:"13.3.2 \u81ea\u5b9a\u4e49\u6620\u5c04\u89c4\u5219",id:"1332-\u81ea\u5b9a\u4e49\u6620\u5c04\u89c4\u5219",level:3},{value:"13.3.3 \u4f9d\u8d56\u6ce8\u5165\u65b9\u5f0f",id:"1333-\u4f9d\u8d56\u6ce8\u5165\u65b9\u5f0f",level:3},{value:"13.3.4 \u548c <code>EFCore</code> \u914d\u5408",id:"1334-\u548c-efcore-\u914d\u5408",level:3},{value:"13.4 \u5168\u5c40\u9ed8\u8ba4\u914d\u7f6e",id:"134-\u5168\u5c40\u9ed8\u8ba4\u914d\u7f6e",level:2},{value:"13.5 \u53cd\u9988\u4e0e\u5efa\u8bae",id:"135-\u53cd\u9988\u4e0e\u5efa\u8bae",level:2}];function l(e){const n={a:"a",admonition:"admonition",code:"code",h2:"h2",h3:"h3",hr:"hr",mdxAdmonitionTitle:"mdxAdmonitionTitle",p:"p",pre:"pre",strong:"strong",...(0,s.a)(),...e.components};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(n.admonition,{type:"important",children:[(0,t.jsxs)(n.mdxAdmonitionTitle,{children:["\u4f7f\u7528 ",(0,t.jsx)(n.code,{children:"Mapster"})," \u4ee5\u5916\u7684\u62d3\u5c55\u8bf4\u660e"]}),(0,t.jsxs)(n.p,{children:[(0,t.jsx)(n.code,{children:"Furion"})," \u6846\u67b6\u63d0\u4f9b\u4e86 ",(0,t.jsx)(n.code,{children:"Mapster"})," \u7684\u62d3\u5c55 ",(0,t.jsx)(n.code,{children:"Furion.Extras.ObjectMapper.Mapster"}),"\uff0c\u5982\u9700\u4f7f\u7528\u7b2c\u4e09\u65b9\u5982 ",(0,t.jsx)(n.code,{children:"AutoMapper"})," \u5219\u65e0\u9700\u5b89\u88c5\u6b64\u62d3\u5c55\u3002"]})]}),"\n",(0,t.jsx)(n.h2,{id:"131-\u5bf9\u8c61\u6620\u5c04",children:"13.1 \u5bf9\u8c61\u6620\u5c04"}),"\n",(0,t.jsxs)(n.p,{children:["\u7b80\u5355\u6765\u8bf4\uff0c\u5c31\u662f\u5c06\u4e00\u4e2a\u5bf9\u8c61\u7684\u6570\u636e\u6839\u636e\u7279\u5b9a\u89c4\u5219\u6279\u91cf\u6620\u5c04\u5230\u53e6\u4e00\u4e2a\u5bf9\u8c61\u4e2d\uff0c\u51cf\u5c11\u624b\u5de5\u64cd\u4f5c\u548c\u964d\u4f4e\u4eba\u4e3a\u51fa\u9519\u7387\u3002\u5982\u5c06 ",(0,t.jsx)(n.code,{children:"DTO"})," \u5bf9\u8c61\u6620\u5c04\u5230 ",(0,t.jsx)(n.code,{children:"Entity"})," \u5b9e\u4f53\u4e2d\uff0c\u53cd\u4e4b\u4ea6\u7136\u3002"]}),"\n",(0,t.jsx)(n.h2,{id:"132-\u5148\u770b\u4f8b\u5b50",children:"13.2 \u5148\u770b\u4f8b\u5b50"}),"\n",(0,t.jsx)(n.p,{children:"\u5728\u8fc7\u53bb\uff0c\u6211\u4eec\u9700\u8981\u5c06\u4e00\u4e2a\u5bf9\u8c61\u7684\u503c\u8f6c\u6362\u5230\u53e6\u4e00\u4e2a\u5bf9\u8c61\u4e2d\uff0c\u6211\u4eec\u9700\u8981\u8fd9\u6837\u505a\uff0c\u5982\uff1a"}),"\n",(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-cs",metast
|