Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / ndp / fx / src / DataEntity / System / Data / Common / EntitySql / BuiltInExpr.cs / 1 / BuiltInExpr.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; ////// defines the function class of builtin expressions. /// internal enum BuiltInKind { And, Or, Not, Cast, OfType, Treat, IsOf, Union, UnionAll, Intersect, Overlaps, AnyElement, Element, Except, Exists, Flatten, In, NotIn, Distinct, IsNull, IsNotNull, Like, Equal, NotEqual, LessEqual, LessThan, GreaterThan, GreaterEqual, Plus, Minus, Multiply, Divide, Modulus, UnaryMinus, UnaryPlus, Between, NotBetween } ////// Represents a builtin ast expression node /// internal sealed class BuiltInExpr : Expr { private BuiltInKind _kind; private string _name; private ExprList_argList = new ExprList (); private BuiltInExpr( BuiltInKind kind, string name ) { _kind = kind; _name = name.ToUpperInvariant(); } internal BuiltInExpr( BuiltInKind kind, string name, Expr arg1 ) : this(kind, name) { _argList.Add(arg1); } internal BuiltInExpr( BuiltInKind kind, string name, Expr arg1, Expr arg2 ) : this(kind, name, arg1) { _argList.Add(arg2); } internal BuiltInExpr( BuiltInKind kind, string name, Expr arg1, Expr arg2, Expr arg3 ) : this(kind, name, arg1, arg2) { _argList.Add(arg3); } internal BuiltInExpr( BuiltInKind kind, string name, Expr arg1, Expr arg2, Expr arg3, Expr arg4 ) : this(kind, name, arg1, arg2, arg3) { _argList.Add(arg4); } internal BuiltInKind Kind { get { return _kind; } set { _kind = value; } } internal string Name { get { return _name; } } internal ExprList ArgList { get { return _argList; } } internal Expr Arg1 { get { if (_argList.Count < 1) { return null; } return _argList[0]; } } internal Expr Arg2 { get { if (_argList.Count < 2) return null; return _argList[1]; } } internal int ArgCount { get { return ArgList.Count; } } } } // 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; ////// defines the function class of builtin expressions. /// internal enum BuiltInKind { And, Or, Not, Cast, OfType, Treat, IsOf, Union, UnionAll, Intersect, Overlaps, AnyElement, Element, Except, Exists, Flatten, In, NotIn, Distinct, IsNull, IsNotNull, Like, Equal, NotEqual, LessEqual, LessThan, GreaterThan, GreaterEqual, Plus, Minus, Multiply, Divide, Modulus, UnaryMinus, UnaryPlus, Between, NotBetween } ////// Represents a builtin ast expression node /// internal sealed class BuiltInExpr : Expr { private BuiltInKind _kind; private string _name; private ExprList_argList = new ExprList (); private BuiltInExpr( BuiltInKind kind, string name ) { _kind = kind; _name = name.ToUpperInvariant(); } internal BuiltInExpr( BuiltInKind kind, string name, Expr arg1 ) : this(kind, name) { _argList.Add(arg1); } internal BuiltInExpr( BuiltInKind kind, string name, Expr arg1, Expr arg2 ) : this(kind, name, arg1) { _argList.Add(arg2); } internal BuiltInExpr( BuiltInKind kind, string name, Expr arg1, Expr arg2, Expr arg3 ) : this(kind, name, arg1, arg2) { _argList.Add(arg3); } internal BuiltInExpr( BuiltInKind kind, string name, Expr arg1, Expr arg2, Expr arg3, Expr arg4 ) : this(kind, name, arg1, arg2, arg3) { _argList.Add(arg4); } internal BuiltInKind Kind { get { return _kind; } set { _kind = value; } } internal string Name { get { return _name; } } internal ExprList ArgList { get { return _argList; } } internal Expr Arg1 { get { if (_argList.Count < 1) { return null; } return _argList[0]; } } internal Expr Arg2 { get { if (_argList.Count < 2) return null; return _argList[1]; } } internal int ArgCount { get { return ArgList.Count; } } } } // 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
- DataBindingValueUIHandler.cs
- SessionState.cs
- MailDefinition.cs
- LicenseProviderAttribute.cs
- TagMapCollection.cs
- PnrpPermission.cs
- Type.cs
- SocketStream.cs
- DateTimeParse.cs
- ExtensibleClassFactory.cs
- Thread.cs
- MinimizableAttributeTypeConverter.cs
- FixedBufferAttribute.cs
- Trustee.cs
- LinqDataSourceDisposeEventArgs.cs
- WebConfigurationHostFileChange.cs
- RootContext.cs
- RowTypePropertyElement.cs
- ExpressionBuilderCollection.cs
- Visual3DCollection.cs
- RequestCachePolicy.cs
- GraphicsPathIterator.cs
- BamlResourceDeserializer.cs
- ObjectItemCachedAssemblyLoader.cs
- Set.cs
- WebPermission.cs
- HttpStreamXmlDictionaryReader.cs
- CompilerGlobalScopeAttribute.cs
- CodeConstructor.cs
- PersistNameAttribute.cs
- ServiceObjectContainer.cs
- AssociatedControlConverter.cs
- ObjectCloneHelper.cs
- DesignerEventService.cs
- SystemThemeKey.cs
- FixedSOMElement.cs
- ResourcePart.cs
- TargetPerspective.cs
- StrokeRenderer.cs
- SignatureDescription.cs
- RemotingException.cs
- DocumentOrderComparer.cs
- ShutDownListener.cs
- XmlSerializerSection.cs
- Themes.cs
- GPRECTF.cs
- DebuggerAttributes.cs
- entityreference_tresulttype.cs
- Table.cs
- XmlSchemaSimpleContent.cs
- AccessibilityApplicationManager.cs
- MetadataItem_Static.cs
- DataFormats.cs
- SystemPens.cs
- AudioSignalProblemOccurredEventArgs.cs
- ActivationArguments.cs
- DesignOnlyAttribute.cs
- LifetimeServices.cs
- DataControlReferenceCollection.cs
- X509ServiceCertificateAuthenticationElement.cs
- SqlConnectionManager.cs
- DataRecordInternal.cs
- RuntimeCompatibilityAttribute.cs
- JoinGraph.cs
- SessionIDManager.cs
- SwitchLevelAttribute.cs
- OnOperation.cs
- StrokeNodeEnumerator.cs
- PasswordBoxAutomationPeer.cs
- HtmlTextArea.cs
- TrustLevel.cs
- BrowserTree.cs
- HotSpot.cs
- EntityAdapter.cs
- IPAddressCollection.cs
- ScriptingWebServicesSectionGroup.cs
- SqlDependencyUtils.cs
- SourceCollection.cs
- ArgumentsParser.cs
- SequenceDesigner.cs
- VirtualizedContainerService.cs
- RtfToXamlReader.cs
- XmlConvert.cs
- ConfigurationManagerInternalFactory.cs
- SqlGatherProducedAliases.cs
- CurrencyWrapper.cs
- ConfigurationSettings.cs
- BitmapEffectCollection.cs
- OrthographicCamera.cs
- CharacterBufferReference.cs
- ContentFilePart.cs
- Group.cs
- XsdDuration.cs
- KeyProperty.cs
- DbRetry.cs
- PathSegment.cs
- AncestorChangedEventArgs.cs
- EncodingNLS.cs
- SqlCommandSet.cs
- ComplexTypeEmitter.cs