Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / xsp / System / Web / UI / WebParts / WebPartUserCapability.cs / 1 / WebPartUserCapability.cs
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.Web.UI.WebControls.WebParts {
using System;
using System.Security.Permissions;
using System.Web.Util;
///
///
[AspNetHostingPermission(SecurityAction.LinkDemand, Level = AspNetHostingPermissionLevel.Minimal)]
public sealed class WebPartUserCapability {
private string _name;
///
///
public WebPartUserCapability(string name) {
if (String.IsNullOrEmpty(name)) {
throw ExceptionUtil.ParameterNullOrEmpty("name");
}
_name = name;
}
///
///
public string Name {
get {
return _name;
}
}
///
///
public override bool Equals(object o) {
if (o == this) {
return true;
}
WebPartUserCapability other = o as WebPartUserCapability;
return (other != null) && (other.Name == Name);
}
///
///
public override int GetHashCode() {
return _name.GetHashCode();
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.Web.UI.WebControls.WebParts {
using System;
using System.Security.Permissions;
using System.Web.Util;
///
///
[AspNetHostingPermission(SecurityAction.LinkDemand, Level = AspNetHostingPermissionLevel.Minimal)]
public sealed class WebPartUserCapability {
private string _name;
///
///
public WebPartUserCapability(string name) {
if (String.IsNullOrEmpty(name)) {
throw ExceptionUtil.ParameterNullOrEmpty("name");
}
_name = name;
}
///
///
public string Name {
get {
return _name;
}
}
///
///
public override bool Equals(object o) {
if (o == this) {
return true;
}
WebPartUserCapability other = o as WebPartUserCapability;
return (other != null) && (other.Name == Name);
}
///
///
public override int GetHashCode() {
return _name.GetHashCode();
}
}
}
// 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
- DirectoryNotFoundException.cs
- ModulesEntry.cs
- NoneExcludedImageIndexConverter.cs
- Journal.cs
- BigIntegerStorage.cs
- BufferedReadStream.cs
- HostProtectionException.cs
- SafeMILHandle.cs
- ApplicationServiceHelper.cs
- MergablePropertyAttribute.cs
- SHA512Managed.cs
- TabletDevice.cs
- ChangeToolStripParentVerb.cs
- Registry.cs
- XmlSchemaGroup.cs
- LogicalExpressionTypeConverter.cs
- EnvelopedSignatureTransform.cs
- TableCell.cs
- ShortcutKeysEditor.cs
- LockCookie.cs
- WmlPageAdapter.cs
- ListView.cs
- FontClient.cs
- ProfileSection.cs
- EncodingStreamWrapper.cs
- CommunicationException.cs
- PrefixQName.cs
- ActivityDesignerLayoutSerializers.cs
- XmlReaderDelegator.cs
- TransformerInfoCollection.cs
- TemplateControlBuildProvider.cs
- XmlMembersMapping.cs
- SortDescriptionCollection.cs
- Vector3DAnimationBase.cs
- ConsoleKeyInfo.cs
- TabletDevice.cs
- Misc.cs
- Compiler.cs
- FastEncoder.cs
- WmpBitmapEncoder.cs
- mactripleDES.cs
- TextMarkerSource.cs
- LinkAreaEditor.cs
- AttributeCallbackBuilder.cs
- CharKeyFrameCollection.cs
- InkCanvasSelectionAdorner.cs
- CachedFontFamily.cs
- TransformationRules.cs
- SchemaCollectionPreprocessor.cs
- MouseActionValueSerializer.cs
- TypeBuilderInstantiation.cs
- AlternationConverter.cs
- Metadata.cs
- FilteredDataSetHelper.cs
- UserPersonalizationStateInfo.cs
- MenuCommandsChangedEventArgs.cs
- ObjectListComponentEditor.cs
- PointCollection.cs
- DmlSqlGenerator.cs
- IpcChannel.cs
- Padding.cs
- TextTreeUndoUnit.cs
- GridEntryCollection.cs
- ExecutionEngineException.cs
- WebConfigurationFileMap.cs
- SHA384CryptoServiceProvider.cs
- ButtonAutomationPeer.cs
- FormatterConverter.cs
- WebPartDisplayModeCollection.cs
- HtmlFormWrapper.cs
- ConnectionManagementSection.cs
- AnnotationComponentChooser.cs
- SoapFaultCodes.cs
- IncrementalReadDecoders.cs
- Stack.cs
- RepeaterItemEventArgs.cs
- XmlAnyElementAttribute.cs
- TextEditorContextMenu.cs
- ScrollableControl.cs
- Method.cs
- LineProperties.cs
- FileController.cs
- ValidationHelper.cs
- Error.cs
- DataControlExtensions.cs
- UseAttributeSetsAction.cs
- ExplicitDiscriminatorMap.cs
- DrawItemEvent.cs
- MediaTimeline.cs
- WebPartCloseVerb.cs
- LineVisual.cs
- RowsCopiedEventArgs.cs
- AbandonedMutexException.cs
- SplineKeyFrames.cs
- EntityClientCacheEntry.cs
- securitycriticaldataformultiplegetandset.cs
- WorkflowViewStateService.cs
- MetadataItemEmitter.cs
- EndPoint.cs
- GlobalizationAssembly.cs