Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Speech / Src / Internal / GrammarBuilding / GrammarBuilderRuleRef.cs / 1 / GrammarBuilderRuleRef.cs
//------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------- #define CODE_ANALYSIS using System.Speech.Recognition; using System.Speech.Internal.SrgsParser; using System.Diagnostics; namespace System.Speech.Internal.GrammarBuilding { ////// /// internal sealed class GrammarBuilderRuleRef : GrammarBuilderBase { //******************************************************************* // // Constructors // //******************************************************************* #region Constructors ////// /// /// /// internal GrammarBuilderRuleRef (Uri uri, string rule) { _uri = uri.OriginalString + ((rule != null) ? "#" + rule : ""); } ////// /// /// private GrammarBuilderRuleRef (string sgrsUri) { _uri = sgrsUri; } #endregion //******************************************************************** // // Public Methods // //******************************************************************* #region Public Methods /// TODOC <_include file='doc\SpeechAudioFormatInfo.uex' path='docs/doc[@for="SpeechAudioFormatInfo.Equals"]/*' /> public override bool Equals (object obj) { GrammarBuilderRuleRef refObj = obj as GrammarBuilderRuleRef; if (refObj == null) { return false; } return _uri == refObj._uri; } /// TODOC <_include file='doc\SpeechAudioFormatInfo.uex' path='docs/doc[@for="SpeechAudioFormatInfo.GetHashCode"]/*' /> public override int GetHashCode () { return _uri.GetHashCode (); } #endregion //******************************************************************** // // Internal Methods // //******************************************************************** #region Internal Methods ////// /// ///internal override GrammarBuilderBase Clone () { return new GrammarBuilderRuleRef (_uri); } /// /// /// /// /// /// /// ///internal override IElement CreateElement (IElementFactory elementFactory, IElement parent, IRule rule, IdentifierCollection ruleIds) { Uri ruleUri = new Uri (_uri, UriKind.RelativeOrAbsolute); return elementFactory.CreateRuleRef (parent, ruleUri, null, null); } #endregion //******************************************************************* // // Internal Properties // //******************************************************************** #region Internal Properties override internal string DebugSummary { get { return "#" + _uri; } } #endregion //******************************************************************* // // Private Fields // //******************************************************************* #region Private Fields /// /// /// private readonly string _uri; #endregion } } // 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
- EventDescriptorCollection.cs
- ManagedIStream.cs
- ReturnValue.cs
- DuplexSecurityProtocolFactory.cs
- ConditionChanges.cs
- SmtpNetworkElement.cs
- XmlILIndex.cs
- XmlChildNodes.cs
- ExpressionList.cs
- TemplateKey.cs
- WebPartPersonalization.cs
- ListViewGroupConverter.cs
- IdentityModelStringsVersion1.cs
- RoleBoolean.cs
- IISMapPath.cs
- EmptyStringExpandableObjectConverter.cs
- TextWriterTraceListener.cs
- InstanceNormalEvent.cs
- ForEachAction.cs
- EventlogProvider.cs
- DataGridItemCollection.cs
- JavaScriptObjectDeserializer.cs
- ServiceModelExtensionElement.cs
- XmlSchemas.cs
- KoreanCalendar.cs
- MeshGeometry3D.cs
- InputMethodStateChangeEventArgs.cs
- PropertyEntry.cs
- ColumnResizeUndoUnit.cs
- PenCursorManager.cs
- SizeAnimationClockResource.cs
- MultipartContentParser.cs
- Msec.cs
- WinFormsUtils.cs
- StringCollection.cs
- DocumentCollection.cs
- QueryContinueDragEventArgs.cs
- BuildResultCache.cs
- String.cs
- DoubleAnimationBase.cs
- ImagingCache.cs
- FunctionImportElement.cs
- NullableDecimalMinMaxAggregationOperator.cs
- DictionaryTraceRecord.cs
- DesignerToolboxInfo.cs
- UIElementHelper.cs
- Fonts.cs
- ConditionalAttribute.cs
- Update.cs
- NameGenerator.cs
- SQLResource.cs
- ProfilePropertySettings.cs
- PkcsMisc.cs
- Site.cs
- WindowsToolbar.cs
- AssertFilter.cs
- CompilationUnit.cs
- CompositeFontInfo.cs
- XmlHierarchicalEnumerable.cs
- StoreItemCollection.Loader.cs
- IdentityHolder.cs
- XmlSortKey.cs
- AssemblyHash.cs
- TypeValidationEventArgs.cs
- MsmqSecureHashAlgorithm.cs
- ProfilePropertyMetadata.cs
- TTSEngineProxy.cs
- StreamAsIStream.cs
- VariantWrapper.cs
- TextTrailingCharacterEllipsis.cs
- WebConfigurationFileMap.cs
- ellipse.cs
- WebColorConverter.cs
- ConfigurationManagerInternalFactory.cs
- SchemaElement.cs
- SecureUICommand.cs
- XmlCharType.cs
- XmlIlTypeHelper.cs
- wpf-etw.cs
- MaskDescriptors.cs
- ViewCellRelation.cs
- ForceCopyBuildProvider.cs
- AttributeUsageAttribute.cs
- TreeView.cs
- Relationship.cs
- SimpleLine.cs
- TextAutomationPeer.cs
- Int16Storage.cs
- DataList.cs
- Internal.cs
- dtdvalidator.cs
- SessionSwitchEventArgs.cs
- HttpRuntimeSection.cs
- TypeDescriptionProvider.cs
- MultiAsyncResult.cs
- WindowsSecurityTokenAuthenticator.cs
- WindowExtensionMethods.cs
- Int32AnimationBase.cs
- HttpChannelHelpers.cs
- SystemException.cs