public void Register(Type concreteType, Type serviceType, string name = null) { var castAs = serviceType.GetTypeFromAttribute(); var compositeRegistration = new CompositeFrameworkRegistration(concreteType, serviceType, castAs); container.Register(compositeRegistration); }