Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / ndp / fx / src / DataEntity / System / Data / Common / EntitySql / Expr.cs / 2 / Expr.cs
//---------------------------------------------------------------------- //// Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backup [....] //--------------------------------------------------------------------- namespace System.Data.Common.EntitySql { using System; using System.Globalization; using System.Collections; using System.Collections.Generic; enum AstExprKind { Generic, Query, Insert, Update, Delete } ////// Represents the base type of all Expression Nodes /// internal abstract class Expr : AstNode { internal Expr() : base() { } internal Expr( string query, int inputPos ) : base(query, inputPos) { } internal virtual AstExprKind ExprKind { get { return AstExprKind.Generic; } } } ////// Represents generic list of expressions. /// ///expression type internal sealed class ExprList: Expr, System.Collections.Generic.IEnumerable { private List _exprList = new List (); /// /// default constructor /// internal ExprList() { } ////// initializes adding one item to the list. /// /// expression internal ExprList( T item ) { _exprList.Add(item); } ////// add an expression to the expression list. /// /// Expression ///Updated ExpressionList internal ExprListAdd( T item ) { _exprList.Add(item); return this; } /// /// Returns the list of expressions /// internal ListExpressions { get { return _exprList; } } #if __WHEN_NEEDED__ /// /// Verifies if list elements if of specified type. /// /// instance of a given type ///true if is the same type, false otherwise internal bool IsListOf( object o ) { return o.GetType().Equals( typeof( T ) ); } #endif ////// Returns the number of elements in the list /// internal int Count { get { return _exprList.Count; } } ////// Indexer to the list entries. /// /// integer position of the element in the list ///Expression internal T this[int index] { get { return _exprList[index]; } } #region GetEnumerator System.Collections.Generic.IEnumeratorSystem.Collections.Generic.IEnumerable .GetEnumerator() { return _exprList.GetEnumerator(); } System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { return _exprList.GetEnumerator(); } #endregion } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //---------------------------------------------------------------------- // // Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backup [....] //--------------------------------------------------------------------- namespace System.Data.Common.EntitySql { using System; using System.Globalization; using System.Collections; using System.Collections.Generic; enum AstExprKind { Generic, Query, Insert, Update, Delete } ////// Represents the base type of all Expression Nodes /// internal abstract class Expr : AstNode { internal Expr() : base() { } internal Expr( string query, int inputPos ) : base(query, inputPos) { } internal virtual AstExprKind ExprKind { get { return AstExprKind.Generic; } } } ////// Represents generic list of expressions. /// ///expression type internal sealed class ExprList: Expr, System.Collections.Generic.IEnumerable { private List _exprList = new List (); /// /// default constructor /// internal ExprList() { } ////// initializes adding one item to the list. /// /// expression internal ExprList( T item ) { _exprList.Add(item); } ////// add an expression to the expression list. /// /// Expression ///Updated ExpressionList internal ExprListAdd( T item ) { _exprList.Add(item); return this; } /// /// Returns the list of expressions /// internal ListExpressions { get { return _exprList; } } #if __WHEN_NEEDED__ /// /// Verifies if list elements if of specified type. /// /// instance of a given type ///true if is the same type, false otherwise internal bool IsListOf( object o ) { return o.GetType().Equals( typeof( T ) ); } #endif ////// Returns the number of elements in the list /// internal int Count { get { return _exprList.Count; } } ////// Indexer to the list entries. /// /// integer position of the element in the list ///Expression internal T this[int index] { get { return _exprList[index]; } } #region GetEnumerator System.Collections.Generic.IEnumeratorSystem.Collections.Generic.IEnumerable .GetEnumerator() { return _exprList.GetEnumerator(); } System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { return _exprList.GetEnumerator(); } #endregion } } // 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
- XsdSchemaFileEditor.cs
- PreviousTrackingServiceAttribute.cs
- CodeDomLocalizationProvider.cs
- ValueChangedEventManager.cs
- CompiledQuery.cs
- StatusBarDrawItemEvent.cs
- AssemblyHash.cs
- ByteFacetDescriptionElement.cs
- DesignTimeVisibleAttribute.cs
- VectorCollection.cs
- OrderByBuilder.cs
- EmptyControlCollection.cs
- StandardOleMarshalObject.cs
- StylusPointProperties.cs
- GroupQuery.cs
- VisualBrush.cs
- MorphHelper.cs
- IndependentlyAnimatedPropertyMetadata.cs
- SelectionItemProviderWrapper.cs
- ThreadWorkerController.cs
- IndexingContentUnit.cs
- JsonFormatWriterGenerator.cs
- OneOfScalarConst.cs
- oledbconnectionstring.cs
- ApplicationSecurityInfo.cs
- ColorDialog.cs
- Thread.cs
- ButtonBase.cs
- ProjectionCamera.cs
- EntityParameterCollection.cs
- MetadataItem.cs
- PassportIdentity.cs
- ClientUtils.cs
- _OSSOCK.cs
- CounterNameConverter.cs
- IIS7UserPrincipal.cs
- WindowsTooltip.cs
- UnsafeNativeMethodsCLR.cs
- PropertyMapper.cs
- AccessorTable.cs
- MailAddress.cs
- ProcessModelInfo.cs
- DrawingGroupDrawingContext.cs
- SimpleType.cs
- WindowsFormsHost.cs
- LayoutManager.cs
- SoapReflectionImporter.cs
- UnionExpr.cs
- UnsafeNativeMethodsMilCoreApi.cs
- RegexWriter.cs
- PartBasedPackageProperties.cs
- DesignSurfaceCollection.cs
- DataGridViewHeaderCell.cs
- ExtendedPropertyCollection.cs
- OleDbFactory.cs
- ProxyWebPartManagerDesigner.cs
- ToolStripArrowRenderEventArgs.cs
- TemplateControlBuildProvider.cs
- Match.cs
- XPathNavigator.cs
- DbParameterCollection.cs
- SafePEFileHandle.cs
- FrameworkElement.cs
- DataGridViewCell.cs
- DataGridCaption.cs
- PropertyGridEditorPart.cs
- DatatypeImplementation.cs
- WebConfigurationFileMap.cs
- TypeInformation.cs
- PartialTrustVisibleAssembliesSection.cs
- GridView.cs
- RectKeyFrameCollection.cs
- OdbcStatementHandle.cs
- WinEventWrap.cs
- IconHelper.cs
- SqlInfoMessageEvent.cs
- ListViewCommandEventArgs.cs
- BindValidator.cs
- Button.cs
- RegexReplacement.cs
- hresults.cs
- OracleTransaction.cs
- NamespaceEmitter.cs
- RijndaelManagedTransform.cs
- ObjectTokenCategory.cs
- ArraySet.cs
- Validator.cs
- DefaultPropertyAttribute.cs
- JoinTreeSlot.cs
- EnumMemberAttribute.cs
- EnumerableWrapperWeakToStrong.cs
- XmlTypeAttribute.cs
- ScrollChrome.cs
- Schema.cs
- ConfigurationManagerInternal.cs
- EventProxy.cs
- VarRefManager.cs
- BrowserInteropHelper.cs
- CommandLibraryHelper.cs
- TableFieldsEditor.cs