public void RegisterMapping(Type controlType, IRegionAdapter adapter)
{
if (controlType == null) throw new ArgumentNullException("controlType");
if (adapter == null) throw new ArgumentNullException("adapter");
Contract.EndContractBlock();
if (mappings.ContainsKey(controlType))
{
throw new InvalidOperationException(String.Format(CultureInfo.CurrentCulture,
Resources.MappingExistsException, controlType.Name));
}
mappings.Add(controlType, adapter);
}