Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / CompMod / System / CodeDOM / CodeCastExpression.cs / 1 / CodeCastExpression.cs
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.CodeDom {
using System.Diagnostics;
using System;
using Microsoft.Win32;
using System.Collections;
using System.Runtime.InteropServices;
///
///
/// Represents a
/// type cast expression.
///
///
[
ClassInterface(ClassInterfaceType.AutoDispatch),
ComVisible(true),
Serializable,
]
public class CodeCastExpression : CodeExpression {
private CodeTypeReference targetType;
private CodeExpression expression;
///
///
/// Initializes a new instance of .
///
///
public CodeCastExpression() {
}
///
///
/// Initializes a new instance of using the specified
/// parameters.
///
///
public CodeCastExpression(CodeTypeReference targetType, CodeExpression expression) {
TargetType = targetType;
Expression = expression;
}
///
/// [To be supplied.]
///
public CodeCastExpression(string targetType, CodeExpression expression) {
TargetType = new CodeTypeReference(targetType);
Expression = expression;
}
///
/// [To be supplied.]
///
public CodeCastExpression(Type targetType, CodeExpression expression) {
TargetType = new CodeTypeReference(targetType);
Expression = expression;
}
///
///
/// The target type of the cast.
///
///
public CodeTypeReference TargetType {
get {
if (targetType == null) {
targetType = new CodeTypeReference("");
}
return targetType;
}
set {
targetType = value;
}
}
///
///
/// The expression to cast.
///
///
public CodeExpression Expression {
get {
return expression;
}
set {
expression = value;
}
}
}
}
// 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.Runtime.InteropServices;
///
///
/// Represents a
/// type cast expression.
///
///
[
ClassInterface(ClassInterfaceType.AutoDispatch),
ComVisible(true),
Serializable,
]
public class CodeCastExpression : CodeExpression {
private CodeTypeReference targetType;
private CodeExpression expression;
///
///
/// Initializes a new instance of .
///
///
public CodeCastExpression() {
}
///
///
/// Initializes a new instance of using the specified
/// parameters.
///
///
public CodeCastExpression(CodeTypeReference targetType, CodeExpression expression) {
TargetType = targetType;
Expression = expression;
}
///
/// [To be supplied.]
///
public CodeCastExpression(string targetType, CodeExpression expression) {
TargetType = new CodeTypeReference(targetType);
Expression = expression;
}
///
/// [To be supplied.]
///
public CodeCastExpression(Type targetType, CodeExpression expression) {
TargetType = new CodeTypeReference(targetType);
Expression = expression;
}
///
///
/// The target type of the cast.
///
///
public CodeTypeReference TargetType {
get {
if (targetType == null) {
targetType = new CodeTypeReference("");
}
return targetType;
}
set {
targetType = value;
}
}
///
///
/// The expression to cast.
///
///
public CodeExpression Expression {
get {
return expression;
}
set {
expression = value;
}
}
}
}
// 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
- TextServicesDisplayAttribute.cs
- DataServiceContext.cs
- CodeGenerator.cs
- log.cs
- WebPartMovingEventArgs.cs
- PersonalizationDictionary.cs
- TransformationRules.cs
- Floater.cs
- DataBoundControl.cs
- CustomValidator.cs
- XmlObjectSerializerWriteContextComplexJson.cs
- SqlDependency.cs
- x509utils.cs
- RightsManagementEncryptedStream.cs
- unitconverter.cs
- EncoderReplacementFallback.cs
- ActiveXHost.cs
- HMACRIPEMD160.cs
- StylusPointCollection.cs
- SHA256.cs
- DEREncoding.cs
- UrlRoutingHandler.cs
- X509Utils.cs
- MethodCallConverter.cs
- BulletChrome.cs
- EdgeModeValidation.cs
- CallbackHandler.cs
- ExpressionEditorAttribute.cs
- WebEvents.cs
- InteropEnvironment.cs
- ProviderUtil.cs
- DataGridViewColumnEventArgs.cs
- TimerElapsedEvenArgs.cs
- NavigationHelper.cs
- StrokeNodeOperations.cs
- MenuItemCollection.cs
- odbcmetadatacolumnnames.cs
- ApplicationHost.cs
- ReferentialConstraint.cs
- ZipPackage.cs
- DataGridViewCellToolTipTextNeededEventArgs.cs
- CatchDesigner.xaml.cs
- PermissionListSet.cs
- ElementUtil.cs
- LoadedOrUnloadedOperation.cs
- RectangleHotSpot.cs
- QilPatternFactory.cs
- TableNameAttribute.cs
- XmlLinkedNode.cs
- DbSetClause.cs
- StatusBarDrawItemEvent.cs
- HMACSHA512.cs
- DependencyObjectPropertyDescriptor.cs
- SegmentInfo.cs
- ProcessingInstructionAction.cs
- ContentOperations.cs
- MethodExpr.cs
- EmptyStringExpandableObjectConverter.cs
- unsafenativemethodstextservices.cs
- SqlDataSourceConfigureSelectPanel.cs
- SystemIcmpV4Statistics.cs
- M3DUtil.cs
- JsonUriDataContract.cs
- XmlDataLoader.cs
- XmlSchemaSequence.cs
- TransactionalPackage.cs
- JavaScriptObjectDeserializer.cs
- StylusEditingBehavior.cs
- RegexRunner.cs
- DataGridRowDetailsEventArgs.cs
- SoapSchemaExporter.cs
- BaseDataBoundControl.cs
- PassportIdentity.cs
- TokenFactoryBase.cs
- ColumnMap.cs
- NativeMethods.cs
- SqlConnection.cs
- HttpBufferlessInputStream.cs
- ProfileInfo.cs
- QilSortKey.cs
- ControlCommandSet.cs
- TraceAsyncResult.cs
- ByteStack.cs
- RemotingException.cs
- EntityContainer.cs
- StackSpiller.Generated.cs
- RegexStringValidator.cs
- ArrangedElementCollection.cs
- TransformerInfoCollection.cs
- BinaryObjectInfo.cs
- DataBindEngine.cs
- FormViewUpdatedEventArgs.cs
- ResourceExpressionEditor.cs
- SchemaComplexType.cs
- HandoffBehavior.cs
- XmlBoundElement.cs
- Int16KeyFrameCollection.cs
- BitmapFrame.cs
- TabControlAutomationPeer.cs
- ZoneMembershipCondition.cs