Code:
/ FXUpdate3074 / FXUpdate3074 / 1.1 / DEVDIV / depot / DevDiv / releases / whidbey / QFE / ndp / fx / src / xsp / System / Web / Util / counter.cs / 1 / counter.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.Util { using System; using System.Web; using System.Runtime.InteropServices; ////// internal sealed class Counter { ///Provides access to system timers. ////// not creatable /// private Counter() { } #if UNUSED_CODE internal static float Time(long start) { long time = Value - start; return time / (float)Frequency; } #endif ////// Gets the current system counter value. /// internal static long Value { get { long count = 0; SafeNativeMethods.QueryPerformanceCounter(ref count); return count; } } ////// Gets the frequency of the system counter in counts per second. /// internal static long Frequency { get { long freq = 0; SafeNativeMethods.QueryPerformanceFrequency(ref freq); return freq; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.Util { using System; using System.Web; using System.Runtime.InteropServices; ////// internal sealed class Counter { ///Provides access to system timers. ////// not creatable /// private Counter() { } #if UNUSED_CODE internal static float Time(long start) { long time = Value - start; return time / (float)Frequency; } #endif ////// Gets the current system counter value. /// internal static long Value { get { long count = 0; SafeNativeMethods.QueryPerformanceCounter(ref count); return count; } } ////// Gets the frequency of the system counter in counts per second. /// internal static long Frequency { get { long freq = 0; SafeNativeMethods.QueryPerformanceFrequency(ref freq); return freq; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- LocalBuilder.cs
- FixUpCollection.cs
- listitem.cs
- CustomAttributeFormatException.cs
- WithParamAction.cs
- OutputCacheSettings.cs
- ServiceDebugElement.cs
- Hashtable.cs
- CodeAttributeDeclarationCollection.cs
- XhtmlStyleClass.cs
- HttpCacheVaryByContentEncodings.cs
- CellIdBoolean.cs
- DoubleAnimationClockResource.cs
- EmbeddedObject.cs
- precedingquery.cs
- ListViewTableCell.cs
- MaskedTextBox.cs
- SpecialFolderEnumConverter.cs
- WSFederationHttpSecurityElement.cs
- CheckBoxAutomationPeer.cs
- TextAction.cs
- RowType.cs
- HtmlShim.cs
- ButtonFieldBase.cs
- BinHexDecoder.cs
- ObjectTag.cs
- WebPartMovingEventArgs.cs
- PtsHost.cs
- QuadraticBezierSegment.cs
- WmlTextViewAdapter.cs
- CallbackValidatorAttribute.cs
- HandledMouseEvent.cs
- DiscoveryDocumentSerializer.cs
- AssemblyResourceLoader.cs
- Brushes.cs
- ObjectDataSourceSelectingEventArgs.cs
- PrefixQName.cs
- HandlerBase.cs
- ScaleTransform3D.cs
- GC.cs
- DesignerTransaction.cs
- SettingsPropertyCollection.cs
- MetadataHelper.cs
- TableLayoutStyleCollection.cs
- DBSqlParserColumn.cs
- SecurityDocument.cs
- ToolStripContainerActionList.cs
- RenderOptions.cs
- TransformerInfoCollection.cs
- ScriptResourceAttribute.cs
- UserPrincipalNameElement.cs
- RecordManager.cs
- SecurityTokenSerializer.cs
- Effect.cs
- FieldNameLookup.cs
- CellTreeNodeVisitors.cs
- PageCache.cs
- RecognizedPhrase.cs
- XsdValidatingReader.cs
- DataGridViewColumn.cs
- FontStyle.cs
- SqlDataSourceCache.cs
- ConfigurationManagerHelperFactory.cs
- UDPClient.cs
- GACIdentityPermission.cs
- HttpResponseInternalWrapper.cs
- ExceptionUtil.cs
- CodeAttributeDeclarationCollection.cs
- EventsTab.cs
- SimpleTableProvider.cs
- BitmapEffectGeneralTransform.cs
- HwndTarget.cs
- XPathArrayIterator.cs
- BitmapMetadataBlob.cs
- BaseDataBoundControlDesigner.cs
- TemplatePagerField.cs
- UITypeEditor.cs
- DataGridViewCellFormattingEventArgs.cs
- DataRelationCollection.cs
- SigningCredentials.cs
- DesignRelation.cs
- HttpResponse.cs
- SetterBase.cs
- OdbcEnvironmentHandle.cs
- PropertyCollection.cs
- IPipelineRuntime.cs
- WindowsFormsLinkLabel.cs
- ThreadAbortException.cs
- ImageMap.cs
- EncryptedData.cs
- NullableFloatMinMaxAggregationOperator.cs
- XmlSchemaCompilationSettings.cs
- ActiveXMessageFormatter.cs
- EndOfStreamException.cs
- ChildrenQuery.cs
- EventToken.cs
- Privilege.cs
- TextAnchor.cs
- InitializerFacet.cs
- ThreadPool.cs