Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / Data / System / Data / Filter / ZeroOpNode.cs / 1 / ZeroOpNode.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //[....] //[....] //[....] //----------------------------------------------------------------------------- namespace System.Data { using System; using System.Collections.Generic; using System.Diagnostics; internal sealed class ZeroOpNode : ExpressionNode { internal readonly int op; internal const int zop_True = 1; internal const int zop_False = 0; internal const int zop_Null = -1; internal ZeroOpNode(int op) : base((DataTable)null) { this.op = op; Debug.Assert(op == Operators.True || op == Operators.False || op == Operators.Null, "Invalid zero-op"); } internal override void Bind(DataTable table, Listlist) { } internal override object Eval() { switch (op) { case Operators.True: return true; case Operators.False: return false; case Operators.Null: return DBNull.Value; default: Debug.Assert(op == Operators.True || op == Operators.False || op == Operators.Null, "Invalid zero-op"); return DBNull.Value; } } internal override object Eval(DataRow row, DataRowVersion version) { return Eval(); } internal override object Eval(int[] recordNos) { return Eval(); } internal override bool IsConstant() { return true; } internal override bool IsTableConstant() { return true; } internal override bool HasLocalAggregate() { return false; } internal override bool HasRemoteAggregate() { return false; } internal override ExpressionNode Optimize() { return this; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- ZoneButton.cs
- TimeoutException.cs
- MaskedTextBoxTextEditorDropDown.cs
- NativeMethods.cs
- ListViewGroupConverter.cs
- SQLBytesStorage.cs
- ClientProxyGenerator.cs
- UntrustedRecipientException.cs
- SimpleApplicationHost.cs
- Transactions.cs
- Transform3D.cs
- BasicHttpBindingElement.cs
- LocalFileSettingsProvider.cs
- BulletedList.cs
- SizeAnimationUsingKeyFrames.cs
- DataTableClearEvent.cs
- RequestStatusBarUpdateEventArgs.cs
- PreviewKeyDownEventArgs.cs
- SqlDataSourceSelectingEventArgs.cs
- WSDualHttpSecurity.cs
- StrokeIntersection.cs
- FontWeightConverter.cs
- SafeHandle.cs
- DbDataSourceEnumerator.cs
- ReaderOutput.cs
- UseManagedPresentationBindingElementImporter.cs
- ViewKeyConstraint.cs
- MatrixConverter.cs
- ModuleBuilderData.cs
- X509Extension.cs
- FormsAuthenticationTicket.cs
- CryptoApi.cs
- X509Chain.cs
- SqlClientPermission.cs
- ChangeTracker.cs
- IgnoreFlushAndCloseStream.cs
- TextRunCache.cs
- FakeModelPropertyImpl.cs
- GeneralTransform3DTo2DTo3D.cs
- ClickablePoint.cs
- FillErrorEventArgs.cs
- TypeUtil.cs
- Base64Encoder.cs
- CqlGenerator.cs
- ArrayConverter.cs
- IndentedWriter.cs
- XPathScanner.cs
- MessageQueueTransaction.cs
- DataGridBeginningEditEventArgs.cs
- SequentialUshortCollection.cs
- DataGridViewRowHeaderCell.cs
- SecurityRuntime.cs
- TextReader.cs
- DeclaredTypeElementCollection.cs
- OdbcDataReader.cs
- PersonalizationStateInfo.cs
- DocumentPageTextView.cs
- Subtract.cs
- LeaseManager.cs
- _RequestCacheProtocol.cs
- LicenseProviderAttribute.cs
- ResetableIterator.cs
- SqlRetyper.cs
- DataGridView.cs
- AutomationProperties.cs
- BindingSource.cs
- HwndAppCommandInputProvider.cs
- PropertyCondition.cs
- StrokeSerializer.cs
- HtmlInputImage.cs
- DocumentPage.cs
- HtmlInputSubmit.cs
- ToolStripOverflowButton.cs
- Registry.cs
- ProfileManager.cs
- sqlstateclientmanager.cs
- SqlDataSource.cs
- DocumentViewerHelper.cs
- ObjectNavigationPropertyMapping.cs
- StylusLogic.cs
- CatalogZone.cs
- HostSecurityManager.cs
- MetadataPropertyCollection.cs
- ExtendedPropertyDescriptor.cs
- TransactionManager.cs
- NumberAction.cs
- XmlReflectionMember.cs
- DataObjectAttribute.cs
- CodeDirectionExpression.cs
- Themes.cs
- ObjectDataSourceView.cs
- SkinBuilder.cs
- WebPartActionVerb.cs
- ApplicationException.cs
- Activator.cs
- ListViewHitTestInfo.cs
- ListViewItemMouseHoverEvent.cs
- NetworkCredential.cs
- WebResourceAttribute.cs
- NumericExpr.cs