Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / Xml / System / Xml / Dom / XmlNotation.cs / 1 / XmlNotation.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //[....] //----------------------------------------------------------------------------- namespace System.Xml { using System; using System.Diagnostics; // Contains a notation declared in the DTD or schema. public class XmlNotation : XmlNode { String publicId; String systemId; String name; internal XmlNotation( String name, String publicId, String systemId, XmlDocument doc ): base( doc ) { this.name = doc.NameTable.Add(name); this.publicId = publicId; this.systemId = systemId; } // Gets the name of the node. public override string Name { get { return name;} } // Gets the name of the current node without the namespace prefix. public override string LocalName { get { return name;} } // Gets the type of the current node. public override XmlNodeType NodeType { get { return XmlNodeType.Notation;} } // Throws an InvalidOperationException since Notation can not be cloned. public override XmlNode CloneNode(bool deep) { throw new InvalidOperationException(Res.GetString(Res.Xdom_Node_Cloning)); } // // Microsoft extensions // // Gets a value indicating whether the node is read-only. public override bool IsReadOnly { get { return true; // Make notations readonly } } // Gets the value of the public identifier on the notation declaration. public String PublicId { get { return publicId;} } // Gets the value of // the system identifier on the notation declaration. public String SystemId { get { return systemId;} } // Without override these two functions, we can't guarantee that WriteTo()/WriteContent() functions will never be called public override String OuterXml { get { return String.Empty; } } public override String InnerXml { get { return String.Empty; } set { throw new InvalidOperationException( Res.GetString(Res.Xdom_Set_InnerXml ) ); } } // Saves the node to the specified XmlWriter. public override void WriteTo(XmlWriter w) { } // Saves all the children of the node to the specified XmlWriter. public override void WriteContentTo(XmlWriter w) { } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //[....] //----------------------------------------------------------------------------- namespace System.Xml { using System; using System.Diagnostics; // Contains a notation declared in the DTD or schema. public class XmlNotation : XmlNode { String publicId; String systemId; String name; internal XmlNotation( String name, String publicId, String systemId, XmlDocument doc ): base( doc ) { this.name = doc.NameTable.Add(name); this.publicId = publicId; this.systemId = systemId; } // Gets the name of the node. public override string Name { get { return name;} } // Gets the name of the current node without the namespace prefix. public override string LocalName { get { return name;} } // Gets the type of the current node. public override XmlNodeType NodeType { get { return XmlNodeType.Notation;} } // Throws an InvalidOperationException since Notation can not be cloned. public override XmlNode CloneNode(bool deep) { throw new InvalidOperationException(Res.GetString(Res.Xdom_Node_Cloning)); } // // Microsoft extensions // // Gets a value indicating whether the node is read-only. public override bool IsReadOnly { get { return true; // Make notations readonly } } // Gets the value of the public identifier on the notation declaration. public String PublicId { get { return publicId;} } // Gets the value of // the system identifier on the notation declaration. public String SystemId { get { return systemId;} } // Without override these two functions, we can't guarantee that WriteTo()/WriteContent() functions will never be called public override String OuterXml { get { return String.Empty; } } public override String InnerXml { get { return String.Empty; } set { throw new InvalidOperationException( Res.GetString(Res.Xdom_Set_InnerXml ) ); } } // Saves the node to the specified XmlWriter. public override void WriteTo(XmlWriter w) { } // Saves all the children of the node to the specified XmlWriter. public override void WriteContentTo(XmlWriter w) { } } } // 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
- BooleanAnimationUsingKeyFrames.cs
- Membership.cs
- WmpBitmapEncoder.cs
- RequestTimeoutManager.cs
- EFDataModelProvider.cs
- DataListItemCollection.cs
- StoreContentChangedEventArgs.cs
- UIntPtr.cs
- ISO2022Encoding.cs
- DecimalAnimationUsingKeyFrames.cs
- ValueExpressions.cs
- ExpressionPrinter.cs
- CatalogPartCollection.cs
- LowerCaseStringConverter.cs
- OutputCacheSettingsSection.cs
- MediaEntryAttribute.cs
- EntitySqlQueryCacheKey.cs
- SemanticResolver.cs
- SQLInt32Storage.cs
- DebugHandleTracker.cs
- Panel.cs
- SimpleTypeResolver.cs
- ParentQuery.cs
- WmlLinkAdapter.cs
- PrintDialog.cs
- DataStreamFromComStream.cs
- HostDesigntimeLicenseContext.cs
- Debug.cs
- DataIdProcessor.cs
- CheckBoxField.cs
- GridEntry.cs
- XamlVector3DCollectionSerializer.cs
- WebCodeGenerator.cs
- UnsafeNativeMethodsCLR.cs
- ResourceReferenceExpression.cs
- QilGeneratorEnv.cs
- Page.cs
- GraphicsPathIterator.cs
- AssociationSetMetadata.cs
- XmlLoader.cs
- CodeNamespaceImportCollection.cs
- EraserBehavior.cs
- HostSecurityManager.cs
- Binding.cs
- DrawingBrush.cs
- SqlProvider.cs
- XmlSerializer.cs
- SecurityDescriptor.cs
- ReceiveDesigner.xaml.cs
- TreeNode.cs
- Helper.cs
- HebrewNumber.cs
- ProcessMonitor.cs
- DbProviderSpecificTypePropertyAttribute.cs
- SqlParameter.cs
- IsolatedStorageException.cs
- EnumMemberAttribute.cs
- GridErrorDlg.cs
- Function.cs
- AbstractSvcMapFileLoader.cs
- MoveSizeWinEventHandler.cs
- BindingSource.cs
- SafeProcessHandle.cs
- KeyValueConfigurationCollection.cs
- TextFragmentEngine.cs
- BamlCollectionHolder.cs
- UpdateProgress.cs
- DataServiceProcessingPipelineEventArgs.cs
- MinimizableAttributeTypeConverter.cs
- FixedTextContainer.cs
- WebBrowsableAttribute.cs
- RenderingBiasValidation.cs
- GeneralTransform3DTo2D.cs
- BuildResult.cs
- FormViewInsertEventArgs.cs
- MemoryFailPoint.cs
- CompositeFontParser.cs
- Serializer.cs
- Graphics.cs
- BadImageFormatException.cs
- ReceiveCompletedEventArgs.cs
- EventManager.cs
- CapabilitiesAssignment.cs
- TextParagraph.cs
- SourceFileInfo.cs
- ListItemCollection.cs
- MenuItem.cs
- UTF7Encoding.cs
- FileSystemInfo.cs
- DeviceFiltersSection.cs
- ToolStripDropDownButton.cs
- RadioButtonList.cs
- List.cs
- WebServiceEndpoint.cs
- Parser.cs
- EllipseGeometry.cs
- Error.cs
- AutomationProperties.cs
- QualifiedCellIdBoolean.cs
- TableRowCollection.cs