Questions tagged [objectbuilder]

ObjectBuilder is Microsoft's first .NET dependency injection framework. The Patterns and Practices team describes it as "a framework for building dependency injection systems", which means a base of abstraction which actual DI implementations, like Unity application block, make use of underneath the covers to accomplish their feats.

ObjectBuilder is hosted at CodePlex.

http://objectbuilder.codeplex.com/

7 questions
4
votes
2 answers

With Method that takes Func on an Object Builder

I am trying to create an Object Builder so I can easily create objects for unit testing. I would like to create a With() method so I can pass in a Func<> and it will set the correct property for me. Here is what I have so far: public class…
Martin
  • 11,031
  • 8
  • 50
  • 77
2
votes
1 answer

How setup dart objectbox with a local database pre-populated?

I want to set up an ObjectBox database with Flutter. I would like to pre-populate the database file with values. When installing the application, the database file will be copied and is used by the application. I want to be able to continue to…
Dev Loots
  • 708
  • 9
  • 28
2
votes
1 answer

Is there a thread-safety issue in this ObjectBuilder code?

I suspect a problem with an old version of the ObjectBuilder which once was part of the WCSF Extension project and meanwhile moved into Unity. I am not sure whether I am on the right way or not so I hope someone out there has more competent…
Eulinky
  • 375
  • 3
  • 14
1
vote
1 answer

ObjectBuilder dependency injection and ASP.NET Web Services

I'm using Microsoft.Practices.ObjectBuilder in a web project to handle dependency injection (between view and presenter for example). I've recently added an ASP.NET Web Service (.asmx) to handle ajax calls. I would like to use dependency injection…
Joel
  • 8,502
  • 11
  • 66
  • 115
0
votes
1 answer

Delegates to "anonymous" interface proxy

May be you know if the standard .net framework library / ms enterprise library contains something like this functionality: IConvertible proxy = CodegenThatEverybodyNeed.CreateProxy( new Func {...}, new…
Roman Pokrovskij
  • 9,449
  • 21
  • 87
  • 142
0
votes
1 answer

Why does Unity custom BuilderStrategy returns null even after setting Existing property

I'm using version 2 of Unity (that comes with Prism4). I'm trying to write an extension that can return enumerable of a non registered type. Following code is what I've written but I'm getting null after resolve call. class…
Muhammad Hasan Khan
  • 34,648
  • 16
  • 88
  • 131
0
votes
2 answers

ServiceLocator.Current.GetInstance causes excessive number of calls to ObjectBuilder2.PolicyList.GetNoDefault

In my MVC4, .NET4.5 web app using Unity IoC container, in the method IoCContainerFactory.GetControllerInstance() we use ServiceLocator.Current.GetInstance to get the controller instance: public class IoCControllerFactory :…
JK.
  • 21,477
  • 35
  • 135
  • 214