org.cruxframework.crux.core.rebind.crossdevice
Class DeviceAdaptiveProxyCreator

java.lang.Object
  extended by org.cruxframework.crux.core.rebind.AbstractProxyCreator
      extended by org.cruxframework.crux.core.rebind.AbstractInterfaceWrapperProxyCreator
          extended by org.cruxframework.crux.core.rebind.AbstractWrapperProxyCreator
              extended by org.cruxframework.crux.core.rebind.crossdevice.DeviceAdaptiveProxyCreator

public class DeviceAdaptiveProxyCreator
extends AbstractWrapperProxyCreator

Author:
Thiago da Rosa de Bustamante

Nested Class Summary
 
Nested classes/interfaces inherited from class org.cruxframework.crux.core.rebind.AbstractProxyCreator
AbstractProxyCreator.SourcePrinter
 
Field Summary
 
Fields inherited from class org.cruxframework.crux.core.rebind.AbstractInterfaceWrapperProxyCreator
baseIntf
 
Fields inherited from class org.cruxframework.crux.core.rebind.AbstractProxyCreator
cacheable, cacheableVersionFound, context, logger
 
Constructor Summary
DeviceAdaptiveProxyCreator(com.google.gwt.core.ext.TreeLogger logger, com.google.gwt.core.ext.GeneratorContext context, com.google.gwt.core.ext.typeinfo.JClassType baseIntf)
           
 
Method Summary
protected  void createController(AbstractProxyCreator.SourcePrinter srcWriter, String viewVariable)
           
protected  void generateProxyContructor(AbstractProxyCreator.SourcePrinter srcWriter)
          Generate the proxy constructor and delegate to the superclass constructor using the default address for the RemoteService.
protected  void generateProxyFields(AbstractProxyCreator.SourcePrinter srcWriter)
          Generate any fields required by the proxy.
protected  void generateWrapperMethod(com.google.gwt.core.ext.typeinfo.JMethod method, AbstractProxyCreator.SourcePrinter srcWriter)
           
protected  String[] getImports()
           
 String getProxyQualifiedName()
           
 String getProxySimpleName()
           
protected  AbstractProxyCreator.SourcePrinter getSourcePrinter()
           
protected  void initializeController(View view)
           
protected  void initializeTemplateParser()
           
protected  boolean mustDelegateToController(com.google.gwt.core.ext.typeinfo.JMethod method)
           
 
Methods inherited from class org.cruxframework.crux.core.rebind.AbstractWrapperProxyCreator
generateProxyMethods, generateProxyMethods
 
Methods inherited from class org.cruxframework.crux.core.rebind.AbstractInterfaceWrapperProxyCreator
findCacheableImplementationAndMarkForReuseIfAvailable, getDeviceFeatures, getModule, getScreens, getUserAgent, getViews
 
Methods inherited from class org.cruxframework.crux.core.rebind.AbstractProxyCreator
cacheableVersionFound, create, findCacheableImplementationAndMarkForReuseIfAvailable, generateLoggerField, generateMethodParameters, generateMethodTrhowsClause, generateProxyWrapperMethodDeclaration, generateSubTypes, getJsniSimpleSignature, isAlreadyGenerated, isCacheable, isCrux2OldInterfacesCompatibilityEnabled, logDebugMessage
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DeviceAdaptiveProxyCreator

public DeviceAdaptiveProxyCreator(com.google.gwt.core.ext.TreeLogger logger,
                                  com.google.gwt.core.ext.GeneratorContext context,
                                  com.google.gwt.core.ext.typeinfo.JClassType baseIntf)
Parameters:
logger -
context -
baseIntf -
Method Detail

initializeTemplateParser

protected void initializeTemplateParser()

initializeController

protected void initializeController(View view)

generateWrapperMethod

protected void generateWrapperMethod(com.google.gwt.core.ext.typeinfo.JMethod method,
                                     AbstractProxyCreator.SourcePrinter srcWriter)
Specified by:
generateWrapperMethod in class AbstractWrapperProxyCreator

mustDelegateToController

protected boolean mustDelegateToController(com.google.gwt.core.ext.typeinfo.JMethod method)

getImports

protected String[] getImports()
Specified by:
getImports in class AbstractInterfaceWrapperProxyCreator
Returns:
the list of imports required by proxy

generateProxyContructor

protected void generateProxyContructor(AbstractProxyCreator.SourcePrinter srcWriter)
                                throws CruxGeneratorException
Description copied from class: AbstractProxyCreator
Generate the proxy constructor and delegate to the superclass constructor using the default address for the RemoteService.

Overrides:
generateProxyContructor in class AbstractProxyCreator
Throws:
CruxGeneratorException

createController

protected void createController(AbstractProxyCreator.SourcePrinter srcWriter,
                                String viewVariable)
Parameters:
srcWriter -

generateProxyFields

protected void generateProxyFields(AbstractProxyCreator.SourcePrinter srcWriter)
                            throws CruxGeneratorException
Description copied from class: AbstractProxyCreator
Generate any fields required by the proxy.

Overrides:
generateProxyFields in class AbstractProxyCreator
Throws:
CruxGeneratorException

getProxySimpleName

public String getProxySimpleName()
Overrides:
getProxySimpleName in class AbstractInterfaceWrapperProxyCreator
Returns:
the simple name of the proxy object.

getProxyQualifiedName

public String getProxyQualifiedName()
Overrides:
getProxyQualifiedName in class AbstractInterfaceWrapperProxyCreator
Returns:
the full qualified name of the proxy object.

getSourcePrinter

protected AbstractProxyCreator.SourcePrinter getSourcePrinter()
Overrides:
getSourcePrinter in class AbstractInterfaceWrapperProxyCreator
Returns:
a sourceWriter for the proxy class


Copyright © 2014. All rights reserved.