Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / whidbey / NetFXspW7 / ndp / fx / src / CompMod / System / CodeDOM / CodeTypeDelegate.cs / 1 / CodeTypeDelegate.cs
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.CodeDom {
using System.Diagnostics;
using System;
using Microsoft.Win32;
using System.Collections;
using System.Reflection;
using System.Runtime.InteropServices;
using System.Runtime.Serialization;
///
///
/// Represents a class or nested class.
///
///
[
ClassInterface(ClassInterfaceType.AutoDispatch),
ComVisible(true),
Serializable,
]
public class CodeTypeDelegate : CodeTypeDeclaration {
private CodeParameterDeclarationExpressionCollection parameters = new CodeParameterDeclarationExpressionCollection();
private CodeTypeReference returnType;
///
///
/// Initializes a new instance of .
///
///
public CodeTypeDelegate() {
TypeAttributes &= ~TypeAttributes.ClassSemanticsMask;
TypeAttributes |= TypeAttributes.Class;
BaseTypes.Clear();
BaseTypes.Add(new CodeTypeReference("System.Delegate"));
}
///
///
/// Initializes a new instance of .
///
///
public CodeTypeDelegate(string name) : this() {
Name = name;
}
///
///
/// Gets or sets the return type of the delegate.
///
///
public CodeTypeReference ReturnType {
get {
if (returnType == null) {
returnType = new CodeTypeReference("");
}
return returnType;
}
set {
returnType = value;
}
}
///
///
/// The parameters of the delegate.
///
///
public CodeParameterDeclarationExpressionCollection Parameters {
get {
return parameters;
}
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.CodeDom {
using System.Diagnostics;
using System;
using Microsoft.Win32;
using System.Collections;
using System.Reflection;
using System.Runtime.InteropServices;
using System.Runtime.Serialization;
///
///
/// Represents a class or nested class.
///
///
[
ClassInterface(ClassInterfaceType.AutoDispatch),
ComVisible(true),
Serializable,
]
public class CodeTypeDelegate : CodeTypeDeclaration {
private CodeParameterDeclarationExpressionCollection parameters = new CodeParameterDeclarationExpressionCollection();
private CodeTypeReference returnType;
///
///
/// Initializes a new instance of .
///
///
public CodeTypeDelegate() {
TypeAttributes &= ~TypeAttributes.ClassSemanticsMask;
TypeAttributes |= TypeAttributes.Class;
BaseTypes.Clear();
BaseTypes.Add(new CodeTypeReference("System.Delegate"));
}
///
///
/// Initializes a new instance of .
///
///
public CodeTypeDelegate(string name) : this() {
Name = name;
}
///
///
/// Gets or sets the return type of the delegate.
///
///
public CodeTypeReference ReturnType {
get {
if (returnType == null) {
returnType = new CodeTypeReference("");
}
return returnType;
}
set {
returnType = value;
}
}
///
///
/// The parameters of the delegate.
///
///
public CodeParameterDeclarationExpressionCollection Parameters {
get {
return parameters;
}
}
}
}
// 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
- OleCmdHelper.cs
- ManagementOperationWatcher.cs
- ImageBrush.cs
- Module.cs
- XmlILIndex.cs
- ClientSponsor.cs
- WindowPattern.cs
- MonitorWrapper.cs
- GroupBox.cs
- RuntimeHandles.cs
- XmlQueryOutput.cs
- TypeGeneratedEventArgs.cs
- GridViewUpdatedEventArgs.cs
- ReplyChannel.cs
- TableLayoutSettingsTypeConverter.cs
- Selection.cs
- autovalidator.cs
- BinaryFormatterWriter.cs
- WsdlContractConversionContext.cs
- HtmlCalendarAdapter.cs
- OperatingSystem.cs
- IfAction.cs
- log.cs
- DispatcherFrame.cs
- OwnerDrawPropertyBag.cs
- WsrmTraceRecord.cs
- SafeUserTokenHandle.cs
- AnchoredBlock.cs
- x509store.cs
- VisualStyleInformation.cs
- TypeFieldSchema.cs
- ArglessEventHandlerProxy.cs
- KeyInterop.cs
- DrawItemEvent.cs
- DataView.cs
- XmlArrayItemAttributes.cs
- PreservationFileWriter.cs
- TypeBuilder.cs
- WebPartDescriptionCollection.cs
- CatalogPart.cs
- CompilationPass2TaskInternal.cs
- PlacementWorkspace.cs
- WebPartCatalogAddVerb.cs
- X509Certificate2.cs
- EventOpcode.cs
- XmlReflectionImporter.cs
- DocumentCollection.cs
- SortAction.cs
- Publisher.cs
- WindowsAuthenticationEventArgs.cs
- DictionaryEditChange.cs
- MessageSmuggler.cs
- EDesignUtil.cs
- DocumentPaginator.cs
- WSSecureConversation.cs
- MethodAccessException.cs
- TimeStampChecker.cs
- AutomationProperties.cs
- DataSourceXmlTextReader.cs
- SQLBinary.cs
- RestHandlerFactory.cs
- xmlformatgeneratorstatics.cs
- streamingZipPartStream.cs
- XmlWriterTraceListener.cs
- CodeIdentifiers.cs
- UserControlFileEditor.cs
- IntSecurity.cs
- OpenTypeCommon.cs
- MethodImplAttribute.cs
- NativeObjectSecurity.cs
- OpacityConverter.cs
- UmAlQuraCalendar.cs
- XmlQueryContext.cs
- EventWaitHandleSecurity.cs
- ImageFormat.cs
- InputGestureCollection.cs
- BuildDependencySet.cs
- ComNativeDescriptor.cs
- FormatException.cs
- MatchAttribute.cs
- SessionSwitchEventArgs.cs
- ProxyWebPart.cs
- ConfigXmlCDataSection.cs
- RIPEMD160Managed.cs
- RuntimeArgumentHandle.cs
- CryptoKeySecurity.cs
- XmlSchemaFacet.cs
- UIElement.cs
- Publisher.cs
- TextMarkerSource.cs
- DesignerObjectListAdapter.cs
- InvokeHandlers.cs
- TableItemProviderWrapper.cs
- InstanceValue.cs
- XmlSchemaException.cs
- SpnegoTokenProvider.cs
- CodeExpressionStatement.cs
- QuaternionAnimationBase.cs
- HttpRuntimeSection.cs
- CharacterString.cs