com.googlecode.androidannotations.processing.rest
Class MethodProcessor

java.lang.Object
  extended by com.googlecode.androidannotations.processing.rest.MethodProcessor
All Implemented Interfaces:
HasTarget, ElementProcessor
Direct Known Subclasses:
DeleteProcessor, GetProcessor, HeadProcessor, OptionsProcessor, PostProcessor, PutProcessor

public abstract class MethodProcessor
extends java.lang.Object
implements ElementProcessor


Field Summary
protected  RestAnnotationHelper restAnnotationHelper
           
protected  RestImplementationsHolder restImplementationsHolder
           
 
Constructor Summary
MethodProcessor(javax.annotation.processing.ProcessingEnvironment processingEnv, RestImplementationsHolder restImplementationHolder)
           
 
Method Summary
protected abstract  com.sun.codemodel.JInvocation addHttpEntityVar(com.sun.codemodel.JInvocation restCall, MethodProcessorHolder methodHolder)
           
protected abstract  com.sun.codemodel.JVar addHttpHeadersVar(com.sun.codemodel.JBlock body, javax.lang.model.element.ExecutableElement executableElement)
           
protected abstract  com.sun.codemodel.JInvocation addResponseEntityArg(com.sun.codemodel.JInvocation restCall, MethodProcessorHolder methodHolder)
           
protected abstract  com.sun.codemodel.JInvocation addResultCallMethod(com.sun.codemodel.JInvocation restCall, MethodProcessorHolder methodHolder)
           
protected  com.sun.codemodel.JVar generateHttpEntityVar(MethodProcessorHolder methodHolder)
           
protected  com.sun.codemodel.JVar generateHttpHeadersVar(com.sun.codemodel.JBlock body, javax.lang.model.element.ExecutableElement executableElement)
           
protected  void generateRestTemplateCallBlock(MethodProcessorHolder methodHolder)
           
abstract  java.lang.Class<? extends java.lang.annotation.Annotation> getTarget()
           
abstract  void process(javax.lang.model.element.Element element, com.sun.codemodel.JCodeModel codeModel, EBeansHolder eBeansHolder)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

restImplementationsHolder

protected final RestImplementationsHolder restImplementationsHolder

restAnnotationHelper

protected final RestAnnotationHelper restAnnotationHelper
Constructor Detail

MethodProcessor

public MethodProcessor(javax.annotation.processing.ProcessingEnvironment processingEnv,
                       RestImplementationsHolder restImplementationHolder)
Method Detail

generateRestTemplateCallBlock

protected void generateRestTemplateCallBlock(MethodProcessorHolder methodHolder)

addHttpEntityVar

protected abstract com.sun.codemodel.JInvocation addHttpEntityVar(com.sun.codemodel.JInvocation restCall,
                                                                  MethodProcessorHolder methodHolder)

addResponseEntityArg

protected abstract com.sun.codemodel.JInvocation addResponseEntityArg(com.sun.codemodel.JInvocation restCall,
                                                                      MethodProcessorHolder methodHolder)

addResultCallMethod

protected abstract com.sun.codemodel.JInvocation addResultCallMethod(com.sun.codemodel.JInvocation restCall,
                                                                     MethodProcessorHolder methodHolder)

generateHttpEntityVar

protected com.sun.codemodel.JVar generateHttpEntityVar(MethodProcessorHolder methodHolder)

generateHttpHeadersVar

protected com.sun.codemodel.JVar generateHttpHeadersVar(com.sun.codemodel.JBlock body,
                                                        javax.lang.model.element.ExecutableElement executableElement)

addHttpHeadersVar

protected abstract com.sun.codemodel.JVar addHttpHeadersVar(com.sun.codemodel.JBlock body,
                                                            javax.lang.model.element.ExecutableElement executableElement)

getTarget

public abstract java.lang.Class<? extends java.lang.annotation.Annotation> getTarget()
Specified by:
getTarget in interface HasTarget

process

public abstract void process(javax.lang.model.element.Element element,
                             com.sun.codemodel.JCodeModel codeModel,
                             EBeansHolder eBeansHolder)
                      throws java.lang.Exception
Specified by:
process in interface ElementProcessor
Throws:
java.lang.Exception


Copyright © 2010-2012. All Rights Reserved.