private DeferredComparison compareDeclarations ( final Document control , final XPathContext controlContext , final Document test , final XPathContext testContext ) { return new DeferredComparison ( ) { @ Override public ComparisonState apply ( ) { return compare ( new Comparison ( ComparisonType . XML_VERSION , control , getXPath ( controlContext ) , control . getXmlVersion ( ) , getParentXPath ( controlContext ) , test , getXPath ( testContext ) , test . getXmlVersion ( ) , getParentXPath ( testContext ) ) ) . andThen ( new Comparison ( ComparisonType . XML_STANDALONE , control , getXPath ( controlContext ) , control . getXmlStandalone ( ) , getParentXPath ( controlContext ) , test , getXPath ( testContext ) , test . getXmlStandalone ( ) , getParentXPath ( testContext ) ) ) . andThen ( new Comparison ( ComparisonType . XML_ENCODING , control , getXPath ( controlContext ) , control . getXmlEncoding ( ) , getParentXPath ( controlContext ) , test , getXPath ( testContext ) , test . getXmlEncoding ( ) , getParentXPath ( testContext ) ) ) ; } } ; }
Compares properties of XML declaration .