@Override protected void configure() { bind(ModelLocator.class).to(DefaultModelLocator.class).in(Singleton.class); bind(ModelReader.class).to(DefaultModelReader.class).in(Singleton.class); bind(ModelValidator.class).to(DefaultModelValidator.class).in(Singleton.class); bind(RepositoryConnectorFactory.class).to(BasicRepositoryConnectorFactory.class) .in(Singleton.class); bind(ArtifactDescriptorReader.class) // .to(DefaultArtifactDescriptorReader.class).in(Singleton.class); bind(VersionResolver.class) // .to(DefaultVersionResolver.class).in(Singleton.class); bind(VersionRangeResolver.class) // .to(DefaultVersionRangeResolver.class).in(Singleton.class); bind(MetadataGeneratorFactory.class).annotatedWith(Names.named("snapshot")) // .to(SnapshotMetadataGeneratorFactory.class).in(Singleton.class); bind(MetadataGeneratorFactory.class).annotatedWith(Names.named("versions")) // .to(VersionsMetadataGeneratorFactory.class).in(Singleton.class); bind(TransporterFactory.class).annotatedWith(Names.named("http")) .to(HttpTransporterFactory.class).in(Singleton.class); bind(TransporterFactory.class).annotatedWith(Names.named("file")) .to(FileTransporterFactory.class).in(Singleton.class); }
protected ModelValidator newModelValidator() { return new DefaultModelValidator(); }
public DefaultModelBuilder setModelValidator( ModelValidator modelValidator ) { this.modelValidator = modelValidator; return this; }