Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / xsp / System / Web / UI / ControlBuilderAttribute.cs / 1305376 / ControlBuilderAttribute.cs
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
/*
*/
namespace System.Web.UI {
using System;
using System.ComponentModel;
using System.Security.Permissions;
///
/// Allows a control to specify a custom object
/// for building that control within the ASP.NET parser.
///
[AttributeUsage(AttributeTargets.Class)]
public sealed class ControlBuilderAttribute : Attribute {
///
///
/// The default object is a
/// builder. This field is read-only.
///
public static readonly ControlBuilderAttribute Default = new ControlBuilderAttribute(null);
private Type builderType = null;
///
///
public ControlBuilderAttribute(Type builderType) {
this.builderType = builderType;
}
///
/// Indicates XXX. This property is read-only.
///
public Type BuilderType {
get {
return builderType;
}
}
///
///
/// [To be supplied.]
///
public override int GetHashCode() {
return ((BuilderType != null) ? BuilderType.GetHashCode() : 0);
}
///
///
///
public override bool Equals(object obj) {
if (obj == this) {
return true;
}
if ((obj != null) && (obj is ControlBuilderAttribute)) {
return((ControlBuilderAttribute)obj).BuilderType == builderType;
}
return false;
}
///
///
///
public override bool IsDefaultAttribute() {
return this.Equals(Default);
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
/*
*/
namespace System.Web.UI {
using System;
using System.ComponentModel;
using System.Security.Permissions;
///
/// Allows a control to specify a custom object
/// for building that control within the ASP.NET parser.
///
[AttributeUsage(AttributeTargets.Class)]
public sealed class ControlBuilderAttribute : Attribute {
///
///
/// The default object is a
/// builder. This field is read-only.
///
public static readonly ControlBuilderAttribute Default = new ControlBuilderAttribute(null);
private Type builderType = null;
///
///
public ControlBuilderAttribute(Type builderType) {
this.builderType = builderType;
}
///
/// Indicates XXX. This property is read-only.
///
public Type BuilderType {
get {
return builderType;
}
}
///
///
/// [To be supplied.]
///
public override int GetHashCode() {
return ((BuilderType != null) ? BuilderType.GetHashCode() : 0);
}
///
///
///
public override bool Equals(object obj) {
if (obj == this) {
return true;
}
if ((obj != null) && (obj is ControlBuilderAttribute)) {
return((ControlBuilderAttribute)obj).BuilderType == builderType;
}
return false;
}
///
///
///
public override bool IsDefaultAttribute() {
return this.Equals(Default);
}
}
}
// 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
- tabpagecollectioneditor.cs
- InstanceLockQueryResult.cs
- InputManager.cs
- EncryptedData.cs
- SmtpException.cs
- FixedSOMSemanticBox.cs
- WebMessageBodyStyleHelper.cs
- AddressingProperty.cs
- CodeTryCatchFinallyStatement.cs
- xml.cs
- ParentUndoUnit.cs
- SqlCharStream.cs
- COM2FontConverter.cs
- ExecutionEngineException.cs
- MimeFormatter.cs
- WebBrowserSiteBase.cs
- XPathMultyIterator.cs
- SaveFileDialog.cs
- BaseHashHelper.cs
- XmlTextReaderImplHelpers.cs
- EmptyStringExpandableObjectConverter.cs
- PanelContainerDesigner.cs
- TimeSpan.cs
- WebPartConnectionsConfigureVerb.cs
- ParserOptions.cs
- Filter.cs
- PrintingPermissionAttribute.cs
- MouseEvent.cs
- FileLevelControlBuilderAttribute.cs
- SqlGenerator.cs
- MatrixTransform.cs
- SizeAnimationBase.cs
- PerSessionInstanceContextProvider.cs
- DataBindingCollection.cs
- StickyNoteAnnotations.cs
- RotateTransform3D.cs
- COMException.cs
- ThrowHelper.cs
- DatatypeImplementation.cs
- Queue.cs
- HasRunnableWorkflowEvent.cs
- InputElement.cs
- XXXOnTypeBuilderInstantiation.cs
- Options.cs
- ClassicBorderDecorator.cs
- FusionWrap.cs
- Size3D.cs
- XmlObjectSerializer.cs
- SelectionProcessor.cs
- UpdateTranslator.cs
- ConsumerConnectionPoint.cs
- ExpressionPrinter.cs
- UrlPath.cs
- EraserBehavior.cs
- ToolStripContentPanelDesigner.cs
- PriorityBindingExpression.cs
- DependencyObjectPropertyDescriptor.cs
- D3DImage.cs
- XmlEntity.cs
- AppliedDeviceFiltersEditor.cs
- __Filters.cs
- MetadataArtifactLoaderXmlReaderWrapper.cs
- DictionaryTraceRecord.cs
- RemotingConfiguration.cs
- AttributeQuery.cs
- sqlnorm.cs
- mda.cs
- EmptyReadOnlyDictionaryInternal.cs
- EmbeddedMailObjectsCollection.cs
- configsystem.cs
- LocalValueEnumerator.cs
- FontUnit.cs
- TextMarkerSource.cs
- ChangesetResponse.cs
- NonPrimarySelectionGlyph.cs
- ContainerFilterService.cs
- Vector3DAnimationUsingKeyFrames.cs
- Quad.cs
- XPathParser.cs
- XmlSchemaExternal.cs
- QilPatternFactory.cs
- LeaseManager.cs
- ComEventsHelper.cs
- _ContextAwareResult.cs
- EndpointInfoCollection.cs
- LayoutDump.cs
- AccessedThroughPropertyAttribute.cs
- DrawingContextWalker.cs
- SmiRecordBuffer.cs
- ObjectListTitleAttribute.cs
- SetStoryboardSpeedRatio.cs
- Rectangle.cs
- ElapsedEventArgs.cs
- SystemFonts.cs
- DataRowChangeEvent.cs
- PlatformCulture.cs
- PagedDataSource.cs
- AddInToken.cs
- Parallel.cs
- CustomAttribute.cs