FileDocCategorySizeDatePackage
ProcessingResultImpl.javaAPI DocGlassfish v2 API4014Fri May 04 22:30:22 BST 2007com.sun.enterprise.deployment.annotation.impl

ProcessingResultImpl

public class ProcessingResultImpl extends Object implements com.sun.enterprise.deployment.annotation.ProcessingResult
Implementation of the ProcessingResult interface
author
Jerome Dochez

Fields Summary
Map
results
com.sun.enterprise.deployment.annotation.ResultType
overallResult
Constructors Summary
public ProcessingResultImpl()
Creates a new instance of ProcessingResultImpl

    
           
      
        results = new HashMap<AnnotatedElement, HandlerProcessingResult>();
    
Methods Summary
public voidadd(com.sun.enterprise.deployment.annotation.ProcessingResult pr)

        
        Map<AnnotatedElement, HandlerProcessingResult> results = pr.getResults();
        for (AnnotatedElement element : results.keySet()) {
            add(element, results.get(element));
        }
    
public voidadd(java.lang.reflect.AnnotatedElement element, com.sun.enterprise.deployment.annotation.HandlerProcessingResult elementResult)


        if (elementResult.getOverallResult().compareTo(overallResult)>0) {
            overallResult = elementResult.getOverallResult();
        }
        if (results.containsKey(element)) {
            HandlerProcessingResultImpl previousResult = (HandlerProcessingResultImpl) results.get(element);
            previousResult.addAll(elementResult);
        } else {
            if (elementResult instanceof HandlerProcessingResultImpl) {
                results.put(element, elementResult);
            } else {
                HandlerProcessingResultImpl result = new HandlerProcessingResultImpl();
                result.addAll(elementResult);
                results.put(element, result);
            }
        }
    
public com.sun.enterprise.deployment.annotation.ResultTypegetOverallResult()

        return overallResult;
    
public java.util.MapgetResults()

        return results;