Package freemarker.cache

Examples of freemarker.cache.ClassTemplateLoader


    final TypeElement element = processingEnv.getElementUtils().getTypeElement(Entity.class.getName());
    if (annotations.contains(element)) {
      try {
        Configuration cfg = new Configuration();
        cfg.setObjectWrapper(new DefaultObjectWrapper());
        cfg.setTemplateLoader(new ClassTemplateLoader(getClass(), "/templates"));
        Template template = cfg.getTemplate("criteria.ftl");
        for (TypeElement typeElement : ElementFilter.typesIn(roundEnv.getElementsAnnotatedWith(Entity.class))) {
          generate(template, typeElement);
        }
        template = cfg.getTemplate("embedded.ftl");
View Full Code Here


    final TypeElement element = env.getElementUtils().getTypeElement(Entity.class.getName());
    if (annotations.contains(element)) {
      try {
        Configuration cfg = new Configuration();
        cfg.setObjectWrapper(new DefaultObjectWrapper());
        cfg.setTemplateLoader(new ClassTemplateLoader(getClass(), "/templates"));
        Template temp = cfg.getTemplate("criteria.ftl");
        Set<TypeElement> elements = ElementFilter.typesIn(roundEnv.getElementsAnnotatedWith(Entity.class));
        for (TypeElement typeElement : elements) {
          String name = typeElement.getSimpleName().toString();
          String pkg = getPackageName(typeElement);
View Full Code Here

         catch (IOException ioEx)
         {
            throw new RuntimeException(ioEx);
         }
      }
      loaders.add(new ClassTemplateLoader(loaderConfig.getLoaderClass(), loaderConfig.getBasePath()));
      config = new Configuration();
      config.setTemplateLoader(new MultiTemplateLoader(loaders.toArray(new TemplateLoader[0])));
      config.setObjectWrapper(new DefaultObjectWrapper());
   }
View Full Code Here

        //grab the catalog and store a reference
        catalog = (Catalog)GeoServerExtensions.bean("catalog");

        //create a class template loader to delegate to
        if (caller != null) {
            classTemplateLoader = new ClassTemplateLoader(caller, "");
        }
       
        dd = new GeoServerDataDirectory(rl);
    }
View Full Code Here

    final TypeElement element = processingEnv.getElementUtils().getTypeElement(Entity.class.getName());
    if (annotations.contains(element)) {
      try {
        Configuration cfg = new Configuration();
        cfg.setObjectWrapper(new DefaultObjectWrapper());
        cfg.setTemplateLoader(new ClassTemplateLoader(getClass(), "/templates"));
        Template template = cfg.getTemplate("criteria.ftl");
        for (TypeElement typeElement : ElementFilter.typesIn(roundEnv.getElementsAnnotatedWith(Entity.class))) {
          generate(template, typeElement);
        }
        template = cfg.getTemplate("embedded.ftl");
View Full Code Here

        return STATIC_RESOURCE_PATH;
    }

    @Override
    public TemplateLoader getTemplateLoader() {
        return new ClassTemplateLoader(getClass(), TEMPLATE_PATH);
    }
View Full Code Here

        return STATIC_RESOURCE_PATH;
    }

    @Override
    public TemplateLoader getTemplateLoader() {
        return new ClassTemplateLoader(getClass(), TEMPLATE_PATH);
    }
View Full Code Here

        return STATIC_RESOURCE_PATH;
    }

    @Override
    public TemplateLoader getTemplateLoader() {
        return new ClassTemplateLoader(getClass(), TEMPLATE_PATH);
    }
View Full Code Here

    return STATIC_RESOURCE_PATH;
  }

  @Override
  public TemplateLoader getTemplateLoader() {
    return new ClassTemplateLoader(getClass(), TEMPLATE_PATH);
  }
View Full Code Here

        return STATIC_RESOURCE_PATH;
    }

    @Override
    public TemplateLoader getTemplateLoader() {
        return new ClassTemplateLoader(getClass(), TEMPLATE_PATH);
    }
View Full Code Here

TOP

Related Classes of freemarker.cache.ClassTemplateLoader

Copyright © 2018 www.massapicom. 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.