this.uri = uri;
}
protected String createHref(String uri, Endpoint endpoint) {
if (endpoint instanceof HasId) {
HasId hasId = (HasId) endpoint;
String id = hasId.getId();
return "/endpoints/" + id;
} else {
// must not include :// in endpoint link
// TODO: might need to use org.apache.camel.util.UnsafeUriCharactersEncoder to safely encode URI for the web
return "/endpoints/" + UriCharactersEncoder.encode(uri);