随笔分类 - 00.Net
摘要:压缩库为google提供的 Closure Compilerhttps://developers.google.com/closure/compiler/?hl=zh-cnusing System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Diagnostics;namespace TestProcessDosCmd{ class Program { static void Main(string[] args) { ...
阅读全文
摘要:http://www.quartz-scheduler.org/documentation/quartz-1.x/tutorials/crontrigger网上表达式生成器:http://www.cronmaker.com/Introductioncronis a UNIX tool that has been around for a long time, so its scheduling capabilities are powerful and proven. TheCronTriggerclass is based on the scheduling capabilities of
阅读全文
摘要:var container = new WindsorContainer();container.Register(Component.For<SauceBéarnaise>());SauceBéarnaise sauce = container.Resolve<SauceBéarnaise>();var container = new WindsorContainer();container.Register(Component.For<IIngredient>().ImplementedBy<SauceBéa
阅读全文
摘要:I recently wrote a post about how to set up CW’s IOC container for applications. This post covered the most basic implementation to get an IOC container up and running. It is now time to cover a proper architecture for using IOC specifically for web applications / sites.The main problem with the pre
阅读全文
摘要:from:http://mvcsharp.wordpress.com/2010/01/09/setting-up-ioc-in-asp-net-mvc-using-castle-windsor/Abstract: This post gathers information needed to setting up Inversion of Control (IoC) in an ASP.NET MVC application using Castle Windsor.Introduction: Inprevious postI summarized how ASP.NET MVC compon
阅读全文
摘要:http://msdn.microsoft.com/en-us/library/ms973868Global.asaxThe Global.asax file is similar to the Global.asa file in ASP, albeit that there are many more events available in ASP.NET. Also, Global.asax is compiled instead of interpreted as it is in ASP. You still have event procedures that fire withi
阅读全文
摘要:http://msdn.microsoft.com/en-us/library/system.data.sqlclient.sqlconnection.connectionstring(v=vs.80).aspxhttp://www.codeproject.com/Articles/17768/ADO-NET-Connection-Pooling-at-a-GlanceThe following table lists the valid names for connection pooling values within theConnectionString. For more infor
阅读全文
摘要:ASP.NET provides three primary forms of caching: page level output caching, user control level output caching (or fragment caching), and the Cache API. Output caching and fragment caching have the advantage of being incredibly simple to implement, and are sufficient in many cases. The cache API prov
阅读全文
摘要:This is not a new topic. But interestingly I could not find a good example on the web while I wanted to find one for some other investigation. So I decided to create a sample here to show the following scenario:A WCF service has the access to a ASP.NET session. Different WCF client proxies can conne
阅读全文
摘要:using System;using System.Threading;namespace InterlockedExchange_Example{ class MyInterlockedExchangeExampleClass { //0 for false, 1 for true. private static int usingResource = 0; private const int numThreadIterations = 5; private const int numThreads = 10; ...
阅读全文
摘要:http://msdn.microsoft.com/en-us/library/ff647790.aspx#scalenetchapt05_topic15Locking and synchronization provide a mechanism to grant exclusive access to data or code to avoid concurrent execution.This section summarizes steps to consider to help you approach locking and synchronization correctly:De
阅读全文
摘要:%comspec% /k ""d:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\vcvarsall.bat"" amd64msbuild MPTSBKW.Test1.sln /p:Configuration=Debug /p:Platform="Any CPU" /consoleloggerparameters:ErrorsOnlyMicrosoft (R) Build Engine Version 4.0.30319.1[Microsoft .NET Framework,
阅读全文
摘要:主页:http://ironpython.net/下载地址:http://ironpython.codeplex.com/开发工具VS2010插件:http://pytools.codeplex.com/
阅读全文
摘要:http://msdn.microsoft.com/en-us/library/e1f13641.aspxhttp://msdn.microsoft.com/en-us/library/h6bb9cz9.aspx<httpRuntime apartmentThreading = "[True|False]" appRequestQueueLimit = "number" delayNotificationTimeout = "number" enable = "[True|False]" enableHead
阅读全文
摘要:转:http://stackoverflow.com/questions/1826657/page-generation-time-asp-net-mvcpublic class PerformanceMonitorModule : IHttpModule{ public void Init(HttpApplication context) { context.PreRequestHandlerExecute += delegate(object sender, EventArgs e) { //Set Page Timer Sta...
阅读全文
摘要:http://cul.codeplex.com/Project DescriptionCraig's Utility Library (or CUL, as in cull because I'm not that creative), was initially designed through a number of projects that I've worked on. Over time I assembled a number of classes to handle various tasks and continue to add a number o
阅读全文