public class FilterLoader
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static class |
FilterLoader.TestZuulFilter |
| Constructor and Description |
|---|
FilterLoader() |
| Modifier and Type | Method and Description |
|---|---|
int |
filterInstanceMapSize() |
ZuulFilter |
getFilter(java.lang.String sCode,
java.lang.String sName)
Given source and name will compile and store the filter if it detects that the filter code has changed or
the filter doesn't exist.
|
java.util.List<ZuulFilter> |
getFiltersByType(java.lang.String filterType)
Returns a list of filters by the filterType specified
|
static FilterLoader |
getInstance() |
boolean |
putFilter(java.io.File file)
From a file this will read the ZuulFilter source code, compile it, and add it to the list of current filters
a true response means that it was successful.
|
void |
setCompiler(DynamicCodeCompiler compiler)
Sets a Dynamic Code Compiler
|
void |
setFilterFactory(FilterFactory factory)
Sets a FilterFactory
|
void |
setFilterRegistry(FilterRegistry r) |
public void setCompiler(DynamicCodeCompiler compiler)
compiler - public void setFilterRegistry(FilterRegistry r)
public void setFilterFactory(FilterFactory factory)
factory - public static FilterLoader getInstance()
public ZuulFilter getFilter(java.lang.String sCode, java.lang.String sName) throws java.lang.Exception
sCode - source codesName - name of the filterjava.lang.IllegalAccessExceptionjava.lang.InstantiationExceptionjava.lang.Exceptionpublic int filterInstanceMapSize()
public boolean putFilter(java.io.File file)
throws java.lang.Exception
file - java.lang.IllegalAccessExceptionjava.lang.InstantiationExceptionjava.io.IOExceptionjava.lang.Exceptionpublic java.util.List<ZuulFilter> getFiltersByType(java.lang.String filterType)
filterType -