Package rocket.generator.rebind

Examples of rocket.generator.rebind.GeneratorContext.info()


  protected void buildAspects(final Set<Aspect> aspects) {
    Checker.notNull("parameter:aspects", aspects);

    final GeneratorContext context = this.getGeneratorContext();
    context.branch();
    context.info("Processing and verifying " + aspects.size() + " aspect(s).");

    final MethodMatcherFactory methodMatcherFactory = createMethodMatcherFactory();

    final Iterator<Aspect> iterator = aspects.iterator();
    while (iterator.hasNext()) {
View Full Code Here


   * Creates a factory bean for each bean that will be proxied.
   */
  protected void applyAspects() {
    final GeneratorContext context = this.getGeneratorContext();
    context.branch();
    context.info("Checking for beans with one or more aspects.");

    final Set<Bean> beans = this.filterBeansRequiringInterceptors();

    final Iterator<Bean> advisedIterator = beans.iterator();
    while (advisedIterator.hasNext()) {
View Full Code Here

    final RegisterFactoryBeansTemplatedFile body = new RegisterFactoryBeansTemplatedFile();
    newMethod.setBody(body);

    context.branch();
    context.info("Overriding " + newMethod + " to register all beans.");

    final Iterator<Bean> beansIterator = this.getBeans().values().iterator();

    while (beansIterator.hasNext()) {
      final Bean bean = beansIterator.next();
View Full Code Here

    final GetAliasesToBeans body = new GetAliasesToBeans();
    newMethod.setBody(body);

    context.branch();
    context.info("Overriding " + newMethod + " to register all aliases.");

    final Iterator<Alias> beansIterator = this.getAliases().values().iterator();
    int aliasCount = 0;

    while (beansIterator.hasNext()) {
View Full Code Here

  protected void overrideLoadEagerBeans() {
    final Map<String, Bean> beans = this.getBeans();

    final GeneratorContext context = this.getGeneratorContext();
    context.branch();
    context.info("Overriding BeanFactory." + Constants.GET_EAGER_SINGELTON_BEAN_NAMES_METHOD
        + "() to initialize eager singleton beans on factory startup.");
    context.branch();

    final NewType beanFactory = this.getBeanFactory();
    final Method abstractMethod = beanFactory.getSuperType().getMostDerivedMethod(Constants.GET_EAGER_SINGELTON_BEAN_NAMES_METHOD,Collections.<Type>emptyList());
View Full Code Here

   */
  protected NewConcreteType createSerializableFactory(final String newTypeName) {
    Checker.notEmpty("parameter:newTypeName", newTypeName);

    final GeneratorContext context = this.getGeneratorContext();
    context.info("Creating serialization factory " + newTypeName);

    final NewConcreteType serializationFactory = context.newConcreteType(newTypeName);
    serializationFactory.setAbstract(false);
    serializationFactory.setFinal(true);
    serializationFactory.setSuperType(this.getSerializationFactory());
View Full Code Here

  protected DocumentWalker getDocumentWalker(final Type type) {
    final String fileName = this.getResourceName(type, Constants.BEAN_FILE_SUFFIX);

    final GeneratorContext context = this.getGeneratorContext();
    context.branch();
    context.info("Preparing to discover components within \"" + fileName + "\".");

    final DocumentWalker document = new DocumentWalker();
    document.setEntityResolver(new BeanFactoryDtdEntityResolver());
    document.setErrorHandler(new RethrowSaxExceptionsErrorHandler());
    document.setGenerator(this);
View Full Code Here

   */
  protected void verifyBeanFactory(final Type type) {
    Checker.notNull("parameter:type", type);

    final GeneratorContext context = this.getGeneratorContext();
    context.info("Verifying " + type + " is a bean factory.");

    final Type beanFactory = this.getBeanFactoryType();
    if (false == type.isAssignableTo(beanFactory)) {
      throwNotABeanFactory("The type \"" + type + "\" is not a " + beanFactory);
    }
View Full Code Here

  protected void buildFactoryBeans(final Set<Bean> beans) {
    Checker.notNull("parameter:beans", beans);

    final GeneratorContext context = this.getGeneratorContext();
    context.branch();
    context.info("Creating FactoryBean's for all beans.");

    final Iterator<Bean> iterator = beans.iterator();
    int nestedBeanCounter = 0;
    int rpcCounter = 0;
    int beansCounter = 0;
View Full Code Here

  protected void overrideAllFactoryBeanCreateInstances(final Set<Bean> beans) {
    Checker.notNull("parameter:beans", beans);

    final GeneratorContext context = this.getGeneratorContext();
    context.branch();
    context.info("Overriding createInstance methods for all bean(s).");

    final Iterator<Bean> iterator = beans.iterator();
    while (iterator.hasNext()) {
      final Bean bean = iterator.next();
      context.branch();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.