Package org.exoplatform.services.rest.ext.provider

Examples of org.exoplatform.services.rest.ext.provider.HierarchicalPropertyEntityProvider


         launcher.service(WebDAVMethods.PROPFIND, getPathWS() + testNode.getPath(), BASE_URI, headers,
            request.getBytes(), null, ctx);

      assertEquals(HTTPStatus.MULTISTATUS, cres.getStatus());

      HierarchicalPropertyEntityProvider provider = new HierarchicalPropertyEntityProvider();
      InputStream inputStream = TestUtils.getResponseAsStream(cres);
      HierarchicalProperty multistatus = provider.readFrom(null, null, null, null, null, inputStream);

      assertEquals(new QName("DAV:", "multistatus"), multistatus.getName());
      assertEquals(1, multistatus.getChildren().size());

      HierarchicalProperty resourceProp = multistatus.getChildren().get(0);
View Full Code Here


   public void testRequestBodyXMLParsing() throws Exception
   {
      String s = "\n<root>\n   <l1>\n\t<l2>hel\nlo</l2>\n  </l1>  \n</root>\n";
      //System.out.println(s);
      HierarchicalProperty hp =
         new HierarchicalPropertyEntityProvider().readFrom(HierarchicalProperty.class, null, null, null, null,
            new ByteArrayInputStream(s.getBytes()));
      assertTrue(hp.getChild(0).getChild(0).getValue().equals("hel\nlo"));
   }
View Full Code Here

TOP

Related Classes of org.exoplatform.services.rest.ext.provider.HierarchicalPropertyEntityProvider

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.