Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / fx / src / Designer / System / data / design / TypedRowHandler.cs / 1 / TypedRowHandler.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All Rights Reserved. // Information Contained Herein is Proprietary and Confidential. // //----------------------------------------------------------------------------- namespace System.Data.Design { using System; using System.CodeDom; using System.Collections; using System.ComponentModel; using System.Data; using System.Reflection; internal sealed class TypedRowHandler { private TypedDataSourceCodeGenerator codeGenerator = null; private DesignTableCollection tables = null; private TypedRowGenerator rowGenerator = null; internal TypedRowHandler(TypedDataSourceCodeGenerator codeGenerator, DesignTableCollection tables) { this.codeGenerator = codeGenerator; this.tables = tables; this.rowGenerator = new TypedRowGenerator(codeGenerator); } internal TypedRowGenerator RowGenerator { get { return rowGenerator; } } internal void AddTypedRowEvents(CodeTypeDeclaration dataTableClass, string tableName) { DesignTable designTable = codeGenerator.TableHandler.Tables[tableName]; string rowClassName = designTable.GeneratorRowClassName; string rowEventHandlerName = designTable.GeneratorRowEvHandlerName; dataTableClass.Members.Add( CodeGenHelper.EventDecl( rowEventHandlerName, designTable.GeneratorRowChangingName ) ); dataTableClass.Members.Add( CodeGenHelper.EventDecl( rowEventHandlerName, designTable.GeneratorRowChangedName ) ); dataTableClass.Members.Add( CodeGenHelper.EventDecl( rowEventHandlerName, designTable.GeneratorRowDeletingName ) ); dataTableClass.Members.Add( CodeGenHelper.EventDecl( rowEventHandlerName, designTable.GeneratorRowDeletedName ) ); } internal void AddTypedRows(CodeTypeDeclaration dataSourceClass) { rowGenerator.GenerateRows(dataSourceClass); } internal void AddTypedRowEventHandlers(CodeTypeDeclaration dataSourceClass) { rowGenerator.GenerateTypedRowEventHandlers(dataSourceClass); } internal void AddTypedRowEventArgs(CodeTypeDeclaration dataSourceClass) { rowGenerator.GenerateTypedRowEventArgs(dataSourceClass); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- GlyphRunDrawing.cs
- RemoveStoryboard.cs
- DeadCharTextComposition.cs
- MessageSmuggler.cs
- MatrixCamera.cs
- StylusPlugInCollection.cs
- ConstrainedDataObject.cs
- WindowsSolidBrush.cs
- SystemResources.cs
- ScrollItemPattern.cs
- EventRouteFactory.cs
- HtmlHead.cs
- Rotation3DAnimationBase.cs
- FormView.cs
- DataGridViewButtonCell.cs
- MarkupExtensionReturnTypeAttribute.cs
- CorrelationManager.cs
- ByteConverter.cs
- DataGridViewSortCompareEventArgs.cs
- CallbackCorrelationInitializer.cs
- FontInfo.cs
- HashMembershipCondition.cs
- SerializerProvider.cs
- PipeSecurity.cs
- WizardStepBase.cs
- SafeReversePInvokeHandle.cs
- OutputWindow.cs
- SharedMemory.cs
- RegexRunnerFactory.cs
- ToolStripTemplateNode.cs
- ImageMap.cs
- Cursors.cs
- SequenceDesigner.cs
- cache.cs
- NetCodeGroup.cs
- AccessViolationException.cs
- ContextMenuAutomationPeer.cs
- AspNetSynchronizationContext.cs
- DateTimeParse.cs
- FacetValues.cs
- DropShadowBitmapEffect.cs
- SoapTypeAttribute.cs
- BooleanAnimationUsingKeyFrames.cs
- DesignerUtility.cs
- RectangleGeometry.cs
- webclient.cs
- LockedActivityGlyph.cs
- Switch.cs
- DbgUtil.cs
- Int32Collection.cs
- SerializationInfo.cs
- MediaTimeline.cs
- ProfileSettings.cs
- ControlCachePolicy.cs
- ObjectCacheSettings.cs
- ServiceNameElement.cs
- CommandValueSerializer.cs
- remotingproxy.cs
- HttpResponseInternalWrapper.cs
- TextEditorDragDrop.cs
- ToolStripItemCollection.cs
- ObjectContextServiceProvider.cs
- RenderData.cs
- ScriptDescriptor.cs
- StringSource.cs
- HtmlLink.cs
- ConfigPathUtility.cs
- UIElementHelper.cs
- DefaultWorkflowLoaderService.cs
- PeerObject.cs
- XmlReflectionImporter.cs
- HashSet.cs
- XmlWhitespace.cs
- Codec.cs
- BreadCrumbTextConverter.cs
- MessageDescriptionCollection.cs
- PersistencePipeline.cs
- DataRelationCollection.cs
- DBConnectionString.cs
- ProtocolElement.cs
- ContextMenu.cs
- ServiceHttpModule.cs
- MailWriter.cs
- SystemDiagnosticsSection.cs
- SHA512Managed.cs
- GacUtil.cs
- WebFaultClientMessageInspector.cs
- PreservationFileWriter.cs
- PreviewPageInfo.cs
- NamedPermissionSet.cs
- ScrollChrome.cs
- Classification.cs
- AudioBase.cs
- MsmqReceiveParameters.cs
- Ports.cs
- GeometryHitTestResult.cs
- DesignerSerializationManager.cs
- ChannelFactoryBase.cs
- FunctionQuery.cs
- UnsafeNativeMethodsMilCoreApi.cs