misbaharefin

Stories kicked by misbaharefin

Dependency Injection in ASP.NET MVC3(itworksonmymachine.wordpress.com)

submitted by misbaharefinmisbaharefin(845) 1 year, 3 months ago

What dependency injection means is that instead of writing code like this in your controller private IBlogService _BlogService; public BlogController() { _BlogService = new BlogService(); } you write code like this private IBlogService _BlogService; public BlogController(IBlogService blogService) { _BlogService = blogService; } the benefits of dependency injection are your classes are not tightly coupled, are more testable, and really is pluggable. To enable dependency injection into your controllers in ASP.NET MVC2 you had to create a new class derived from DefaultControllerFactory and override the GetControllerInstance method to create the controller using your dependency injection container e.g. read more...

add a comment |category: |Views: 21

tags: another

Aspect-Oriented Programming vs Dependency Injection(www.sharpcrafters.com)

submitted by gfraiteurgfraiteur(988) 1 year, 5 months ago

Aspect-Oriented Programming and Dependency Injection are very different concepts, but there are limited cases where they fit well together. In these situations, using the AOP facility of a DI framework makes perfect sense. For other cases you have two options: abuse from dynamic proxies (a non-solution), or use of a dedicated AOP framework. read more...

add a comment |category: |Views: 108

tags: another

Free E-Books From Microsoft Press(www.myanmarasp.net)

submitted by cmmaungcmmaung(133) 1 year, 5 months ago

Microsoft Press has released several E-Books that people can download and get started with, I will list them with a short synopsis so that people can go and download the books that interest them. read more...

add a comment |category: |Views: 86

tags: another

Slash your ASP.NET compile/load time without any hard work(blog.lavablast.com)

submitted by EtienneTremblayEtienneTremblay(5008) 1 year, 5 months ago

Tips & tricks to make your ASP.NET development more enjoyable (cut down compilation time / first load time). read more...

add a comment |category: |Views: 721

tags: another

Using ModelMetaData in MVC 2 to wire up sweet jQuery awesomeness(www.lostechies.com)

submitted by misbaharefinmisbaharefin(845) 1 year, 7 months ago

I recently came up with an approach to wiring up some jquery plugins that modify the behavior of standard input text boxes. The approach is not original by any means.I got the idea from the built in client side validation for MVC2, which was inspired by Steve Sanderson's xVal framework. read more...

add a comment |category: |Views: 164

tags: another

Cool site of the day: extensionmethod.net(www.lostechies.com)

submitted by misbaharefinmisbaharefin(845) 1 year, 7 months ago

I was in a meeting today and the topic of extension methods was discussed. I'm a big fan of LINQ - which at the end of the day - is a collection of extension methods on IEnumerable and IEnumerable<T>. I use LINQ all of the time - but I have to profess - I probably don't utilize extension methods as a way of implementing behaviors as much as I should. Looking around the web tonight, I found this site: http://www.extensionmethod.net/. Looks like a nice clearinghouse for extension methods. Next time, before rolling your own, check out this site. Quite likely, somebody else has solved the problem for you. And - you'll likely pick up some good tips!! read more...

add a comment |category: |Views: 3

tags: another

Practically Applying Design Patterns - Part I and II(amazedsaint.blogspot.com)

submitted by amazedsaintamazedsaint(835) 1 year, 7 months ago

Explains the thought process behind applying design patterns read more...

add a comment |category: |Views: 384

tags: another

Attributes Every .NET Developer Should Know About(www.devcurry.com)

submitted by bungleboozbunglebooz(1132) 1 year, 7 months ago

Here’s a list of important .NET attributes that is commonly used in projects and proves very useful if you about them beforehand read more...

add a comment |category: |Views: 1050

tags: another

Ten Caching mistakes that break your app(omaralzabir.com)

submitted by oazabiroazabir(1805) 1 year, 7 months ago

Caching frequently used objects, that are expensive to fetch from the source, makes application perform faster under high load. It helps scale an application under concurrent requests. But some hard to notice mistakes can lead the application to suffer under high load, let alone making it perform better, especially when you are using distributed caching where there’s separate cache server or cache application that stores the items. Moreover, code that works fine using in-memory cache can fail when the cache is made out-of-process. Here I will show you some common distributed caching mistakes that will help you make better decision when to cache and when not to cache. read more...

add a comment |category: |Views: 189

tags: another

Getting rid of null checks in property chains with - but not limited t(bit.ly)

submitted by sandordsandord(140) 1 year, 9 months ago

This article explains how to get rid of the annoying null checks you often have to do before you can evaluate expressions like Order.Customer.Address.ZipCode safely. The provided code builds and compiles an expression tree that does the job in an elegant and well performing manner. Specific extension methods for AutoMapper and S#arpArchitecture are provided as well. read more...

add a comment |category: |Views: 556

tags: another

Using delegates to eliminate duplicate code(alexdresko.com)

submitted by alexdreskoalexdresko(25) 1 year, 9 months ago

Here’s a simple technique you can use to easily eliminate duplicate code. Try not to let the word “delegates” scare you away from learning the technique and I’ll try to refrain from using the word “delegate” as much as possible. I’ll start small and then work my way towards a more complex example that really demonstrates its power. read more...

add a comment |category: |Views: 37

tags: another

Simplify, Shorten and Speed Up Your LINQ Statements with "Let"(blog.nitriq.com)

submitted by viggityviggity(1124) 2 years ago

Details how using the "let" keyword can make your LINQ statements shorter and faster. read more...

add a comment |category: |Views: 675

tags: another

IQueryable Can Kill Your Dog, Steal Your Wife, Kill Your Will To Live,(www.weirdlover.com)

submitted by evannevann(219) 2 years ago

If you take a quick detour over to StackOverflow, you’ll realize very, very quickly that, when it comes to wholly and full-heartedly screwing up your Linq to SQL statements, the screw-up almost always involves a misunderstanding of the purpose and... read more...

add a comment |category: |Views: 841

tags: another

Download Free ebook - Introducing Microsoft SQL Server 2008 R2(beyondrelational.com)

submitted by jacobsebastianjacobsebastian(3639) 2 years, 1 month ago

Introducing Microsoft SQL Server 2008 R2 is a 10 chapter, 216 page book writtenby Ross Mistry and Stacia Misner. Microsoft has made it available as a free ebook read more...

3 comments |category: |Views: 450

tags: another

How to send mail asynchronously in asp.net (jalpesh.blogspot.com)

submitted by jalpeshjalpesh(1347) 2 years, 3 months ago

With Microsoft.NET Framework 2.0 everything is asynchronous and we can send mail also asynchronously. This features is very useful when you send lots of bulk mails like news letter. You don’t have to wait for response from mail server and you can do other task . Let's create a simple example to send mail. For sending mail asynchronously you need to create a event handler that will notify that mail successfully sent or some errors occurred during sending mail. Let’s create a mail object and then we will send it asynchronously. You will require System.Net.Mail space to import in your page to send mail. read more...

add a comment |category: |Views: 27

tags: another

Cartoon. Tetris development(hacktoons.com)

submitted by miniscrumminiscrum(138) 2 years, 3 months ago

Next comic strip about programmers' fail. Guess what's wrong before reading the notes? read more...

add a comment |category: |Views: 507

tags: another