Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / NetFx40 / Tools / System.Activities.Presentation / System / Activities / Presentation / Base / Documents / ViewManagerAttribute.cs / 1305376 / ViewManagerAttribute.cs
namespace System.Activities.Presentation.Documents { using System.Activities.Presentation; using System.Activities.Presentation.Internal.Properties; using System; using System.Globalization; ////// This attribute can be placed on the root of a model /// object graph to specify what view manager should be /// used to present the view. /// [AttributeUsage(AttributeTargets.Class, Inherited=true, AllowMultiple=false)] sealed class ViewManagerAttribute : Attribute { private Type _viewManagerType; ////// An empty ViewManagerAttribute allows you to "unset" the view manager from a base class. /// public ViewManagerAttribute() { } ////// Creates a new ViewManager attribute. /// /// The type of view manager to use. The type specified must derive from ViewManager. ///If viewManagerType is null. ///If viewManagerType does not specify a type that derives from ViewManager. public ViewManagerAttribute(Type viewManagerType) { if (viewManagerType == null) throw FxTrace.Exception.ArgumentNull("viewManagerType"); if (!typeof(ViewManager).IsAssignableFrom(viewManagerType)) { throw FxTrace.Exception.AsError(new ArgumentException(string.Format(CultureInfo.CurrentCulture, Resources.Error_InvalidArgumentType, "viewManagerType", typeof(ViewManager).FullName))); } _viewManagerType = viewManagerType; } ////// The type of view manager to create for the model. /// public Type ViewManagerType { get { return _viewManagerType; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. namespace System.Activities.Presentation.Documents { using System.Activities.Presentation; using System.Activities.Presentation.Internal.Properties; using System; using System.Globalization; ////// This attribute can be placed on the root of a model /// object graph to specify what view manager should be /// used to present the view. /// [AttributeUsage(AttributeTargets.Class, Inherited=true, AllowMultiple=false)] sealed class ViewManagerAttribute : Attribute { private Type _viewManagerType; ////// An empty ViewManagerAttribute allows you to "unset" the view manager from a base class. /// public ViewManagerAttribute() { } ////// Creates a new ViewManager attribute. /// /// The type of view manager to use. The type specified must derive from ViewManager. ///If viewManagerType is null. ///If viewManagerType does not specify a type that derives from ViewManager. public ViewManagerAttribute(Type viewManagerType) { if (viewManagerType == null) throw FxTrace.Exception.ArgumentNull("viewManagerType"); if (!typeof(ViewManager).IsAssignableFrom(viewManagerType)) { throw FxTrace.Exception.AsError(new ArgumentException(string.Format(CultureInfo.CurrentCulture, Resources.Error_InvalidArgumentType, "viewManagerType", typeof(ViewManager).FullName))); } _viewManagerType = viewManagerType; } ////// The type of view manager to create for the model. /// public Type ViewManagerType { get { return _viewManagerType; } } } } // 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
- XmlNodeComparer.cs
- HttpRawResponse.cs
- AndCondition.cs
- XmlQueryCardinality.cs
- httpapplicationstate.cs
- IdentityReference.cs
- ProcessProtocolHandler.cs
- ColorMatrix.cs
- DataTemplateSelector.cs
- ByteConverter.cs
- TraversalRequest.cs
- EventlogProvider.cs
- XmlSchemaIdentityConstraint.cs
- PopupEventArgs.cs
- IntSecurity.cs
- TiffBitmapEncoder.cs
- SystemNetHelpers.cs
- ListParagraph.cs
- XmlBinaryReader.cs
- wmiutil.cs
- RelationshipEndCollection.cs
- CookielessHelper.cs
- CodeDelegateCreateExpression.cs
- LayoutTableCell.cs
- Graphics.cs
- NamespaceQuery.cs
- ClockGroup.cs
- InvalidDataException.cs
- ListBindingConverter.cs
- XmlToDatasetMap.cs
- BaseCodeDomTreeGenerator.cs
- DataGridViewEditingControlShowingEventArgs.cs
- NativeMethods.cs
- StoryFragments.cs
- PageSetupDialog.cs
- ScriptReferenceEventArgs.cs
- GridToolTip.cs
- SessionSwitchEventArgs.cs
- SerializationEventsCache.cs
- NameTable.cs
- HostProtectionException.cs
- ConfigurationStrings.cs
- ModuleConfigurationInfo.cs
- PageBuildProvider.cs
- WorkflowDurableInstance.cs
- _CacheStreams.cs
- CodeNamespace.cs
- MatchAllMessageFilter.cs
- RuleSetBrowserDialog.cs
- PersonalizationStateInfo.cs
- HitTestResult.cs
- SafeReadContext.cs
- HelloOperation11AsyncResult.cs
- RC2.cs
- SpecialNameAttribute.cs
- HMACSHA256.cs
- CultureTableRecord.cs
- Compensate.cs
- MouseCaptureWithinProperty.cs
- EventRouteFactory.cs
- NestPullup.cs
- Win32MouseDevice.cs
- SimpleWebHandlerParser.cs
- ReadOnlyMetadataCollection.cs
- EntityKey.cs
- Ppl.cs
- BaseDataBoundControlDesigner.cs
- DecoderFallback.cs
- DataSet.cs
- Size3D.cs
- UnmanagedMemoryStream.cs
- StylusDevice.cs
- LocalValueEnumerator.cs
- AssociationType.cs
- BindingListCollectionView.cs
- SmiEventStream.cs
- FlowLayoutSettings.cs
- PixelFormat.cs
- ContractBase.cs
- DashStyle.cs
- Faults.cs
- PassportIdentity.cs
- SafeCryptoHandles.cs
- XpsS0ValidatingLoader.cs
- XmlILIndex.cs
- Attribute.cs
- GenericTypeParameterConverter.cs
- TextRenderer.cs
- BrowserCapabilitiesFactoryBase.cs
- PersonalizationProviderCollection.cs
- OleDbReferenceCollection.cs
- DataSourceControlBuilder.cs
- COAUTHINFO.cs
- XmlUTF8TextReader.cs
- EastAsianLunisolarCalendar.cs
- MenuCommandService.cs
- PrintDialogException.cs
- PerspectiveCamera.cs
- CodeAttachEventStatement.cs
- EasingFunctionBase.cs