Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / ndp / fx / src / DataEntityDesign / Design / System / Data / EntityModel / Emitters / ComplexTypeEmitter.cs / 2 / ComplexTypeEmitter.cs
//----------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//
// @owner [....]
// @backupOwner [....]
//---------------------------------------------------------------------
using System;
using System.CodeDom;
using System.Data;
using System.Data.Metadata.Edm;
using System.Data.EntityModel.SchemaObjectModel;
namespace System.Data.EntityModel.Emitters
{
///
/// Summary description for NestedTypeEmitter.
///
internal sealed class ComplexTypeEmitter : StructuredTypeEmitter
{
#region Methods
///
///
///
///
///
public ComplexTypeEmitter(ClientApiGenerator generator, ComplexType complexType)
: base(generator, complexType)
{
}
///
/// Apply the attributes to this type.
///
/// The declaration of the type that should have attributes added to it.
protected override void EmitTypeAttributes( CodeTypeDeclaration typeDecl )
{
Generator.AttributeEmitter.EmitTypeAttributes( this, typeDecl );
base.EmitTypeAttributes( typeDecl );
}
#endregion
#region Protected Properties
///
///
///
///
protected override CodeTypeReference GetBaseType()
{
CodeTypeReference baseType = base.GetBaseType();
if (baseType == null)
{
baseType = TypeReference.ComplexTypeBaseClass;
}
return baseType;
}
protected override ReadOnlyMetadataCollection GetProperties()
{
return Item.Properties;
}
internal new ComplexType Item
{
get
{
return base.Item as ComplexType;
}
}
#endregion
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
//----------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//
// @owner [....]
// @backupOwner [....]
//---------------------------------------------------------------------
using System;
using System.CodeDom;
using System.Data;
using System.Data.Metadata.Edm;
using System.Data.EntityModel.SchemaObjectModel;
namespace System.Data.EntityModel.Emitters
{
///
/// Summary description for NestedTypeEmitter.
///
internal sealed class ComplexTypeEmitter : StructuredTypeEmitter
{
#region Methods
///
///
///
///
///
public ComplexTypeEmitter(ClientApiGenerator generator, ComplexType complexType)
: base(generator, complexType)
{
}
///
/// Apply the attributes to this type.
///
/// The declaration of the type that should have attributes added to it.
protected override void EmitTypeAttributes( CodeTypeDeclaration typeDecl )
{
Generator.AttributeEmitter.EmitTypeAttributes( this, typeDecl );
base.EmitTypeAttributes( typeDecl );
}
#endregion
#region Protected Properties
///
///
///
///
protected override CodeTypeReference GetBaseType()
{
CodeTypeReference baseType = base.GetBaseType();
if (baseType == null)
{
baseType = TypeReference.ComplexTypeBaseClass;
}
return baseType;
}
protected override ReadOnlyMetadataCollection GetProperties()
{
return Item.Properties;
}
internal new ComplexType Item
{
get
{
return base.Item as ComplexType;
}
}
#endregion
}
}
// 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
- ServiceMemoryGates.cs
- xsdvalidator.cs
- StaticTextPointer.cs
- DataTable.cs
- Internal.cs
- TextBoxRenderer.cs
- Int16Storage.cs
- PeerMaintainer.cs
- SystemIPGlobalProperties.cs
- UnSafeCharBuffer.cs
- StringConverter.cs
- IDReferencePropertyAttribute.cs
- UriSection.cs
- HierarchicalDataBoundControl.cs
- HtmlInputButton.cs
- _SSPIWrapper.cs
- InlineObject.cs
- TextViewSelectionProcessor.cs
- XmlDataImplementation.cs
- TagPrefixCollection.cs
- SqlCommand.cs
- OleTxTransaction.cs
- CultureTable.cs
- XmlBinaryWriterSession.cs
- DrawingCollection.cs
- MemberRelationshipService.cs
- HelpKeywordAttribute.cs
- MemberAccessException.cs
- LineSegment.cs
- TreeViewCancelEvent.cs
- ListViewAutomationPeer.cs
- BeginEvent.cs
- SystemColors.cs
- SerializationIncompleteException.cs
- WebEventCodes.cs
- ObjectDataProvider.cs
- ImageIndexEditor.cs
- FlatButtonAppearance.cs
- DrawingContext.cs
- DataRelationCollection.cs
- OutOfProcStateClientManager.cs
- MailHeaderInfo.cs
- XmlChoiceIdentifierAttribute.cs
- LocatorPart.cs
- PhysicalAddress.cs
- AliasGenerator.cs
- FileDialog_Vista.cs
- X509UI.cs
- CalendarAutoFormat.cs
- DataGridViewCellLinkedList.cs
- DistributedTransactionPermission.cs
- _DomainName.cs
- SecurityRuntime.cs
- FixedSOMTableRow.cs
- LabelLiteral.cs
- WCFModelStrings.Designer.cs
- Filter.cs
- SubstitutionResponseElement.cs
- TextEndOfSegment.cs
- HtmlMeta.cs
- Permission.cs
- ErrorWebPart.cs
- HwndAppCommandInputProvider.cs
- ContentElementAutomationPeer.cs
- NetTcpSecurity.cs
- SystemSounds.cs
- DataRowView.cs
- EntityDataSourceContextCreatedEventArgs.cs
- StatusStrip.cs
- PaperSource.cs
- BitmapSizeOptions.cs
- StringValueSerializer.cs
- ExpressionPrefixAttribute.cs
- X509ThumbprintKeyIdentifierClause.cs
- BindingsCollection.cs
- LoginView.cs
- XmlUtf8RawTextWriter.cs
- RemoveStoryboard.cs
- objectresult_tresulttype.cs
- Constraint.cs
- Literal.cs
- InfoCardMetadataExchangeClient.cs
- TrackingMemoryStreamFactory.cs
- Partitioner.cs
- XmlSchemas.cs
- ProviderException.cs
- NamespaceTable.cs
- TypeLibConverter.cs
- XslVisitor.cs
- StringExpressionSet.cs
- Transform3D.cs
- PublishLicense.cs
- SessionPageStateSection.cs
- KnownTypesHelper.cs
- InputProcessorProfiles.cs
- ThemeableAttribute.cs
- MemoryFailPoint.cs
- ImageIndexEditor.cs
- ListViewItem.cs
- ImageMapEventArgs.cs