com.github.dreamhead.moco.matcher
Class XmlRequestMatcher

java.lang.Object
  extended by com.github.dreamhead.moco.matcher.XmlRequestMatcher
All Implemented Interfaces:
ConfigApplier<RequestMatcher>, RequestMatcher

public class XmlRequestMatcher
extends java.lang.Object
implements RequestMatcher


Constructor Summary
XmlRequestMatcher(RequestExtractor<java.lang.String> extractor, Resource resource)
           
 
Method Summary
 RequestMatcher apply(MocoConfig config)
           
 javax.xml.parsers.DocumentBuilder documentBuilder()
           
 org.w3c.dom.Document extractDocument(org.xml.sax.InputSource inputSource, XmlRequestMatcher xmlRequestMatcher)
           
 boolean match(io.netty.handler.codec.http.FullHttpRequest request)
           
 void trimChild(org.w3c.dom.Node node, org.w3c.dom.Node child)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XmlRequestMatcher

public XmlRequestMatcher(RequestExtractor<java.lang.String> extractor,
                         Resource resource)
Method Detail

match

public boolean match(io.netty.handler.codec.http.FullHttpRequest request)
Specified by:
match in interface RequestMatcher

apply

public RequestMatcher apply(MocoConfig config)
Specified by:
apply in interface ConfigApplier<RequestMatcher>

trimChild

public void trimChild(org.w3c.dom.Node node,
                      org.w3c.dom.Node child)

documentBuilder

public javax.xml.parsers.DocumentBuilder documentBuilder()

extractDocument

public org.w3c.dom.Document extractDocument(org.xml.sax.InputSource inputSource,
                                            XmlRequestMatcher xmlRequestMatcher)
                                     throws org.xml.sax.SAXException
Throws:
org.xml.sax.SAXException