Package org.one.stone.soup.xml

Examples of org.one.stone.soup.xml.XmlElement


    HttpServer server = new HttpServer(XappDB.findElement("xpath.model:xapp-server/mime-types"),name,root);
   
    Vector services = xServer.getElementsByName("http-service");
    for(int loop=0;loop<services.size();loop++)
    {
      XmlElement xService = (XmlElement)services.elementAt(loop);
      String serviceAlias = xService.getAttributeValueByName("name");
      String serviceName = xService.getAttributeValueByName("service");
      XmlElement authentication = xService.getElementByName("authentication-server");
     
      XmlElement xServiceDefinition = XappDB.findElement("xpath.model:xapp-server/services/node()[@name=\""+serviceName+"\"]");
      HttpRouter service = buildService( server,name,xServiceDefinition );
     
      if(authentication!=null)
      {
        String address = authentication.getAttributeValueByName("address");
View Full Code Here


    else if(type.equals("http-load-balance-service"))
    {
      HttpLoadBalancingRouter balancingRouter = new HttpLoadBalancingRouter(name,server.getFileServer());
      router = balancingRouter;
     
      XmlElement balancingServers = xServiceDefinition.getElementByName("http-balance-servers");
      for(int loop=0;loop<balancingServers.getElementCount();loop++)
      {
        XmlElement balancingServer = balancingServers.getElementByIndex(loop);
       
        balancingRouter.addBalancingServer( balancingServer.getAttributeValueByName("address"),Integer.parseInt(balancingServer.getAttributeValueByName("port")) );
      }
    }
   
    if(router!=null)
    {
View Full Code Here

    return (HttpServer)servers.get(name);
  }
 
  public Hashtable getMimeTypes()
  {
    XmlElement mimeTypes = XappDB.findElement("xpath.model:xapp-server/mime-types");
    Hashtable types = XmlHelper.getElementAsHashtable(mimeTypes,"file-extension");

    return types;
  }
View Full Code Here

TOP

Related Classes of org.one.stone.soup.xml.XmlElement

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.