Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / wpf / src / Framework / System / Windows / Documents / DocumentStructures / StoryFragments.cs / 1 / StoryFragments.cs
//---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // History: // 05/12/2005 : mingliu - created. // // //--------------------------------------------------------------------------- using MS.Internal.Documents; using MS.Utility; using System; using System.Collections; using System.Collections.Generic; using System.Collections.ObjectModel; using System.Diagnostics; using System.Reflection; using System.Security.Permissions; using System.Windows.Controls.Primitives; using System.Windows.Documents; using System.Windows.Media; using System.Windows.Shapes; using System.Windows.Markup; [assembly: XmlnsDefinition( "http://schemas.microsoft.com/xps/2005/06/documentstructure", "System.Windows.Documents.DocumentStructures")] namespace System.Windows.Documents.DocumentStructures { ////// /// public class StoryFragments : IAddChildInternal { ////// /// public StoryFragments() { _elementList = new List(); } void IAddChild.AddChild(object value) { // // Only the StoryFragment type are accepted. // if (value is StoryFragment) { _elementList.Add( (StoryFragment) value); return; } throw new ArgumentException(SR.Get(SRID.UnexpectedParameterType, value.GetType(), typeof(StoryFragment)), "value"); } void IAddChild.AddText(string text) { } internal List StoryFragmentList { get { return _elementList; } } private List _elementList; } /// /// /// public class StoryFragment : IAddChildInternal { ////// /// public StoryFragment() { _elementList = new List(); } void IAddChild.AddChild(object value) { // // Only the following type are accepted. // Section|Paragraph|Inline(Bold|Italic|Underline)|Floater|Figure|List // |Table|StoryBreak // if (value is SectionStructure || value is ParagraphStructure || value is FigureStructure || value is ListStructure || value is TableStructure || value is StoryBreak) { _elementList.Add( (BlockElement) value); return; } throw new ArgumentException(SR.Get(SRID.DocumentStructureUnexpectedParameterType6, value.GetType(), typeof(SectionStructure), typeof(ParagraphStructure), typeof(FigureStructure), typeof(ListStructure), typeof(TableStructure), typeof(StoryBreak)), "value"); } void IAddChild.AddText(string text) { } /// /// The element name /// public string StoryName { get { return _storyName; } set { _storyName = value; } } ////// The element name /// public string FragmentName { get { return _fragmentName; } set { _fragmentName = value; } } ////// The element name /// public String FragmentType { get { return _fragmentType; } set { _fragmentType = value; } } internal ListBlockElementList { get { return _elementList; } } private List _elementList; private String _storyName; private String _fragmentName; private String _fragmentType; } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //---------------------------------------------------------------------------- // // // Copyright (C) Microsoft Corporation. All rights reserved. // // // History: // 05/12/2005 : mingliu - created. // // //--------------------------------------------------------------------------- using MS.Internal.Documents; using MS.Utility; using System; using System.Collections; using System.Collections.Generic; using System.Collections.ObjectModel; using System.Diagnostics; using System.Reflection; using System.Security.Permissions; using System.Windows.Controls.Primitives; using System.Windows.Documents; using System.Windows.Media; using System.Windows.Shapes; using System.Windows.Markup; [assembly: XmlnsDefinition( "http://schemas.microsoft.com/xps/2005/06/documentstructure", "System.Windows.Documents.DocumentStructures")] namespace System.Windows.Documents.DocumentStructures { ////// /// public class StoryFragments : IAddChildInternal { ////// /// public StoryFragments() { _elementList = new List(); } void IAddChild.AddChild(object value) { // // Only the StoryFragment type are accepted. // if (value is StoryFragment) { _elementList.Add( (StoryFragment) value); return; } throw new ArgumentException(SR.Get(SRID.UnexpectedParameterType, value.GetType(), typeof(StoryFragment)), "value"); } void IAddChild.AddText(string text) { } internal List StoryFragmentList { get { return _elementList; } } private List _elementList; } /// /// /// public class StoryFragment : IAddChildInternal { ////// /// public StoryFragment() { _elementList = new List(); } void IAddChild.AddChild(object value) { // // Only the following type are accepted. // Section|Paragraph|Inline(Bold|Italic|Underline)|Floater|Figure|List // |Table|StoryBreak // if (value is SectionStructure || value is ParagraphStructure || value is FigureStructure || value is ListStructure || value is TableStructure || value is StoryBreak) { _elementList.Add( (BlockElement) value); return; } throw new ArgumentException(SR.Get(SRID.DocumentStructureUnexpectedParameterType6, value.GetType(), typeof(SectionStructure), typeof(ParagraphStructure), typeof(FigureStructure), typeof(ListStructure), typeof(TableStructure), typeof(StoryBreak)), "value"); } void IAddChild.AddText(string text) { } /// /// The element name /// public string StoryName { get { return _storyName; } set { _storyName = value; } } ////// The element name /// public string FragmentName { get { return _fragmentName; } set { _fragmentName = value; } } ////// The element name /// public String FragmentType { get { return _fragmentType; } set { _fragmentType = value; } } internal ListBlockElementList { get { return _elementList; } } private List _elementList; private String _storyName; private String _fragmentName; private String _fragmentType; } } // 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
- Timeline.cs
- NavigatorOutput.cs
- DBCommandBuilder.cs
- ApplicationTrust.cs
- MetaChildrenColumn.cs
- SystemUdpStatistics.cs
- ConfigurationValues.cs
- HashCodeCombiner.cs
- SafeMILHandleMemoryPressure.cs
- ValidatedMobileControlConverter.cs
- RequestCachePolicyConverter.cs
- Types.cs
- SetterBase.cs
- JpegBitmapEncoder.cs
- SelectorAutomationPeer.cs
- Certificate.cs
- PropertyChangedEventManager.cs
- OrthographicCamera.cs
- sqlmetadatafactory.cs
- DbDataRecord.cs
- isolationinterop.cs
- TriggerActionCollection.cs
- Internal.cs
- Stack.cs
- GridViewDeletedEventArgs.cs
- AssociationSet.cs
- X509SecurityTokenProvider.cs
- VisualStyleRenderer.cs
- RelationalExpressions.cs
- XPathBinder.cs
- MimeWriter.cs
- TdsParserStateObject.cs
- ToolStripContainerDesigner.cs
- HijriCalendar.cs
- XmlWrappingReader.cs
- CannotUnloadAppDomainException.cs
- EqualityComparer.cs
- Hyperlink.cs
- ClientViaElement.cs
- DbReferenceCollection.cs
- ParameterElement.cs
- RefExpr.cs
- LayoutTableCell.cs
- VirtualPathProvider.cs
- GeometryCombineModeValidation.cs
- Descriptor.cs
- UTF8Encoding.cs
- EmptyStringExpandableObjectConverter.cs
- CryptoHelper.cs
- QueryCacheKey.cs
- DataGridHeaderBorder.cs
- ThreadInterruptedException.cs
- SQLInt64Storage.cs
- LinkButton.cs
- DataGridViewColumnHeaderCell.cs
- ActivityTypeResolver.xaml.cs
- PathFigure.cs
- _ConnectionGroup.cs
- InstanceCreationEditor.cs
- MethodCallExpression.cs
- Helpers.cs
- NameTable.cs
- CodeDelegateCreateExpression.cs
- AxisAngleRotation3D.cs
- PrintSystemException.cs
- CqlParser.cs
- ToolStripContainer.cs
- DataBoundControlHelper.cs
- UserControl.cs
- ResourceExpressionBuilder.cs
- DrawingBrush.cs
- VBIdentifierDesigner.xaml.cs
- ZipIOEndOfCentralDirectoryBlock.cs
- WindowsIPAddress.cs
- GenericParameterDataContract.cs
- JapaneseLunisolarCalendar.cs
- ObjectDataSourceView.cs
- EntityDataSourceEntityTypeFilterItem.cs
- PropertyEntry.cs
- newinstructionaction.cs
- FacetValueContainer.cs
- MultipartContentParser.cs
- DocComment.cs
- WebPartVerbCollection.cs
- PageParser.cs
- TabControlCancelEvent.cs
- RequiredFieldValidator.cs
- EntityTypeBase.cs
- XPathNavigatorKeyComparer.cs
- SelectedGridItemChangedEvent.cs
- BoundingRectTracker.cs
- DataGridView.cs
- CharEntityEncoderFallback.cs
- MethodAccessException.cs
- UrlAuthorizationModule.cs
- Task.cs
- ReliableSessionElement.cs
- StrongName.cs
- Utils.cs
- SyndicationSerializer.cs