func (h *handler) ServeHTTP(responseWriter http.ResponseWriter, request *http.Request) error {
	token, err := server_idparser.ParseKeyFormRequest(request)
	if err != nil {
		return err
	}
	model, err := h.getModelByToken(token)
	if err != nil {
		return err
	}
	responseWriter.Header().Set("Content-Type", "text/vcard")
	responseWriter.WriteHeader(http.StatusOK)
	return h.writeModelAsVCard(responseWriter, model)
}
func (h *handler) ServeHTTP(responseWriter http.ResponseWriter, request *http.Request) error {
	token, err := server_idparser.ParseKeyFormRequest(request)
	if err != nil {
		return err
	}
	expectedToken := h.getStringDefault(CALENDAR_TOKEN_KEY, CALENDAR_TOKEN_DEFAULT)
	if token != expectedToken {
		return fmt.Errorf("permission denied")
	}
	responseWriter.Header().Set("Content-Type", "text/calendar")
	responseWriter.WriteHeader(http.StatusOK)
	return h.writeCalendar(responseWriter)
}
func (h *handler) ServeHTTP(responseWriter http.ResponseWriter, request *http.Request) error {
	glog.V(2).Infof("delete config")
	key, err := server_idparser.ParseKeyFormRequest(request)
	if err != nil {
		return err
	}
	obj, err := h.delete(key)
	if err != nil {
		return err
	}
	go h.protocol(request, "config/delete", obj)
	j := json_handler.New(obj)
	j.ServeHTTP(responseWriter, request)
	return nil
}
func (h *handler) ServeHTTP(responseWriter http.ResponseWriter, request *http.Request) error {
	glog.V(2).Infof("get config")
	key, err := server_idparser.ParseKeyFormRequest(request)
	if err != nil {
		return err
	}
	glog.V(2).Infof("get config %s", key)
	obj, err := h.get(key)
	if err != nil {
		return err
	}
	j := json_handler.New(obj)
	j.ServeHTTP(responseWriter, request)
	return nil
}