Class CarbonServerConfig

java.lang.Object
org.wso2.carbon.rest.api.CarbonServerConfig
All Implemented Interfaces:
org.wso2.carbon.mediation.commons.rest.api.swagger.ServerConfig

public class CarbonServerConfig extends Object implements org.wso2.carbon.mediation.commons.rest.api.swagger.ServerConfig
  • Constructor Details

  • Method Details

    • getHost

      public String getHost(org.apache.synapse.api.API api) throws org.apache.axis2.AxisFault
      Function to retrieve host for the swagger definition Host is extracted from following sources 1. Host configured in API definition 2. WSDLEPRPrefix configured in axis2.xml under http or https transport listeners 3. "hostname" parameter in axis2.xml (combined with http port configured for transport listener) 4. Server (machine) host (combined with http port configured for transport listener)
      Specified by:
      getHost in interface org.wso2.carbon.mediation.commons.rest.api.swagger.ServerConfig
      Parameters:
      api - api that required to retrieve host
      Returns:
      return host
      Throws:
      org.apache.axis2.AxisFault
    • getHost

      public String getHost(String transport) throws org.apache.axis2.AxisFault
      Specified by:
      getHost in interface org.wso2.carbon.mediation.commons.rest.api.swagger.ServerConfig
      Throws:
      org.apache.axis2.AxisFault