Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / 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
- XsdDuration.cs
- DefaultShape.cs
- Content.cs
- QueryContinueDragEventArgs.cs
- SelectionEditingBehavior.cs
- FormViewRow.cs
- CachedPathData.cs
- QilStrConcat.cs
- UserNamePasswordValidator.cs
- SqlBulkCopyColumnMappingCollection.cs
- EncodingNLS.cs
- SqlSupersetValidator.cs
- IPPacketInformation.cs
- MenuAutomationPeer.cs
- SortedDictionary.cs
- PlatformCulture.cs
- WebControlAdapter.cs
- UnicodeEncoding.cs
- CachedBitmap.cs
- CompatibleIComparer.cs
- InstrumentationTracker.cs
- RoleGroupCollectionEditor.cs
- HttpCookie.cs
- SuppressMessageAttribute.cs
- XmlElementList.cs
- Point.cs
- DesignRelation.cs
- ResourceContainer.cs
- CompositeKey.cs
- StorageRoot.cs
- ListViewItem.cs
- SessionEndedEventArgs.cs
- TranslateTransform.cs
- FaultPropagationQuery.cs
- ExpressionTextBox.xaml.cs
- Thread.cs
- CompiledQueryCacheKey.cs
- ProfileSettingsCollection.cs
- NativeMethods.cs
- ProgressBarHighlightConverter.cs
- DelayLoadType.cs
- TimeStampChecker.cs
- RowBinding.cs
- WizardStepBase.cs
- FontInfo.cs
- AttributeAction.cs
- TreeViewBindingsEditor.cs
- TableLayoutPanel.cs
- PageVisual.cs
- UnsafeNativeMethods.cs
- Cursor.cs
- ExpressionBuilderContext.cs
- XmlSchemaSimpleTypeList.cs
- StaticContext.cs
- CatalogPartChrome.cs
- EndpointDispatcher.cs
- GridViewSortEventArgs.cs
- TextFindEngine.cs
- DocumentGridContextMenu.cs
- DataGridViewColumn.cs
- EventLogEntryCollection.cs
- ListBox.cs
- DiagnosticTraceSource.cs
- BlurEffect.cs
- _CacheStreams.cs
- RepeatInfo.cs
- handlecollector.cs
- DataSysAttribute.cs
- CursorConverter.cs
- Validator.cs
- ColorTransform.cs
- XmlElementList.cs
- RelationshipSet.cs
- MappingMetadataHelper.cs
- WebResourceUtil.cs
- RadioButtonBaseAdapter.cs
- SourceFilter.cs
- ThreadPool.cs
- TypeToken.cs
- DataBoundControlHelper.cs
- StoreAnnotationsMap.cs
- SourceItem.cs
- DataGridViewCellCollection.cs
- FillRuleValidation.cs
- ConditionChanges.cs
- WebServiceData.cs
- PrimitiveType.cs
- EnumUnknown.cs
- WorkflowServiceHost.cs
- LostFocusEventManager.cs
- IgnoreFileBuildProvider.cs
- XslAstAnalyzer.cs
- ElementMarkupObject.cs
- EventToken.cs
- TrackingConditionCollection.cs
- ImageCollectionCodeDomSerializer.cs
- CodeAccessSecurityEngine.cs
- TypeExtensionSerializer.cs
- VisualTarget.cs
- WebPartConnectionCollection.cs