Package org.exoplatform.services.html.util

Examples of org.exoplatform.services.html.util.URLCreator


      assertEquals("tr", new String(row2Node.getValue()));
      //System.out.println("ROW2: " + row2Node.getTextValue());
      HTMLNode row2Cell2 = row2Node.getChildrenNode().get(1);

      assertNotNull(new URL("http://www.mysite.net"));
      URLCreator urlCreator = new URLCreator();
      hyperlinkUtil.createFullNormalLink(row2Cell2, new URL("http://www.mysite.net"), urlCreator);
      linkList.clear();
      linkList = hyperlinkUtil.getSiteLink(document.getRoot());
      System.out.println("\nSHOW ALL HYPERLINKs: ");
      for (int i = 0; i < linkList.size(); i++)
      {
         System.out.println(linkList.get(i).toString());
      }

      //CreateFullImageLink.-----------------------------------------------------------------------
      hyperlinkUtil.createFullImageLink(document.getRoot(), new URL("http://www.myImageLink.net"));
      System.out.println("\nNEW IMAGE_LINK1:" + hyperlinkUtil.getSingleImageLink(document.getRoot()));
      hyperlinkUtil.createFullImageLink(document.getRoot(), new URL("http://www.exo.com"), new URLCreator());
      System.out.println("\nNEW IMAGE_LINK2:" + hyperlinkUtil.getSingleImageLink(document.getRoot()));
   }
View Full Code Here


   }

   public void testURLCreator() throws Exception
   {
      String link = "";
      URLCreator urlCreator = new URLCreator();
      link = urlCreator.createURL("http://www.dantri.com.vn", "default.aspx?sub_id=1");
      System.out.println("\n\nLINK: " + link);
   }
View Full Code Here

TOP

Related Classes of org.exoplatform.services.html.util.URLCreator

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.