Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Speech / Src / Internal / SrgsCompiler / ScriptRef.cs / 1 / ScriptRef.cs
//// Copyright (c) Microsoft Corporation. All rights reserved. // // // // Description: // // History: // 6/1/2004 jeanfp Created //----------------------------------------------------------------------------using System; using System.Diagnostics; using System.Speech.Internal.SrgsParser; namespace System.Speech.Internal.SrgsCompiler { ////// Summary description for ScriptRef. /// // list of rules with scripts #if VSCOMPILE [DebuggerDisplay ("rule=\"{_rule}\" method=\"{_sMethod}\" operation=\"{_method.ToString ()}\"")] #endif internal class ScriptRef { //******************************************************************* // // Constructors // //******************************************************************* #region Constructors internal ScriptRef (string rule, string sMethod, RuleMethodScript method) { _rule = rule; _sMethod = sMethod; _method = method; } #endregion //******************************************************************* // // Internal Methods // //******************************************************************** #region internal Methods internal void Serialize (StringBlob symbols, StreamMarshaler streamBuffer) { CfgScriptRef script = new CfgScriptRef (); // Get the symbol id for the rule script._idRule = symbols.Find (_rule); script._method = _method; script._idMethod = _idSymbol; System.Diagnostics.Debug.Assert (script._idRule != -1 && script._idMethod != -1); streamBuffer.WriteStream (script); } internal static string OnInitMethod (ScriptRef [] scriptRefs, string rule) { if (scriptRefs != null) { foreach (ScriptRef script in scriptRefs) { if (script._rule == rule && script._method == RuleMethodScript.onInit) { return script._sMethod; } } } return null; } #endregion //******************************************************************* // // Internal Fields // //******************************************************************** #region Internal Fields internal string _rule; internal string _sMethod; internal RuleMethodScript _method; internal int _idSymbol; #endregion } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //// Copyright (c) Microsoft Corporation. All rights reserved. // // // // Description: // // History: // 6/1/2004 jeanfp Created //----------------------------------------------------------------------------using System; using System.Diagnostics; using System.Speech.Internal.SrgsParser; namespace System.Speech.Internal.SrgsCompiler { ////// Summary description for ScriptRef. /// // list of rules with scripts #if VSCOMPILE [DebuggerDisplay ("rule=\"{_rule}\" method=\"{_sMethod}\" operation=\"{_method.ToString ()}\"")] #endif internal class ScriptRef { //******************************************************************* // // Constructors // //******************************************************************* #region Constructors internal ScriptRef (string rule, string sMethod, RuleMethodScript method) { _rule = rule; _sMethod = sMethod; _method = method; } #endregion //******************************************************************* // // Internal Methods // //******************************************************************** #region internal Methods internal void Serialize (StringBlob symbols, StreamMarshaler streamBuffer) { CfgScriptRef script = new CfgScriptRef (); // Get the symbol id for the rule script._idRule = symbols.Find (_rule); script._method = _method; script._idMethod = _idSymbol; System.Diagnostics.Debug.Assert (script._idRule != -1 && script._idMethod != -1); streamBuffer.WriteStream (script); } internal static string OnInitMethod (ScriptRef [] scriptRefs, string rule) { if (scriptRefs != null) { foreach (ScriptRef script in scriptRefs) { if (script._rule == rule && script._method == RuleMethodScript.onInit) { return script._sMethod; } } } return null; } #endregion //******************************************************************* // // Internal Fields // //******************************************************************** #region Internal Fields internal string _rule; internal string _sMethod; internal RuleMethodScript _method; internal int _idSymbol; #endregion } } // 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
- CapabilitiesAssignment.cs
- MetadataItemSerializer.cs
- ThreadAbortException.cs
- SymLanguageVendor.cs
- PropertyDescriptorComparer.cs
- SQLByteStorage.cs
- listitem.cs
- TimeSpanMinutesOrInfiniteConverter.cs
- FigureParagraph.cs
- MessageBox.cs
- PasswordTextContainer.cs
- Transform.cs
- SpellerHighlightLayer.cs
- ApplicationTrust.cs
- XPathNavigator.cs
- HandleValueEditor.cs
- keycontainerpermission.cs
- XslTransform.cs
- Message.cs
- TransactionScope.cs
- MatrixTransform3D.cs
- SqlProviderManifest.cs
- OutgoingWebResponseContext.cs
- DataSysAttribute.cs
- URL.cs
- ExtractorMetadata.cs
- HostingMessageProperty.cs
- UserControl.cs
- StreamInfo.cs
- ViewSimplifier.cs
- TabControlAutomationPeer.cs
- AuthorizationRuleCollection.cs
- ObservableDictionary.cs
- SqlDataRecord.cs
- XmlSequenceWriter.cs
- AssemblyUtil.cs
- XmlBinaryReaderSession.cs
- AddInActivator.cs
- EntityFunctions.cs
- _LazyAsyncResult.cs
- TimeEnumHelper.cs
- ResXResourceSet.cs
- unitconverter.cs
- BitConverter.cs
- UrlMapping.cs
- Input.cs
- CustomAttributeFormatException.cs
- EntryIndex.cs
- HierarchicalDataBoundControlAdapter.cs
- SharedUtils.cs
- DataBoundControlHelper.cs
- ServiceProviders.cs
- NamespaceQuery.cs
- XmlNodeReader.cs
- isolationinterop.cs
- Utils.cs
- NameValueConfigurationElement.cs
- AudioFormatConverter.cs
- DESCryptoServiceProvider.cs
- WrapPanel.cs
- DocumentSchemaValidator.cs
- MouseActionValueSerializer.cs
- Transactions.cs
- IndexingContentUnit.cs
- DataGridHeaderBorder.cs
- FontStretchConverter.cs
- TokenizerHelper.cs
- DesignSurfaceEvent.cs
- StringUtil.cs
- DNS.cs
- PageThemeCodeDomTreeGenerator.cs
- DictationGrammar.cs
- EdmToObjectNamespaceMap.cs
- GenericUriParser.cs
- XmlSignificantWhitespace.cs
- XDeferredAxisSource.cs
- NewExpression.cs
- Point3DConverter.cs
- ResourceWriter.cs
- Thickness.cs
- OLEDB_Util.cs
- VirtualPathData.cs
- OleDbConnectionInternal.cs
- ProcessHostConfigUtils.cs
- ButtonFlatAdapter.cs
- UiaCoreApi.cs
- ChtmlSelectionListAdapter.cs
- InvokeWebService.cs
- ValidationHelper.cs
- ProxyWebPartConnectionCollection.cs
- Site.cs
- RadioButtonRenderer.cs
- RtfToken.cs
- CommonProperties.cs
- SynchronizationLockException.cs
- PasswordRecovery.cs
- ellipse.cs
- StylusPointPropertyInfoDefaults.cs
- InterleavedZipPartStream.cs
- ListBox.cs