How to combine FileContentPattern with XmlPatterns ?
Hi,
I'm currently trying to implement a facet for an internal framework.
I have some problem to implement the "createSuitableFilePattern". The framework dectection is based on the presence of a Spring bean with a specficic value for the attribute 'class'
Here's how I try tho do that :
return FileContentPattern.fileContent()
.xmlWithRootTagNamespace("http://www.springframework.org/schema/beans")
.xmlWithRootTag("beans").and(XmlPatterns.xmlTag().withName("bean").withAttributeValue("class", "com.bsb.fluid.core.model.scanner.ScanningConfiguration"));
But this does not seem to work. The first part (before ".and") works, it detects correctly all spring configuration file, but the complete pattern does not work.
Is there a way to implement what I'm trying to do ?
I also noticed that facet configuration seems to have some kind of cache. Restarting does not always take changes of the method "createSuitableFilePattern" into account, I need to add/remove some plugins before it works correctly.
Is there a way to bypass that cache ?
Thanks
Gauthier
Please sign in to leave a comment.
I was finally able to implement what I wanted to do like this :
But I still have a lot of questions and misunderstandings. Is there any documentation on how to implement Facets somewhere ?
Thanks,
Gauthier