[ 
https://issues.apache.org/jira/browse/SLING-2448?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13238189#comment-13238189
 ] 

Robert Munteanu commented on SLING-2448:
----------------------------------------

In reply to comment #2:
> Can you explain how this manifests itself? The use of Guava's Maps class (in
> fact the use of Guava at all) is an internal implementation detail of this
> bundle and is not exposed to consumers. Only the Guava classes which are
> actually required by the bundle are embedded.

The issue here is how Eclipse handles classes found in attached libraries 
rather than in compilation using javac or runtime usage. Eclipse analyses the 
Maps class and notices that one of the methods references the MadDifference 
interface. It tries to resolve it but fails and therefore generates a 
compilation error.

I suspect that compiling the bundle using ecj would generate the same error , 
but I did not check that.

I will attach a screenshot of what I usually get in Eclipse for this error.
                
> org.apache.sling.jcr.resource should embed 
> com.google.common.collect.MapDifference
> ----------------------------------------------------------------------------------
>
>                 Key: SLING-2448
>                 URL: https://issues.apache.org/jira/browse/SLING-2448
>             Project: Sling
>          Issue Type: Bug
>          Components: JCR
>    Affects Versions: JCR Resource 2.0.10
>            Reporter: Robert Munteanu
>            Priority: Minor
>         Attachments: SLING-2448.txt
>
>
> org.apache.sling.jcr.resource embeds parts of the guava bundle 
> inconsistently. It embeds the Map class, but not the MapDifference interface, 
> which is directly refered from the Maps class.
> This error is typically flagged in Eclipse with a very cryptic message: 'The 
> project was not built since its build path is incomplete. Cannot find the 
> class file for com.google.common.collect.MapDifference$ValueDifference. Fix 
> the build path then try building this project'.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to