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
- GatewayDefinition.cs
- DateTimeOffset.cs
- DefaultValidator.cs
- HandlerMappingMemo.cs
- ExtenderControl.cs
- FontCacheLogic.cs
- TakeOrSkipWhileQueryOperator.cs
- DBAsyncResult.cs
- AssertSection.cs
- SqlDataReaderSmi.cs
- AuthenticationModuleElementCollection.cs
- ObjectDataSourceDisposingEventArgs.cs
- ToolBar.cs
- SqlComparer.cs
- CSharpCodeProvider.cs
- CodeMethodReturnStatement.cs
- ZipIOCentralDirectoryFileHeader.cs
- XpsSerializerWriter.cs
- SafeLocalMemHandle.cs
- OdbcConnectionStringbuilder.cs
- DrawingContextDrawingContextWalker.cs
- MediaPlayerState.cs
- CompositeActivityCodeGenerator.cs
- ParentQuery.cs
- CodeAttributeDeclarationCollection.cs
- DetailsViewRowCollection.cs
- RTLAwareMessageBox.cs
- ItemsPanelTemplate.cs
- HttpDictionary.cs
- Int32KeyFrameCollection.cs
- EnumerableCollectionView.cs
- XslCompiledTransform.cs
- StreamGeometryContext.cs
- ProxyHelper.cs
- DSASignatureDeformatter.cs
- _ConnectionGroup.cs
- XPathException.cs
- UIElementHelper.cs
- Registry.cs
- SQLDecimal.cs
- SqlOuterApplyReducer.cs
- NativeMethods.cs
- HotSpotCollection.cs
- HtmlWindowCollection.cs
- VectorAnimation.cs
- WmpBitmapDecoder.cs
- ZoneButton.cs
- TokenizerHelper.cs
- XmlSchemaSubstitutionGroup.cs
- QilFunction.cs
- TransformCollection.cs
- IteratorFilter.cs
- SectionRecord.cs
- TraceUtils.cs
- InkPresenterAutomationPeer.cs
- DataGridViewAddColumnDialog.cs
- RegexCharClass.cs
- MessageBox.cs
- WeakReferenceList.cs
- DataTablePropertyDescriptor.cs
- HtmlProps.cs
- SafeRightsManagementEnvironmentHandle.cs
- PerformanceCounterCategory.cs
- RecognizerBase.cs
- StrokeNodeData.cs
- ExpressionVisitor.cs
- DataColumnChangeEvent.cs
- ComAdminWrapper.cs
- ArrayConverter.cs
- CompositeActivityTypeDescriptorProvider.cs
- SectionUpdates.cs
- ComplexObject.cs
- DynamicDiscoSearcher.cs
- mediaeventargs.cs
- AdornerDecorator.cs
- ColorMatrix.cs
- DataSpaceManager.cs
- StringResourceManager.cs
- DesignerLoader.cs
- SettingsSection.cs
- ImageEditor.cs
- XhtmlBasicValidationSummaryAdapter.cs
- Utils.cs
- IndentedWriter.cs
- TreeViewDataItemAutomationPeer.cs
- FixedTextView.cs
- InputBindingCollection.cs
- SchemaInfo.cs
- ClonableStack.cs
- ComponentCodeDomSerializer.cs
- HighlightVisual.cs
- InputLanguageProfileNotifySink.cs
- HttpModuleAction.cs
- GatewayIPAddressInformationCollection.cs
- CollectionContainer.cs
- EncoderBestFitFallback.cs
- FontInfo.cs
- EmbeddedMailObject.cs
- DataViewListener.cs
- Stack.cs