Search in sources :

Example 6 with Version

use of org.apache.knox.gateway.topology.Version in project knox by apache.

the class BeanConverter method getApplication.

private static org.apache.knox.gateway.topology.Application getApplication(Application application) {
    org.apache.knox.gateway.topology.Application applicationResource = new org.apache.knox.gateway.topology.Application();
    applicationResource.setRole(application.getRole());
    applicationResource.setName(application.getName());
    if (application.getVersion() != null) {
        applicationResource.setVersion(new Version(application.getVersion()));
    }
    for (Param param : application.getParams()) {
        applicationResource.addParam(getParam(param));
    }
    for (String url : application.getUrls()) {
        applicationResource.getUrls().add(url);
    }
    return applicationResource;
}
Also used : Version(org.apache.knox.gateway.topology.Version)

Aggregations

Version (org.apache.knox.gateway.topology.Version)6 File (java.io.File)2 URL (java.net.URL)2 Digester (org.apache.commons.digester3.Digester)2 Provider (org.apache.knox.gateway.topology.Provider)2 Service (org.apache.knox.gateway.topology.Service)2 Topology (org.apache.knox.gateway.topology.Topology)2 TopologyBuilder (org.apache.knox.gateway.topology.builder.TopologyBuilder)2 Test (org.junit.Test)2