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
- SystemBrushes.cs
- XmlParserContext.cs
- DataContractSet.cs
- CodeDirectiveCollection.cs
- ToolStripSystemRenderer.cs
- CompilationLock.cs
- MulticastDelegate.cs
- EditorBrowsableAttribute.cs
- CompositeClientFormatter.cs
- XmlEncodedRawTextWriter.cs
- HWStack.cs
- FormView.cs
- ProfilePropertySettingsCollection.cs
- SystemTcpConnection.cs
- AttachedAnnotation.cs
- ComboBoxItem.cs
- HttpProtocolReflector.cs
- TextCharacters.cs
- WsdlWriter.cs
- XpsFilter.cs
- InheritablePropertyChangeInfo.cs
- CollectionEditorDialog.cs
- Parallel.cs
- QilPatternVisitor.cs
- CodeCastExpression.cs
- TextServicesCompartmentContext.cs
- AnnotationService.cs
- WebReferencesBuildProvider.cs
- SectionUpdates.cs
- CatalogPartDesigner.cs
- PerformanceCounter.cs
- Walker.cs
- UnsafePeerToPeerMethods.cs
- PartitionedStream.cs
- ObjectNavigationPropertyMapping.cs
- RenderingEventArgs.cs
- Listbox.cs
- UnauthorizedAccessException.cs
- ContextMarshalException.cs
- ConstraintEnumerator.cs
- ServerValidateEventArgs.cs
- SwitchAttribute.cs
- input.cs
- WeakReferenceList.cs
- StructuredCompositeActivityDesigner.cs
- DiscoveryExceptionDictionary.cs
- LinqDataSourceSelectEventArgs.cs
- Wow64ConfigurationLoader.cs
- ScrollItemProviderWrapper.cs
- DetailsViewDeleteEventArgs.cs
- DateTimeAutomationPeer.cs
- ConnectionsZone.cs
- TCPListener.cs
- UrlMapping.cs
- SoapAttributes.cs
- ConsumerConnectionPoint.cs
- InvokeDelegate.cs
- BasicCellRelation.cs
- ExclusiveTcpListener.cs
- RegexTree.cs
- GridViewHeaderRowPresenter.cs
- EndpointBehaviorElement.cs
- VirtualPath.cs
- FlowchartDesigner.Helpers.cs
- SchemaNamespaceManager.cs
- ConfigurationValidatorBase.cs
- SeekableReadStream.cs
- TextTreeTextBlock.cs
- TransformerTypeCollection.cs
- ImageButton.cs
- AggregateNode.cs
- KeyGesture.cs
- HtmlTextArea.cs
- HybridWebProxyFinder.cs
- Control.cs
- xmlglyphRunInfo.cs
- LogEntry.cs
- Image.cs
- RMPublishingDialog.cs
- CodePropertyReferenceExpression.cs
- TraceListeners.cs
- BatchStream.cs
- PathSegment.cs
- FixedSOMTableRow.cs
- QueryContinueDragEvent.cs
- ArrangedElementCollection.cs
- SafeNativeMethods.cs
- TextControl.cs
- MatrixAnimationBase.cs
- StrokeCollectionConverter.cs
- CodeTypeOfExpression.cs
- IsolatedStorageException.cs
- RolePrincipal.cs
- Control.cs
- PointF.cs
- XmlSchemaIdentityConstraint.cs
- ByteFacetDescriptionElement.cs
- XamlSerializationHelper.cs
- TableStyle.cs
- PackageStore.cs