mirror of
https://github.com/BepInEx/mono.git
synced 2026-11-19 01:31:17 -10:00
Adding reference source for System.Data System.Data.DataSetExtensions System.Data.Entity System.Data.Entity.Design System.Data.Linq System.Data.SqlXml System.ServiceModel System.ServiceModel.Activation System.ServiceModel.Activities System.ServiceModel.Channels System.ServiceModel.Discovery System.ServiceModel.Internals System.ServiceModel.Routing System.ServiceModel.WasHosting System.ServiceModel.Web System.Web System.Web.ApplicationServices System.Web.DynamicData System.Web.Entity System.Web.Entity.Design System.Web.Extensions System.Web.Mobile System.Web.Routing System.Web.Services System.Xml System.Xml.Linq
55 lines
1.5 KiB
C#
55 lines
1.5 KiB
C#
//---------------------------------------------------------------------
|
|
// <copyright file="EntityContainerEntitySetDefiningQuery.cs" company="Microsoft">
|
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
|
// </copyright>
|
|
//
|
|
// @owner [....]
|
|
// @backupOwner [....]
|
|
//---------------------------------------------------------------------
|
|
|
|
namespace System.Data.EntityModel.SchemaObjectModel
|
|
{
|
|
using System;
|
|
using System.Data.Metadata.Edm;
|
|
using System.Xml;
|
|
|
|
/// <summary>
|
|
/// Represents an DefiningQuery element.
|
|
/// </summary>
|
|
internal sealed class EntityContainerEntitySetDefiningQuery : SchemaElement
|
|
{
|
|
private string _query;
|
|
|
|
/// <summary>
|
|
/// Constructs an EntityContainerEntitySet
|
|
/// </summary>
|
|
/// <param name="parentElement">Reference to the schema element.</param>
|
|
public EntityContainerEntitySetDefiningQuery(EntityContainerEntitySet parentElement)
|
|
: base( parentElement )
|
|
{
|
|
}
|
|
|
|
public string Query
|
|
{
|
|
get { return _query; }
|
|
}
|
|
|
|
protected override bool HandleText(XmlReader reader)
|
|
{
|
|
_query = reader.Value;
|
|
return true;
|
|
}
|
|
|
|
internal override void Validate()
|
|
{
|
|
base.Validate();
|
|
|
|
if(String.IsNullOrEmpty(_query))
|
|
{
|
|
AddError(ErrorCode.EmptyDefiningQuery, EdmSchemaErrorSeverity.Error,
|
|
System.Data.Entity.Strings.EmptyDefiningQuery);
|
|
}
|
|
}
|
|
}
|
|
}
|