C#??????????????10???????????
???????????? ???????[ 2015/11/12 14:57:35 ] ??????????????????? ?????
????9 ??ü????????????????
????????????Щ??????????????????StopWatch???????δ????????????????????????
????System.Diagnostics.Stopwatch timer = new System.Diagnostics.Stopwatch();
????timer.Start();
????Decimal total = 0;
????int limit = 1000000;
????for (int i = 0; i < limit; ++i)
????{
????total = total + (Decimal)Math.Sqrt(i);
????}
????timer.Stop();
????Console.WriteLine(“Sum of sqrts: {0}”??total);
????Console.WriteLine(“Elapsed milliseconds: {0}”??
????timer.ElapsedMilliseconds);
????Console.WriteLine(“Elapsed time: {0}”?? timer.Elapsed);
??????????????????????????????????????????????????????????dotNetPerformance?????
????????????????????????????????????????????????????????Щ????????ο???????????
????class AutoStopwatch : System.Diagnostics.Stopwatch?? IDisposable
????{
????public AutoStopwatch()
????{
????Start();
????}
????public void Dispose()
????{
????Stop();
????Console.WriteLine(“Elapsed: {0}”?? this.Elapsed);
????}
????}
??????????using???????????????????????????δ?????????????????????????
????using (new AutoStopwatch())
????{
????Decimal total2 = 0;
????int limit2 = 1000000;
????for (int i = 0; i < limit2; ++i)
????{
????total2 = total2 + (Decimal)Math.Sqrt(i);
????}
????}
????10 ??ù??
???????????????????б??????????????????????????????μ??????????????ɡ?
????class AutoWaitCursor : IDisposable
????{
????private Control _target;
????private Cursor _prevCursor = Cursors.Default;
????public AutoWaitCursor(Control control)
????{
????if (control == null)
????{
????throw new ArgumentNullException(“control”);
????}
????_target = control;
????_prevCursor = _target.Cursor;
????_target.Cursor = Cursors.WaitCursor;
????}
????public void Dispose()
????{
????_target.Cursor = _prevCursor;
????}
????}
?????÷?????????????д??????????????????????????
????using (new AutoWaitCursor(this))
????{
????...
????throw new Exception();
????}
????????????????????????????????????????????
???????????????????????漰???????????????????SPASVOС??(021-61079698-8054)?????????????????????????
??????
???????C#?е?StringC# Socket???????????????????C#?????????????????????????C#???????C#????????????Log4net??????δ????C#?????????????C#?????????????????C#???????????????C#????????????????C#7 ?е?Tuple??????C#??TypeScript - GeneratorC# ?????????細(xì)??????????C#?е???н???C#??MySQL?????????μ??Ч?????д??C#????C++??dll???C#??VS2010????е??????
???·???
??????????????????
2023/3/23 14:23:39???д?ò??????????
2023/3/22 16:17:39????????????????????Щ??
2022/6/14 16:14:27??????????????????????????
2021/10/18 15:37:44???????????????
2021/9/17 15:19:29???·???????·
2021/9/14 15:42:25?????????????
2021/5/28 17:25:47??????APP??????????
2021/5/8 17:01:11????????
?????????App Bug???????????????????????Jmeter?????????QC??????APP????????????????app?????е????????jenkins+testng+ant+webdriver??????????????JMeter????HTTP???????Selenium 2.0 WebDriver ??????