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
- XmlNodeChangedEventManager.cs
- ListViewAutomationPeer.cs
- UserInitiatedNavigationPermission.cs
- SortExpressionBuilder.cs
- HWStack.cs
- SecurityTokenAuthenticator.cs
- StateItem.cs
- TextEmbeddedObject.cs
- ProcessModelInfo.cs
- RequestCacheManager.cs
- ValidationService.cs
- DataControlImageButton.cs
- Itemizer.cs
- MessageCredentialType.cs
- ListBox.cs
- DataGridViewCellToolTipTextNeededEventArgs.cs
- CompositeScriptReference.cs
- AggregateNode.cs
- CodeArgumentReferenceExpression.cs
- RoutedCommand.cs
- TransactionProxy.cs
- CodeMethodReturnStatement.cs
- Char.cs
- KeyInterop.cs
- SqlFlattener.cs
- PrintDocument.cs
- GenerateTemporaryAssemblyTask.cs
- DetailsViewUpdateEventArgs.cs
- diagnosticsswitches.cs
- Configuration.cs
- AstNode.cs
- IApplicationTrustManager.cs
- WasEndpointConfigContainer.cs
- UIHelper.cs
- CodeAttributeArgumentCollection.cs
- OleDbSchemaGuid.cs
- MimeTextImporter.cs
- IISMapPath.cs
- ConfigurationException.cs
- WebPartExportVerb.cs
- CodeMethodMap.cs
- ZoneButton.cs
- BaseTransportHeaders.cs
- HttpChannelHelper.cs
- OpenFileDialog.cs
- DataObjectMethodAttribute.cs
- MenuTracker.cs
- MemberPathMap.cs
- PlacementWorkspace.cs
- SecureUICommand.cs
- HierarchicalDataBoundControl.cs
- ScriptServiceAttribute.cs
- PathSegmentCollection.cs
- Geometry.cs
- SafeMILHandle.cs
- NetworkCredential.cs
- TraceProvider.cs
- RectValueSerializer.cs
- BitmapEffectOutputConnector.cs
- EditorPartChrome.cs
- RegexParser.cs
- EventHandlerList.cs
- SetStoryboardSpeedRatio.cs
- Trustee.cs
- DesignerFrame.cs
- EntityTransaction.cs
- AsyncCompletedEventArgs.cs
- returneventsaver.cs
- WebPartTracker.cs
- NativeMethods.cs
- WebPartUtil.cs
- ExceptionUtil.cs
- AdapterDictionary.cs
- ComponentDispatcherThread.cs
- Transaction.cs
- GeometryDrawing.cs
- CancelAsyncOperationRequest.cs
- SchemaElementDecl.cs
- XXXInfos.cs
- SupportsEventValidationAttribute.cs
- PartialList.cs
- sqlpipe.cs
- AddingNewEventArgs.cs
- CompositionTarget.cs
- PauseStoryboard.cs
- ReverseInheritProperty.cs
- StateMachineHelpers.cs
- PagedDataSource.cs
- IdentifierCollection.cs
- XhtmlBasicPhoneCallAdapter.cs
- assertwrapper.cs
- PropertyChangedEventArgs.cs
- MetadataItemSerializer.cs
- WebPartPersonalization.cs
- HitTestParameters.cs
- WebControlsSection.cs
- ChtmlLinkAdapter.cs
- InstanceCreationEditor.cs
- SafeThemeHandle.cs
- StylusEventArgs.cs