Documentation ¶
Index ¶
- type ToDDApi
- func (tapi ToDDApi) Agent(w http.ResponseWriter, r *http.Request)
- func (tapi ToDDApi) CreateObject(w http.ResponseWriter, r *http.Request)
- func (tapi ToDDApi) DeleteObject(w http.ResponseWriter, r *http.Request)
- func (tapi ToDDApi) Groups(w http.ResponseWriter, r *http.Request)
- func (tapi ToDDApi) ListObjects(w http.ResponseWriter, r *http.Request)
- func (tapi ToDDApi) Run(w http.ResponseWriter, r *http.Request)
- func (tapi ToDDApi) Start(cfg config.Config) error
- func (tapi ToDDApi) TestData(w http.ResponseWriter, r *http.Request)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ToDDApi ¶
type ToDDApi struct {
// contains filtered or unexported fields
}
func (ToDDApi) CreateObject ¶
func (tapi ToDDApi) CreateObject(w http.ResponseWriter, r *http.Request)
CreateObject will decode a JSON object into a proper ToddObject instance, and send that to the database layer to be written persistently.
func (ToDDApi) DeleteObject ¶
func (tapi ToDDApi) DeleteObject(w http.ResponseWriter, r *http.Request)
DeleteObject will decode a JSON object from a client request to determine the type and label of the object that needs to be deleted. Then, it will send this information to the database layer to delete this object.
func (ToDDApi) ListObjects ¶
func (tapi ToDDApi) ListObjects(w http.ResponseWriter, r *http.Request)
ListObjects will query the database layer for a slice of objects based on the parameters provided in the URL. The client may ask for a specific type of object by using the "/all" notation after the object keyword in the URL, or this may be a specific type, such as "/group".
Click to show internal directories.
Click to hide internal directories.