package foundation.route;
|
|
import foundation.json.IJSONWriter;
|
|
public class VirtualPathRoute extends Route {
|
|
private String target;
|
|
public VirtualPathRoute(String from, String target) {
|
super(RouteBrowseCode.FreeResourceURI, from);
|
|
this.target = target;
|
routeType = RouteType.Resource;
|
remark = from + " --> " + target;
|
}
|
|
@Override
|
protected String formateFrom(String from) {
|
return from;
|
}
|
|
@Override
|
public void onWriteJSON(IJSONWriter writer) {
|
writer.write("from", from);
|
writer.write("to", "*");
|
}
|
|
public String getTarget() {
|
return target;
|
}
|
|
}
|