| |
browse.develop.com
Browse.develop.com is a community that was established to collect and
organize valuable web information. Our technical staff have selected and
indexed information and courses that they feel will help you stay
current on best practices across the SDLC.
|
7 Articles match "Public","Sample"
| Related DevelopMentor Courses | MORE | | Understanding Map - Reduce The Orders data structure looks like this: 1: public class Order. 3: public Order(). 7: 8: public int CustomerId { get; set; }. 9: public List Lines { get; set; }. 11: 12: public class OrderLine. 14: public string Book { get; set; }. 15: public int Quantity { get; set; }. 16: public decimal Price { get; set; }. We store that in the following structure: 1: public class ReducedTo. 3: public string Book { get; set; }. 4: public decimal Amount { get; set; }. Running the sample code produces output like this. 10: }. The Problem Solver - Monday, December 3, 2012 Building Scalable and Secure WCF Services public class NonSslAuthHttpTransportBindingElement : HttpTransportBindingElement { public override BindingElement Clone() { return new NonSslAuthHttpTransportBindingElement { AuthenticationScheme = AuthenticationScheme, ManualAddressing = ManualAddressing }; } public override T GetProperty<T>( BindingContext context) { if ( typeof (T) == typeof ( ISecurityCapabilities )) { return (T)( object ) new NonSslAuthSecurityCapabilities (); } return base.GetProperty<T>(context); } }. This means the load can be more efficiently distributed across multiple servers. DevelopMentor Courses - Monday, June 18, 2012 Use Common Instance Factory to Abstract Away the Dependency Injection Container public class GreetingService : IGreetingService { private readonly IGreetingRepository _greetingRepository; public GreetingService( IGreetingRepository greetingRepository) { _greetingRepository = greetingRepository; } public string Greet( string name) { string greeting = _greetingRepository.GetGreeting(); return string.Format( " {0} {1} " , greeting, name); } }. public interface ICommonInstanceFactory <TInstance> { TInstance GetInstance(); IEnumerable <TInstance> GetAllInstances(); void ReleaseInstance(TInstance instance); }. Stay tuned for more!) DevelopMentor Courses - Wednesday, May 23, 2012 |
77 Articles match "Public","Sample"
| The Latest from DevelopMentor | MORE | | Understanding Map - Reduce The Orders data structure looks like this: 1: public class Order. 3: public Order(). 7: 8: public int CustomerId { get; set; }. 9: public List Lines { get; set; }. 11: 12: public class OrderLine. 14: public string Book { get; set; }. 15: public int Quantity { get; set; }. 16: public decimal Price { get; set; }. We store that in the following structure: 1: public class ReducedTo. 3: public string Book { get; set; }. 4: public decimal Amount { get; set; }. Running the sample code produces output like this. 10: }. The Problem Solver - Monday, December 3, 2012 Understanding Map - Reduce The Orders data structure looks like this: 1: public class Order. 3: public Order(). 7: 8: public int CustomerId { get; set; }. 9: public List Lines { get; set; }. 11: 12: public class OrderLine. 14: public string Book { get; set; }. 15: public int Quantity { get; set; }. 16: public decimal Price { get; set; }. We store that in the following structure: 1: public class ReducedTo. 3: public string Book { get; set; }. 4: public decimal Amount { get; set; }. Running the sample code produces output like this. 10: }. The Problem Solver - Monday, December 3, 2012 What’s new in ApprovalTests.Net v.20? Here’s an example var urls = new [] { "/Home/Index/Hello" , "/" }; AspApprovals.VerifyRouting(MvcApplication.RegisterRoutes, urls); In the sample above, the delegate (MvcApplication.RegisterRoutes) will be invokes against a mock route collection, and then fed the URLs provided. sample output would look like this: /Home/Index/Hello = > [[controller, Home], [action, Index], [id, Hello]] / = > [[controller, Cool], [action, Index], [id, ]] Event approvals Similar to the example above, another aspect of code which is often hidden (or implicit) is which events are wired-up to your form. DevelopMentor Courses - Thursday, August 9, 2012 | -
| The Best from DevelopMentor | MORE | - Understanding Map - Reduce
The Orders data structure looks like this: 1: public class Order. 3: public Order(). 7: 8: public int CustomerId { get; set; }. 9: public List Lines { get; set; }. 11: 12: public class OrderLine. 14: public string Book { get; set; }. 15: public int Quantity { get; set; }. 16: public decimal Price { get; set; }. We store that in the following structure: 1: public class ReducedTo. 3: public string Book { get; set; }. 4: public decimal Amount { get; set; }. Running the sample code produces output like this. 10: }. The Problem Solver - Monday, December 3, 2012 - Using Model – View – ViewModel with Silverlight
Even thought the UI technology used doesn't change the basic MVVM pattern there are some subtle differences, like not easily being able to use ICommand in Silverlight, so I decided to create a small Silverlight sample. know it is a bit of a lame business rule but it is just a sample. 5: public class Customer : INotifyPropertyChanged. 7: private string _firstName; 8: private string _lastName; 9: 10: public string FirstName. 20: public string LastName. 30: 31: 32: public string FullName. 6: public partial class CustomerView : UserControl. The Problem Solver - Tuesday, April 7, 2009 - Peeling Back the Onion Architecture
public class ProductController : Controller { // Services will be injected private IProductService _productService; public ProductController( IProductService productService ) { _productService = productService; }. // // GET: /Product/ public ActionResult Index() { // Get products var products = _productService.GetProducts (selectedCategoryId); // Rest of method follows. } }. public class RepositoryModule : NinjectModule { public override void Load() { // Bind and get config service Bind< IConfigService >().To< Download the code for this article. Tony and Zuzana's World - Saturday, October 8, 2011 - The NoSQL Movement, LINQ, and MongoDB - Oh My!
Here’s a taste of the Blog class: public class Blog { public ObjectId _id { get; set; } public string Name { get; set; } public string Url { get; set; } public string RssUrl { get; set; } public List Entries { get; set; } //. }. The RssEntry class has the summary info for a blog entry: public class RssEntry { public ObjectId _id { get; set; } public Guid UniqueId { get; set; } public DateTime PostedDate { get; set; } public string Title { get; set; } public string RssGuid { get; set; } }. Insanity!” Flat files? Michael C. Kennedy's Weblog - Thursday, April 22, 2010 - Building Scalable and Secure WCF Services
public class NonSslAuthHttpTransportBindingElement : HttpTransportBindingElement { public override BindingElement Clone() { return new NonSslAuthHttpTransportBindingElement { AuthenticationScheme = AuthenticationScheme, ManualAddressing = ManualAddressing }; } public override T GetProperty<T>( BindingContext context) { if ( typeof (T) == typeof ( ISecurityCapabilities )) { return (T)( object ) new NonSslAuthSecurityCapabilities (); } return base.GetProperty<T>(context); } }. This means the load can be more efficiently distributed across multiple servers. DevelopMentor Courses - Monday, June 18, 2012 - Easier Async for Silverlight Apps using MVVM
public static void InternalNotifyPropertyChanged( string propertyName, object sender, PropertyChangedEventHandler propertyChanged) { if (propertyChanged != Check out the sample app by downloading the Simple MVVM Toolkit and opening the SimpleMvvm-Async project. It makes sense to execute long-running tasks on a background thread, in order to keep the UI responsive by not tying up the main thread. However, as is the case with other UI frameworks such as Windows Forms or WPF, you should not touch UI elements from worker threads. Technical MVVM Silverlight Tony and Zuzana's World - Saturday, January 29, 2011 - Use Common Instance Factory to Abstract Away the Dependency Injection Container
public class GreetingService : IGreetingService { private readonly IGreetingRepository _greetingRepository; public GreetingService( IGreetingRepository greetingRepository) { _greetingRepository = greetingRepository; } public string Greet( string name) { string greeting = _greetingRepository.GetGreeting(); return string.Format( " {0} {1} " , greeting, name); } }. public interface ICommonInstanceFactory <TInstance> { TInstance GetInstance(); IEnumerable <TInstance> GetAllInstances(); void ReleaseInstance(TInstance instance); }. Stay tuned for more!) DevelopMentor Courses - Wednesday, May 23, 2012 %>
| | |