com.wordnik.swagger.jaxrs.ext.SwaggerExtensions Maven / Gradle / Ivy
package com.wordnik.swagger.jaxrs.ext;
import com.wordnik.swagger.jaxrs.DefaultParameterExtension;
import java.util.ServiceLoader;
import java.util.*;
public class SwaggerExtensions {
private static List extensions = null;
static {
extensions = new ArrayList();
ServiceLoader loader = ServiceLoader.load(SwaggerExtension.class);
Iterator itr = loader.iterator();
while(itr.hasNext()) {
extensions.add(itr.next());
}
extensions.add(new DefaultParameterExtension());
}
public static List getExtensions() {
return extensions;
}
public static Iterator chain() {
return extensions.iterator();
}
}