Skip to content

Instantly share code, notes, and snippets.

@jagregory
Created February 9, 2009 23:25
Show Gist options
  • Select an option

  • Save jagregory/61092 to your computer and use it in GitHub Desktop.

Select an option

Save jagregory/61092 to your computer and use it in GitHub Desktop.
public interface IAutoMappingConfigChunk
{
void Configure(AutoPersistenceModel model);
}
// in AutoPersistenceModel
public AutoPersistenceModel WithConfigurationChunk(IAutoMappingConfigChunk chunk)
{
configChunks.Add(chunk);
return this;
}
// WithConfigurationChunks(assembly) etc...
// before compiling automappings, iterate configChunks and
// execute them against the APM
foreach (var chunk in configChunks)
{
chunk.Configure(this);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment