Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / 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; } } } }
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- CodeNamespace.cs
- ObjectIDGenerator.cs
- Qualifier.cs
- CompilationSection.cs
- AppSettingsReader.cs
- XmlSchemaParticle.cs
- DesignerOptions.cs
- FileEnumerator.cs
- DecimalStorage.cs
- XPathAncestorQuery.cs
- Update.cs
- Simplifier.cs
- LogLogRecordEnumerator.cs
- DataControlLinkButton.cs
- GraphicsPath.cs
- PeerDuplexChannelListener.cs
- DateTimeUtil.cs
- MimeMapping.cs
- EnvelopedPkcs7.cs
- ResXBuildProvider.cs
- SeverityFilter.cs
- ProtocolViolationException.cs
- EntityKeyElement.cs
- StrongNameUtility.cs
- ReadOnlyCollection.cs
- DataFieldConverter.cs
- Config.cs
- ProxyManager.cs
- StringFormat.cs
- WindowsIdentity.cs
- oledbconnectionstring.cs
- WsdlExporter.cs
- VoiceChangeEventArgs.cs
- ScaleTransform.cs
- StylusPointProperties.cs
- TimeZoneInfo.cs
- BindingCompleteEventArgs.cs
- SystemIcmpV6Statistics.cs
- CallTemplateAction.cs
- Light.cs
- SQLSingle.cs
- SplayTreeNode.cs
- CacheVirtualItemsEvent.cs
- ScrollData.cs
- FileLevelControlBuilderAttribute.cs
- DetailsViewDeletedEventArgs.cs
- EmptyEnumerator.cs
- SqlNode.cs
- DrawingContext.cs
- HttpHeaderCollection.cs
- ipaddressinformationcollection.cs
- JavascriptCallbackMessageInspector.cs
- ListManagerBindingsCollection.cs
- PerformanceCounterPermissionEntryCollection.cs
- TraceXPathNavigator.cs
- CalendarDataBindingHandler.cs
- ClientBuildManager.cs
- CustomLineCap.cs
- ChangeConflicts.cs
- XmlCompatibilityReader.cs
- ImageConverter.cs
- SingleStorage.cs
- ClrProviderManifest.cs
- Deserializer.cs
- ToolStripRenderEventArgs.cs
- CultureNotFoundException.cs
- GlobalAllocSafeHandle.cs
- ISAPIRuntime.cs
- RootAction.cs
- BufferAllocator.cs
- FormDocumentDesigner.cs
- TreeWalker.cs
- ColorDialog.cs
- PointF.cs
- ModifierKeysConverter.cs
- TimeoutHelper.cs
- ComponentResourceKey.cs
- ImageMap.cs
- SessionParameter.cs
- FormatterServices.cs
- FaultHandlingFilter.cs
- MultiBindingExpression.cs
- BitmapSizeOptions.cs
- ModuleConfigurationInfo.cs
- DataConnectionHelper.cs
- ActivityDesignerHighlighter.cs
- QuotedPrintableStream.cs
- BitmapMetadataEnumerator.cs
- RootProfilePropertySettingsCollection.cs
- SecurityPermission.cs
- ObjectQueryExecutionPlan.cs
- DispatchRuntime.cs
- CalendarAutoFormatDialog.cs
- GPRECTF.cs
- MailSettingsSection.cs
- SafeNativeMethodsOther.cs
- XamlSerializerUtil.cs
- SByteStorage.cs
- RijndaelManaged.cs
- MulticastNotSupportedException.cs