示例#1
0
        public void StringShouldBeConstructed()
        {
            var builder  = new EdmPropertyBuilder();
            var property = builder.Build <string>("Name");

            property.Should().NotBeNull();
            property.Name.Should().Be("Name");
            property.PrimitiveType.Should().Be(PrimitiveType.GetEdmPrimitiveType(PrimitiveTypeKind.String));
        }
示例#2
0
        public void Int32ShouldBeConstructed()
        {
            var builder  = new EdmPropertyBuilder();
            var property = builder.Build <int>("ID");

            property.Should().NotBeNull();
            property.Name.Should().Be("ID");
            property.PrimitiveType.Should().Be(PrimitiveType.GetEdmPrimitiveType(PrimitiveTypeKind.Int32));
        }
示例#3
0
        public EntityTypeBuilder()
        {
            this.dataSpace        = DataSpace.CSpace;
            this.builder          = new EdmPropertyBuilder();
            this.typeUsageFactory = new TypeUsageFactory();

            this.keyMemberNames     = new List <string>();
            this.edmProperties      = new List <EdmProperty>();
            this.metadataProperties = new List <MetadataProperty>();
        }