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 / GrammarBuilding / OneOfElement.cs / 1 / OneOfElement.cs
//------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------- using System.Diagnostics; using System.Speech.Recognition; using System.Speech.Internal.SrgsParser; using System.Text; namespace System.Speech.Internal.GrammarBuilding { #if VSCOMPILE [DebuggerDisplay ("{DebugSummary}")] #endif internal sealed class OneOfElement : BuilderElements { //******************************************************************* // // Constructors // //******************************************************************* #region Constructors internal OneOfElement () { } #endregion //******************************************************************** // // Internal Methods // //******************************************************************* #region Internal Methods ////// /// ///internal override GrammarBuilderBase Clone () { OneOfElement oneOf = new OneOfElement (); oneOf.CloneItems (this); return oneOf; } /// /// /// /// /// /// /// ///internal override IElement CreateElement (IElementFactory elementFactory, IElement parent, IRule rule, IdentifierCollection ruleIds) { // Create and return the IOneOf representing the current object IOneOf oneOf = elementFactory.CreateOneOf (parent, rule); foreach (GrammarBuilderBase item in Items) { ItemElement newItem = item as ItemElement; if (newItem == null) { newItem = new ItemElement (item); } IItem element = (IItem) newItem.CreateElement (elementFactory, oneOf, rule, ruleIds); element.PostParse (oneOf); elementFactory.AddItem (oneOf, element); } return oneOf; } #endregion //******************************************************************** // // Internal Properties // //******************************************************************** #region Internal Properties override internal string DebugSummary { get { StringBuilder sb = new StringBuilder (); foreach (GrammarBuilderBase item in Items) { if (sb.Length > 0) { sb.Append (","); } sb.Append (item.DebugSummary); } return "[" + sb.ToString () + "]"; } } #endregion } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------ // // Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------- using System.Diagnostics; using System.Speech.Recognition; using System.Speech.Internal.SrgsParser; using System.Text; namespace System.Speech.Internal.GrammarBuilding { #if VSCOMPILE [DebuggerDisplay ("{DebugSummary}")] #endif internal sealed class OneOfElement : BuilderElements { //******************************************************************* // // Constructors // //******************************************************************* #region Constructors internal OneOfElement () { } #endregion //******************************************************************** // // Internal Methods // //******************************************************************* #region Internal Methods ////// /// ///internal override GrammarBuilderBase Clone () { OneOfElement oneOf = new OneOfElement (); oneOf.CloneItems (this); return oneOf; } /// /// /// /// /// /// /// ///internal override IElement CreateElement (IElementFactory elementFactory, IElement parent, IRule rule, IdentifierCollection ruleIds) { // Create and return the IOneOf representing the current object IOneOf oneOf = elementFactory.CreateOneOf (parent, rule); foreach (GrammarBuilderBase item in Items) { ItemElement newItem = item as ItemElement; if (newItem == null) { newItem = new ItemElement (item); } IItem element = (IItem) newItem.CreateElement (elementFactory, oneOf, rule, ruleIds); element.PostParse (oneOf); elementFactory.AddItem (oneOf, element); } return oneOf; } #endregion //******************************************************************** // // Internal Properties // //******************************************************************** #region Internal Properties override internal string DebugSummary { get { StringBuilder sb = new StringBuilder (); foreach (GrammarBuilderBase item in Items) { if (sb.Length > 0) { sb.Append (","); } sb.Append (item.DebugSummary); } return "[" + sb.ToString () + "]"; } } #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
- ValidationHelper.cs
- PackageStore.cs
- DocumentGridPage.cs
- DirectionalLight.cs
- ByteRangeDownloader.cs
- CacheEntry.cs
- IssuedTokenParametersElement.cs
- PreProcessor.cs
- WindowsRichEditRange.cs
- XmlMemberMapping.cs
- TemplateXamlParser.cs
- Filter.cs
- WebPartEditorOkVerb.cs
- MetafileHeader.cs
- ServiceContractDetailViewControl.cs
- contentDescriptor.cs
- XamlBuildTaskServices.cs
- VisualTreeUtils.cs
- WindowsFormsDesignerOptionService.cs
- DispatchChannelSink.cs
- SessionStateContainer.cs
- StructuralObject.cs
- DbCommandDefinition.cs
- CompModSwitches.cs
- ComboBoxItem.cs
- NetNamedPipeBindingElement.cs
- DesigntimeLicenseContext.cs
- ObjectDataSourceSelectingEventArgs.cs
- RecordBuilder.cs
- Separator.cs
- BuildProvider.cs
- TextDecorationLocationValidation.cs
- ListDictionaryInternal.cs
- CodeCastExpression.cs
- CatalogPartChrome.cs
- BulletedList.cs
- NonVisualControlAttribute.cs
- Rectangle.cs
- TextAction.cs
- Polygon.cs
- GridViewPageEventArgs.cs
- ConfigUtil.cs
- UIElementHelper.cs
- SystemBrushes.cs
- SqlLiftIndependentRowExpressions.cs
- PrintDialog.cs
- IDQuery.cs
- BindingEditor.xaml.cs
- ISAPIApplicationHost.cs
- SessionStateContainer.cs
- StorageRoot.cs
- CompositeClientFormatter.cs
- EventHandlersDesigner.cs
- CodeGroup.cs
- FacetValues.cs
- ParameterDataSourceExpression.cs
- _ListenerResponseStream.cs
- BrowserCapabilitiesCompiler.cs
- StringReader.cs
- SystemWebCachingSectionGroup.cs
- ResourceReferenceExpression.cs
- XamlPointCollectionSerializer.cs
- ScriptModule.cs
- XmlPreloadedResolver.cs
- DataGridItem.cs
- DiscoveryClientDocuments.cs
- EventLogEntry.cs
- ServiceXNameTypeConverter.cs
- GeneralTransform3DGroup.cs
- ExtendedPropertyInfo.cs
- FixedElement.cs
- CompoundFileReference.cs
- SourceFileBuildProvider.cs
- EnumDataContract.cs
- ServiceEndpointAssociationProvider.cs
- DecodeHelper.cs
- AppSettingsExpressionEditor.cs
- NotifyIcon.cs
- DesignerAttribute.cs
- InkCanvasAutomationPeer.cs
- EntityClassGenerator.cs
- AppDomainShutdownMonitor.cs
- HtmlTableCellCollection.cs
- FormClosedEvent.cs
- InputLangChangeEvent.cs
- TemplateEditingVerb.cs
- PageAsyncTask.cs
- MultipleViewProviderWrapper.cs
- xdrvalidator.cs
- ObjectConverter.cs
- Label.cs
- Configuration.cs
- QueryAsyncResult.cs
- DataServiceCollectionOfT.cs
- WebPartCloseVerb.cs
- Mapping.cs
- FillBehavior.cs
- DetailsViewCommandEventArgs.cs
- UpdatePanelControlTrigger.cs
- AttachedPropertyDescriptor.cs