Package com.google.gwt.place.shared

Examples of com.google.gwt.place.shared.WithTokenizers


   public Object create(Class<?> classLiteral) throws Exception {
      if (!PlaceHistoryMapper.class.isAssignableFrom(classLiteral)) {
         return null;
      }

      WithTokenizers withTokenizers = classLiteral.getAnnotation(WithTokenizers.class);
      if (withTokenizers == null) {
         throw new GwtTestPatchException(
                  "Error while trying to create an instance of "
                           + classLiteral.getName()
                           + " : gwt-test-utils default GwtCreateHandler for PlaceHistoryMapper is not currently able to create a valid implementation without relying on the @WithTokenizer annotation");
      }

      return Proxy.newProxyInstance(classLiteral.getClassLoader(), new Class<?>[]{classLiteral},
               new PlaceHistoryInvocationHandler(withTokenizers.value()));

   }
View Full Code Here


    return getPlaceTypeForTokenizerType(returnType).getName();
  }

  private Set<JClassType> getWithTokenizerEntries() {
    WithTokenizers annotation = interfaceType.getAnnotation(WithTokenizers.class);
    if (annotation == null) {
      return Collections.emptySet();
    }

    LinkedHashSet<JClassType> rtn = new LinkedHashSet<JClassType>();
    for (Class<? extends PlaceTokenizer<?>> tokenizerClass : annotation.value()) {
      JClassType tokenizerType = typeOracle.findType(tokenizerClass.getCanonicalName());
      if (tokenizerType == null) {
        logger.log(TreeLogger.ERROR, String.format(
            "Error processing @%s, cannot find type %s",
            WithTokenizers.class.getSimpleName(),
View Full Code Here

TOP

Related Classes of com.google.gwt.place.shared.WithTokenizers

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.