Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / XmlUtils / System / Xml / Xsl / XsltOld / TemplateBaseAction.cs / 1 / TemplateBaseAction.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //[....] //----------------------------------------------------------------------------- namespace System.Xml.Xsl.XsltOld { using Res = System.Xml.Utils.Res; using System; using System.Diagnostics; using System.Collections; using System.Xml; using System.Xml.XPath; using System.Globalization; // RootAction and TemplateActions have a litle in common -- they are responsible for variable allocation // TemplateBaseAction -- implenemts this shared behavior internal abstract class TemplateBaseAction : ContainerAction { protected int variableCount; // space to allocate on frame for variables private int variableFreeSlot; // compile time counter responsiable for variable placement logic public int AllocateVariableSlot() { // Variable placement logic. Optimized int thisSlot = this.variableFreeSlot; this.variableFreeSlot ++; if(this.variableCount < this.variableFreeSlot) { this.variableCount = this.variableFreeSlot; } return thisSlot; } public void ReleaseVariableSlots(int n) { // This code does optimisation of variable placement. Comented out for this version // Reuse of the variable disable the check that variable was assigned before the actual use // this check has to be done in compile time n future. // this.variableFreeSlot -= n; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //[....] //----------------------------------------------------------------------------- namespace System.Xml.Xsl.XsltOld { using Res = System.Xml.Utils.Res; using System; using System.Diagnostics; using System.Collections; using System.Xml; using System.Xml.XPath; using System.Globalization; // RootAction and TemplateActions have a litle in common -- they are responsible for variable allocation // TemplateBaseAction -- implenemts this shared behavior internal abstract class TemplateBaseAction : ContainerAction { protected int variableCount; // space to allocate on frame for variables private int variableFreeSlot; // compile time counter responsiable for variable placement logic public int AllocateVariableSlot() { // Variable placement logic. Optimized int thisSlot = this.variableFreeSlot; this.variableFreeSlot ++; if(this.variableCount < this.variableFreeSlot) { this.variableCount = this.variableFreeSlot; } return thisSlot; } public void ReleaseVariableSlots(int n) { // This code does optimisation of variable placement. Comented out for this version // Reuse of the variable disable the check that variable was assigned before the actual use // this check has to be done in compile time n future. // this.variableFreeSlot -= n; } } } // 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
- EntityClassGenerator.cs
- AdapterDictionary.cs
- ExpandedWrapper.cs
- EventEntry.cs
- HandleExceptionArgs.cs
- InvalidAsynchronousStateException.cs
- ContainerUtilities.cs
- SaveRecipientRequest.cs
- AliasGenerator.cs
- ByteAnimationBase.cs
- DataRow.cs
- ObjectDataProvider.cs
- TypeReference.cs
- ReadOnlyHierarchicalDataSource.cs
- DataKeyCollection.cs
- XmlLoader.cs
- PropertyDescriptorCollection.cs
- AnonymousIdentificationModule.cs
- NotImplementedException.cs
- ComPlusDiagnosticTraceSchemas.cs
- ContentPlaceHolder.cs
- ServerValidateEventArgs.cs
- TreeViewItem.cs
- Size3D.cs
- Model3D.cs
- OLEDB_Enum.cs
- XmlnsCache.cs
- Automation.cs
- SmiEventSink.cs
- WebHttpBehavior.cs
- Bidi.cs
- ConsoleKeyInfo.cs
- DataControlHelper.cs
- ResXBuildProvider.cs
- ImmutableCollection.cs
- ACE.cs
- DesignTimeTemplateParser.cs
- NameObjectCollectionBase.cs
- HTMLTextWriter.cs
- DynamicUpdateCommand.cs
- CheckBoxList.cs
- __TransparentProxy.cs
- BehaviorEditorPart.cs
- EntityDataSourceColumn.cs
- ValueProviderWrapper.cs
- Evidence.cs
- columnmapkeybuilder.cs
- SqlClientPermission.cs
- cookie.cs
- ImageIndexConverter.cs
- SocketException.cs
- Win32Exception.cs
- DBBindings.cs
- LocationUpdates.cs
- FileDialog_Vista.cs
- NativeMethods.cs
- URLAttribute.cs
- DoubleLinkList.cs
- DrawingAttributes.cs
- CellConstantDomain.cs
- HtmlWindowCollection.cs
- EventProxy.cs
- x509store.cs
- AstNode.cs
- MarginsConverter.cs
- KeyValuePairs.cs
- DigestComparer.cs
- Span.cs
- odbcmetadatacolumnnames.cs
- PeerInvitationResponse.cs
- RawMouseInputReport.cs
- PointUtil.cs
- View.cs
- CalendarDataBindingHandler.cs
- HashHelper.cs
- Transform3DGroup.cs
- ZoneButton.cs
- SQLInt64Storage.cs
- NameValuePair.cs
- DataGridViewTextBoxColumn.cs
- PrimitiveSchema.cs
- XPathNodePointer.cs
- AvTrace.cs
- XmlAnyElementAttributes.cs
- DesignerVerbCollection.cs
- ToolboxItemFilterAttribute.cs
- AuthorizationRuleCollection.cs
- Array.cs
- QueryExecutionOption.cs
- SemanticResultValue.cs
- AudioFileOut.cs
- HtmlTableCell.cs
- DataExpression.cs
- FileNotFoundException.cs
- FixedNode.cs
- Hyperlink.cs
- PageAction.cs
- CryptoConfig.cs
- CngUIPolicy.cs
- XsltConvert.cs