.
This commit is contained in:
parent
10a286d71d
commit
044edefa12
|
@ -8,31 +8,32 @@ import java.util.Map;
|
|||
*/
|
||||
public abstract class Crawler {
|
||||
|
||||
public Object add(String id) throws Exception {
|
||||
private Map<String,Map<String,Object>> configs;
|
||||
|
||||
public Object add(String id) throws Exception {
|
||||
return null;
|
||||
}
|
||||
|
||||
public Object get(String id) throws Exception {
|
||||
|
||||
return getInternal(getConfig(id));
|
||||
|
||||
}
|
||||
|
||||
protected abstract Object getInternal(Map<String, Object> params) throws Exception;
|
||||
|
||||
public Map<String,Object> getConfig(String id) throws Exception {
|
||||
|
||||
return null;
|
||||
return configs.get(id);
|
||||
}
|
||||
|
||||
public Object init(String config) throws Exception {
|
||||
public void putConfig(String id,Map<String,Object> o) throws Exception {
|
||||
configs.put(id,o);
|
||||
}
|
||||
|
||||
|
||||
public Object init(String config) throws Exception {
|
||||
return null;
|
||||
}
|
||||
|
||||
public Object remove(String id) throws Exception {
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user