private TreeMap<String, RestLink> unAuthorizedLinks = new TreeMap<>();
private TreeMap<String, RestLink> authorizedLinks = new TreeMap<>();
public Setting() {
RestLink rl;
// unAuthorizedLinks
// rl = new RestLink();
// rl.setRel("links");
// rl.setContentType(MediaType.APPLICATION_JSON);
// rl.setAccept(MediaType.APPLICATION_JSON);
// rl.setRequestMethod(HttpMethod.GET);
// rl.setUrl("rest/login");
// unAuthorizedLinks.put(rl.getRel(), rl);
//
// rl = new RestLink();
// rl.setRel("logIn");
// rl.setContentType(MediaType.APPLICATION_JSON);
// rl.setAccept(CONTENT_TYPE_LOGIN_ANSWER_JSON);
// rl.setRequestMethod(HttpMethod.POST);
// rl.setUrl("rest/login");
// unAuthorizedLinks.put(rl.getRel(), rl);
// authorizedLinks
// rl = new RestLink();
// rl.setRel("lock");
// rl.setContentType(MediaType.APPLICATION_JSON);
// rl.setAccept(MediaType.APPLICATION_JSON);
// rl.setRequestMethod(HttpMethod.POST);
// rl.setUrl("rest/login/lock");
// authorizedLinks.put(rl.getRel(), rl);
//
// rl = new RestLink();
// rl.setRel("buyTime");
// rl.setContentType(MediaType.APPLICATION_JSON);
// rl.setAccept(CONTENT_TYPE_LOGIN_ANSWER_JSON);
// rl.setRequestMethod(HttpMethod.PUT);
// rl.setUrl("rest/login/changeToId");
// authorizedLinks.put(rl.getRel(), rl);
//
// rl = new RestLink();
// rl.setRel("logOut");
// rl.setContentType(MediaType.APPLICATION_JSON);
// rl.setAccept(CONTENT_TYPE_LOGIN_ANSWER_JSON);
// rl.setRequestMethod(HttpMethod.DELETE);
// rl.setUrl("rest/login/changeToId");
// authorizedLinks.put(rl.getRel(), rl);
rl = new RestLink();
rl.setRel("settingStore");
rl.setContentType(MediaType.APPLICATION_JSON);
rl.setAccept(CONTENT_TYPE_GUI_SETTING_JSON);
rl.setRequestMethod(HttpMethod.PUT);
rl.setUrl("rest/setting/changeToId");
authorizedLinks.put(rl.getRel(), rl);
}