I found the answer faster than I thought I would, in the wiki documentation.
This is the temporary way of doing it:
TypeAlias alias = new TypeAlias("OldNameSpace.OldTypeName, OldAssembly", "NewNameSpace.NewTypeName, NewAssembly");
Db4oFactory.Configure().AddAlias(alias);
IObjectContainer db = Db4oFactory.OpenFile(dbfilename);
The more permanent way (it's messy code but it's for a temp fix):
using (IObjectContainer db = Db4oFactory.OpenFile(dbfilename))
{
var n = db.Ext().StoredClasses();
foreach (var x in n)
{
System.Diagnostics.Debug.WriteLine(x.GetName());
}
var c1 = db.Ext().StoredClass("OldNameSpace.OldType, OldAssembly");//
if (c1 != null)
c1.Rename("NewNameSpace.OldType, NewAssembly");
var c2 = db.Ext().StoredClass("System.Collections.Generic.List`1[[OldNameSpace.OldType, OldAssembly]], mscorlib");
if (c2 != null)
c2.Rename("System.Collections.Generic.List`1[[NewNameSpace.OldType, NewAssembly]], mscorlib");
}
As you can see 'ILists' need updating. Make sure when you save you do it to a new file, otherwise you will get both types in the output file.