Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / WF / Activities / Rules / References.cs / 1305376 / References.cs
// ---------------------------------------------------------------------------- // Copyright (C) 2005 Microsoft Corporation All Rights Reserved // --------------------------------------------------------------------------- #define CODE_ANALYSIS using System.CodeDom; using System.Collections.Generic; using System.Diagnostics.CodeAnalysis; using System.Reflection; namespace System.Workflow.Activities.Rules { public class RulePathQualifier { private string name; private RulePathQualifier next; public RulePathQualifier(string name, RulePathQualifier next) { this.name = name; this.next = next; } public string Name { get { return name; } } public RulePathQualifier Next { get { return next; } } } public class RuleAnalysis { private RuleValidation validation; private bool forWrites; private Dictionarysymbols = new Dictionary (); public RuleAnalysis(RuleValidation validation, bool forWrites) { this.validation = validation; this.forWrites = forWrites; } internal RuleValidation Validation { get { return validation; } } public bool ForWrites { get { return forWrites; } } public void AddSymbol(string symbol) { symbols[symbol] = null; } [SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")] public ICollection GetSymbols() { List symbolList = new List (symbols.Keys.Count); foreach (KeyValuePair pair in symbols) symbolList.Add(pair.Key); return symbolList; } #region RuleAttribute Analysis internal void AnalyzeRuleAttributes(MemberInfo member, CodeExpression targetExpr, RulePathQualifier targetQualifier, CodeExpressionCollection argExprs, ParameterInfo[] parameters, List attributedExprs) { object[] attrs = member.GetCustomAttributes(typeof(RuleAttribute), true); if (attrs != null && attrs.Length > 0) { RuleAttribute[] ruleAttrs = (RuleAttribute[])attrs; for (int i = 0; i < ruleAttrs.Length; ++i) ruleAttrs[i].Analyze(this, member, targetExpr, targetQualifier, argExprs, parameters, attributedExprs); } } #endregion } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. // ---------------------------------------------------------------------------- // Copyright (C) 2005 Microsoft Corporation All Rights Reserved // --------------------------------------------------------------------------- #define CODE_ANALYSIS using System.CodeDom; using System.Collections.Generic; using System.Diagnostics.CodeAnalysis; using System.Reflection; namespace System.Workflow.Activities.Rules { public class RulePathQualifier { private string name; private RulePathQualifier next; public RulePathQualifier(string name, RulePathQualifier next) { this.name = name; this.next = next; } public string Name { get { return name; } } public RulePathQualifier Next { get { return next; } } } public class RuleAnalysis { private RuleValidation validation; private bool forWrites; private Dictionary symbols = new Dictionary (); public RuleAnalysis(RuleValidation validation, bool forWrites) { this.validation = validation; this.forWrites = forWrites; } internal RuleValidation Validation { get { return validation; } } public bool ForWrites { get { return forWrites; } } public void AddSymbol(string symbol) { symbols[symbol] = null; } [SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")] public ICollection GetSymbols() { List symbolList = new List (symbols.Keys.Count); foreach (KeyValuePair pair in symbols) symbolList.Add(pair.Key); return symbolList; } #region RuleAttribute Analysis internal void AnalyzeRuleAttributes(MemberInfo member, CodeExpression targetExpr, RulePathQualifier targetQualifier, CodeExpressionCollection argExprs, ParameterInfo[] parameters, List attributedExprs) { object[] attrs = member.GetCustomAttributes(typeof(RuleAttribute), true); if (attrs != null && attrs.Length > 0) { RuleAttribute[] ruleAttrs = (RuleAttribute[])attrs; for (int i = 0; i < ruleAttrs.Length; ++i) ruleAttrs[i].Analyze(this, member, targetExpr, targetQualifier, argExprs, parameters, attributedExprs); } } #endregion } } // 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
- XPathMultyIterator.cs
- XpsFilter.cs
- ToolBarButtonClickEvent.cs
- HelloOperationAsyncResult.cs
- GridPattern.cs
- InplaceBitmapMetadataWriter.cs
- RegexCaptureCollection.cs
- SmtpTransport.cs
- GridViewDeletedEventArgs.cs
- SafeProcessHandle.cs
- GridViewColumn.cs
- FixedPageProcessor.cs
- AsyncResult.cs
- HttpCookiesSection.cs
- EncoderReplacementFallback.cs
- PriorityQueue.cs
- OuterGlowBitmapEffect.cs
- Color.cs
- BlobPersonalizationState.cs
- ConsoleKeyInfo.cs
- AppSettingsExpressionBuilder.cs
- ComponentDispatcherThread.cs
- Stackframe.cs
- Error.cs
- TextCollapsingProperties.cs
- XmlDataFileEditor.cs
- RenderData.cs
- XmlImplementation.cs
- SafeNativeMethods.cs
- OptimizerPatterns.cs
- SqlServer2KCompatibilityCheck.cs
- ScriptingProfileServiceSection.cs
- UserControl.cs
- FunctionDescription.cs
- DoubleStorage.cs
- PropertyPathWorker.cs
- HandlerBase.cs
- EdmTypeAttribute.cs
- ProcessModelSection.cs
- UpdatePanelTriggerCollection.cs
- Keyboard.cs
- CompilerGeneratedAttribute.cs
- ZipIOExtraField.cs
- SpeakInfo.cs
- CheckoutException.cs
- CacheChildrenQuery.cs
- SafeProcessHandle.cs
- httpserverutility.cs
- SerializerProvider.cs
- LocalBuilder.cs
- RelatedCurrencyManager.cs
- CurrentChangedEventManager.cs
- TableAdapterManagerMethodGenerator.cs
- EntityObject.cs
- FormatVersion.cs
- Visitors.cs
- WebBrowserPermission.cs
- TripleDESCryptoServiceProvider.cs
- SerializerDescriptor.cs
- TakeQueryOptionExpression.cs
- LinkButton.cs
- HttpRuntime.cs
- ListViewTableCell.cs
- SyncOperationState.cs
- FastPropertyAccessor.cs
- GradientStop.cs
- GlobalEventManager.cs
- PathStreamGeometryContext.cs
- InputElement.cs
- SByteStorage.cs
- ComUdtElement.cs
- OverflowException.cs
- SharedUtils.cs
- MonthChangedEventArgs.cs
- TraceSource.cs
- DispatcherExceptionEventArgs.cs
- RowToFieldTransformer.cs
- propertyentry.cs
- DefaultAsyncDataDispatcher.cs
- __ConsoleStream.cs
- DictionaryItemsCollection.cs
- DocumentSequenceHighlightLayer.cs
- FileSystemWatcher.cs
- CellTreeNodeVisitors.cs
- LightweightCodeGenerator.cs
- LoadRetryConstantStrategy.cs
- XmlWellformedWriter.cs
- FormsAuthenticationCredentials.cs
- IndexedString.cs
- IMembershipProvider.cs
- OraclePermission.cs
- AutomationElement.cs
- TextBlockAutomationPeer.cs
- precedingquery.cs
- TypeDelegator.cs
- CompositeCollectionView.cs
- SignedXmlDebugLog.cs
- LinkUtilities.cs
- MenuItem.cs
- NumberSubstitution.cs