Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / DataWeb / Client / System / Data / Services / Client / ALinq / ProjectionQueryOptionExpression.cs / 1305376 / ProjectionQueryOptionExpression.cs
//----------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//
// Respresents a projection query option in resource bound expression tree.
//
//
// @owner [....]
//---------------------------------------------------------------------
namespace System.Data.Services.Client
{
#region Namespaces.
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq.Expressions;
#endregion Namespaces.
///
/// An resource specific expression representing a projection query option.
///
internal class ProjectionQueryOptionExpression : QueryOptionExpression
{
#region Private fields.
/// projection expression to evaluate on client on results from server to materialize type
private readonly LambdaExpression lambda;
/// projection paths to send to the server
private readonly List paths;
#endregion Private fields.
///
/// Creates a ProjectionQueryOption expression
///
/// the return type of the expression
/// projection expression
/// Projection paths for the query option
internal ProjectionQueryOptionExpression(Type type, LambdaExpression lambda, List paths)
: base((ExpressionType)ResourceExpressionType.ProjectionQueryOption, type)
{
Debug.Assert(type != null, "type != null");
Debug.Assert(lambda != null, "lambda != null");
Debug.Assert(paths != null, "paths != null");
this.lambda = lambda;
this.paths = paths;
}
#region Internal properties.
///
/// expression for the projection
///
internal LambdaExpression Selector
{
get
{
return this.lambda;
}
}
///
/// expression for the projection
///
internal List Paths
{
get
{
return this.paths;
}
}
#endregion Internal properties.
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
//----------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//
// Respresents a projection query option in resource bound expression tree.
//
//
// @owner [....]
//---------------------------------------------------------------------
namespace System.Data.Services.Client
{
#region Namespaces.
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq.Expressions;
#endregion Namespaces.
///
/// An resource specific expression representing a projection query option.
///
internal class ProjectionQueryOptionExpression : QueryOptionExpression
{
#region Private fields.
/// projection expression to evaluate on client on results from server to materialize type
private readonly LambdaExpression lambda;
/// projection paths to send to the server
private readonly List paths;
#endregion Private fields.
///
/// Creates a ProjectionQueryOption expression
///
/// the return type of the expression
/// projection expression
/// Projection paths for the query option
internal ProjectionQueryOptionExpression(Type type, LambdaExpression lambda, List paths)
: base((ExpressionType)ResourceExpressionType.ProjectionQueryOption, type)
{
Debug.Assert(type != null, "type != null");
Debug.Assert(lambda != null, "lambda != null");
Debug.Assert(paths != null, "paths != null");
this.lambda = lambda;
this.paths = paths;
}
#region Internal properties.
///
/// expression for the projection
///
internal LambdaExpression Selector
{
get
{
return this.lambda;
}
}
///
/// expression for the projection
///
internal List Paths
{
get
{
return this.paths;
}
}
#endregion Internal properties.
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- CountdownEvent.cs
- HostingEnvironment.cs
- OutputCacheSettingsSection.cs
- Int16Animation.cs
- DataRecordInfo.cs
- TraversalRequest.cs
- BitmapEffect.cs
- SmtpFailedRecipientsException.cs
- ArgumentOutOfRangeException.cs
- SelectedPathEditor.cs
- ChildTable.cs
- CompilationRelaxations.cs
- GroupQuery.cs
- PersonalizationStateInfoCollection.cs
- CursorInteropHelper.cs
- MimeTypePropertyAttribute.cs
- DataStorage.cs
- SqlDataSourceFilteringEventArgs.cs
- MenuItemStyleCollection.cs
- Error.cs
- ClaimComparer.cs
- SecureConversationServiceCredential.cs
- SqlProvider.cs
- XmlSchemaIdentityConstraint.cs
- SoapSchemaImporter.cs
- SoapSchemaImporter.cs
- UnmanagedMarshal.cs
- LinqDataSourceDeleteEventArgs.cs
- Storyboard.cs
- XmlAttributeCollection.cs
- GeneratedView.cs
- SizeAnimationClockResource.cs
- TableDetailsCollection.cs
- Timeline.cs
- UInt16.cs
- XamlTreeBuilder.cs
- Brush.cs
- MethodCallConverter.cs
- CodeNamespace.cs
- JsonXmlDataContract.cs
- PackageDigitalSignatureManager.cs
- SynchronousChannel.cs
- RtfControls.cs
- connectionpool.cs
- SizeFConverter.cs
- PixelFormats.cs
- SecurityState.cs
- FilterQuery.cs
- DateTimeUtil.cs
- IOException.cs
- TypedServiceOperationListItem.cs
- RegexTree.cs
- MetadataArtifactLoaderResource.cs
- DataGridViewAutoSizeColumnModeEventArgs.cs
- ZipArchive.cs
- AutoFocusStyle.xaml.cs
- DocumentCollection.cs
- Partitioner.cs
- ProxyAttribute.cs
- SudsCommon.cs
- TextEditorContextMenu.cs
- SqlMethods.cs
- HtmlSelect.cs
- StylusPointPropertyId.cs
- EntityDesignerDataSourceView.cs
- FormViewPagerRow.cs
- SystemTcpStatistics.cs
- ConstructorExpr.cs
- SourceFileBuildProvider.cs
- CacheAxisQuery.cs
- DocumentOrderQuery.cs
- EnvelopedPkcs7.cs
- TextTreeTextElementNode.cs
- LayoutTable.cs
- ImageMapEventArgs.cs
- FixedHyperLink.cs
- mediaclock.cs
- StreamGeometry.cs
- ConcurrentStack.cs
- TextProperties.cs
- SignatureHelper.cs
- SmiEventSink_Default.cs
- CompositeDuplexElement.cs
- ConnectionConsumerAttribute.cs
- LinkDesigner.cs
- RotateTransform3D.cs
- StringValidatorAttribute.cs
- Literal.cs
- BufferedMessageWriter.cs
- NotificationContext.cs
- MenuAutomationPeer.cs
- XmlSchemaAttribute.cs
- Psha1DerivedKeyGenerator.cs
- InfoCardRSAPKCS1KeyExchangeDeformatter.cs
- ExpressionHelper.cs
- CodeTryCatchFinallyStatement.cs
- FontInfo.cs
- MailSettingsSection.cs
- DataGridViewCellEventArgs.cs
- WebPartVerbCollection.cs