Name 특성(EntityContainer CSDL)

EntityContainer 요소의 Name 특성은 EDM(엔터티 데이터 모델) 기반의 개체 모델에서 클래스 이름을 지정합니다. CSDL(개념 스키마 정의 언어)에서 EntityContainer에 할당된 Name은 매핑 사양에서 프로그래밍 가능 클래스를 저장소 구조에 매핑하는 데 사용됩니다. 개념 스키마를 저장소 메타데이터에 매핑하는 방법에 대한 자세한 내용은 EntityContainerMapping 요소(MSL)를 참조하십시오.

XML 계층 구조에서 EntityContainer가 스키마에 정의되었더라도 EntityContainer 요소는 Schema 요소와 별개입니다. 이 점은 EntityContainer를 저장소에 매핑할 때 중요합니다. 매핑 파일에서 EntityContainer의 이름에는 스키마 네임스페이스 이름이 포함되지 않습니다.

다음 코드 예제에서 Name은 여는 요소에 할당됩니다.

<EntityContainer Name="HumanResources">.

다음 스키마 예제에서는 Adventure Works CSDL 스키마 예제에 있는 EntityContainer를 보여 줍니다.

  <EntityContainer Name="HumanResources">
    <EntitySet Name="Department" EntityType="Self.Department" />
    <EntitySet Name="Employee" EntityType="Self.Employee" />
    <EntitySet Name="EmployeeAddress" EntityType="Self.EmployeeAddress" />
    <EntitySet Name="EmployeeDepartmentHistory"
                      EntityType="Self.EmployeeDepartmentHistory" />
    <EntitySet Name="EmployeePayHistory"
                        EntityType="Self.EmployeePayHistory" />
    <EntitySet Name="JobCandidate" EntityType="Self.JobCandidate" />
    <EntitySet Name="Shift" EntityType="Self.Shift" />
    <AssociationSet Name="Employee_Employee_ManagerID"
                     Association="Self.Employee_Employee_ManagerID">
      <End Role="Employee" EntitySet="Employee" />
      <End Role="EmployeeManager" EntitySet="Employee" />
    </AssociationSet>
    <AssociationSet Name="JobCandidate_Employee_EmployeeID"
                 Association="Self.JobCandidate_Employee_EmployeeID">
      <End Role="Employee" EntitySet="Employee" />
      <End Role="JobCandidate" EntitySet="JobCandidate" />
    </AssociationSet>
  </EntityContainer>

이 예제의 코드에 표시된 엔터티 집합 및 연결 집합에 대한 자세한 내용은 EntitySet 요소(EntityContainer CSDL)AssociationSet 요소(EntityContainer CSDL)를 참조하십시오.

참고 항목

개념

EntityContainer 요소(SSDL)
EntityContainerMapping 요소(MSL)
EntitySetMapping 요소(MSL)
엔터티 컨테이너(EDM)
AdventureWorks 전체 모델(EDM)