colesico.framework.dslvalidator.t9n.ValidatorMessagesT9nIoclet Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of colesico-validation Show documentation
Show all versions of colesico-validation Show documentation
Colesico framework data bean validation assistant and simple dsl validator
// This is automatically generated file. Do not modify!
package colesico.framework.dslvalidator.t9n;
import colesico.framework.assist.LazySingleton;
import colesico.framework.assist.codegen.Genstamp;
import colesico.framework.ioc.ioclet.AdvancedIoc;
import colesico.framework.ioc.ioclet.Catalog;
import colesico.framework.ioc.ioclet.Factory;
import colesico.framework.ioc.ioclet.Ioclet;
import colesico.framework.ioc.ioclet.SingletonFactory;
import colesico.framework.ioc.key.TypeKey;
import colesico.framework.ioc.production.InstanceProducingException;
import colesico.framework.translation.TranslationKit;
@Genstamp(
generator = "colesico.framework.ioc.codegen.generator.IocletGenerator",
timestamp = "2022-11-17T14:14:53.075Z",
hashId = "a683668b-03d4-4044-8c1c-e8311ba46dfa",
comments = "Producer: colesico.framework.dslvalidator.t9n.ValidatorMessagesT9nProducer"
)
public final class ValidatorMessagesT9nIoclet implements Ioclet {
private final LazySingleton producer = new LazySingleton() {
@Override
public final ValidatorMessagesT9nProducer create() {
return new ValidatorMessagesT9nProducer();
}
};
@Override
public final String getId() {
return "colesico.framework.dslvalidator.t9n.ValidatorMessagesT9nProducer";
}
/**
* Factory to produce colesico.framework.dslvalidator.t9n.ValidatorMessages class instance
* Scope: UNSCOPED; Custom: null
*/
public Factory getValidatorMessages0Factory0() {
return new Factory() {
private Factory implFac;
@Override
public final void setup(final AdvancedIoc ioc) {
// Initialize dependencies for: colesico.framework.dslvalidator.t9n.ValidatorMessages
this.implFac = ioc.factory(new TypeKey("colesico.framework.dslvalidator.t9n.ValidatorMessagesImpl"));
}
@Override
public final ValidatorMessages get(final Object message) {
try {
// Perform instance producing
ValidatorMessages instance = producer.get().getValidatorMessages0(this.implFac.get(message));
return instance;
} catch (InstanceProducingException ipe) {
throw ipe;
} catch (Throwable t) {
throw new InstanceProducingException(t, ValidatorMessages.class);
}
}
};
}
/**
* Factory to produce colesico.framework.dslvalidator.t9n.ValidatorMessagesImpl class instance
* Scope: SINGLETON; Custom: null
*/
public Factory getValidatorMessagesImplFactory1() {
return new SingletonFactory() {
private Factory translationKitFac;
@Override
public final void setup(final AdvancedIoc ioc) {
// Initialize dependencies for: colesico.framework.dslvalidator.t9n.ValidatorMessagesImpl
this.translationKitFac = ioc.factory(new TypeKey("colesico.framework.translation.TranslationKit"));
}
@Override
public final ValidatorMessagesImpl create(final Object message) {
try {
// Perform instance producing
ValidatorMessagesImpl instance = new ValidatorMessagesImpl(this.translationKitFac.get(message));
// Post construct listeners invocations:
return instance;
} catch (InstanceProducingException ipe) {
throw ipe;
} catch (Throwable t) {
throw new InstanceProducingException(t, ValidatorMessagesImpl.class);
}
}
};
}
@Override
public final void addFactories(final Catalog catalog) {
if(catalog.accept(new TypeKey("colesico.framework.dslvalidator.t9n.ValidatorMessages"), null, null, false)){
catalog.add(getValidatorMessages0Factory0());
}
if(catalog.accept(new TypeKey("colesico.framework.dslvalidator.t9n.ValidatorMessagesImpl"), null, null, false)){
catalog.add(getValidatorMessagesImplFactory1());
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy