Package rocket.generator.rebind

Examples of rocket.generator.rebind.GeneratorContext.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();
      context.debug(bean.getId());

      this.overrideFactoryBeanCreateInstance(bean);

      context.unbranch();
View Full Code Here


      }
    }

    context.unbranch();

    context.branch();
    context.debug("Matching constructors.");

    final List<Constructor> matchingConstructors = new ArrayList<Constructor>();
    final TypeConstructorsVisitor visitor = new TypeConstructorsVisitor() {
View Full Code Here

    while (iterator.hasNext()) {
      final Bean bean = iterator.next();
      final String initMethodName = bean.getInitMethod();

      if (false == Tester.isNullOrEmpty(initMethodName)) {
        context.branch();
        context.debug(bean.getId());

        this.overrideFactoryBeanSatisfyInit(bean);

        context.unbranch();
View Full Code Here

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

    final GeneratorContext context = this.getGeneratorContext();
    context.branch();
    context.info("Overriding satisfyProperties method for bean(s) with 1 or more properties.");

    final Iterator<Bean> iterator = beans.iterator();
    while (iterator.hasNext()) {

View Full Code Here

    NewType imageFactory = null;
    while (i.hasNext()) {
      if (null == imageFactory) {
        imageFactory = this.createImageFactory();

        context.branch();
        context.debug("Creating abstract getters on image factory");
      }

      final ImageValue imageValue = i.next();
View Full Code Here

   *
   * @return
   */
  protected NewType createImageFactory() {
    final GeneratorContext context = this.getGeneratorContext();
    context.branch();
    context.info("Creating Image Factory");

    final NewType beanFactory = this.getBeanFactory();

    final NewNestedInterfaceType imageFactory = beanFactory.newNestedInterfaceType();
View Full Code Here

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

    final GeneratorContext context = this.getGeneratorContext();
    context.branch();
    context.info("Visiting singleton beans.");

    final Iterator<Bean> iterator = beans.iterator();
    int singletonCount = 0;
    int customDestroyMethodCount = 0;
View Full Code Here

      }

      final String destroyMethodName = bean.getDestroyMethod();

      if (false == Tester.isNullOrEmpty(destroyMethodName)) {
        context.branch();
        context.debug(bean.getId());

        this.overrideSingletonFactoryBeanDestroy(bean);

        context.unbranch();
View Full Code Here

    writer.endJavaDocComment();
  }

  protected void log() {
    final GeneratorContext context = this.getGeneratorContext();
    context.branch();
    context.info(this.getVisibility().getName() + (this.isInterface() ? " class " : " interface ") + this.getName());

    this.logSuperType();
    this.logImplementedInterfaces();
View Full Code Here

    final Set<Initializer> initializers = this.getInitializers();
    if (false == initializers.isEmpty()) {

      final GeneratorContext context = this.getGeneratorContext();
      context.branch();

      final String message = "Initializers";
      context.debug(message);

      writer.beginJavaDocComment();
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.