From 477d7014edc787ba9a977acd19fcbfc55531768b Mon Sep 17 00:00:00 2001 From: Quentin Dufour Date: Thu, 16 Sep 2021 13:41:01 +0200 Subject: Vendor goldap --- goldap/del_response.go | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 goldap/del_response.go (limited to 'goldap/del_response.go') diff --git a/goldap/del_response.go b/goldap/del_response.go new file mode 100644 index 0000000..f2e14a7 --- /dev/null +++ b/goldap/del_response.go @@ -0,0 +1,29 @@ +package message + +import "fmt" + +// +// DelResponse ::= [APPLICATION 11] LDAPResult + +func (del *DelResponse) SetResultCode(code int) { + del.resultCode = ENUMERATED(code) +} + +func readDelResponse(bytes *Bytes) (ret DelResponse, err error) { + var res LDAPResult + res, err = readTaggedLDAPResult(bytes, classApplication, TagDelResponse) + if err != nil { + err = LdapError{fmt.Sprintf("readDelResponse:\n%s", err.Error())} + return + } + ret = DelResponse(res) + return +} + +func (del DelResponse) write(bytes *Bytes) int { + return LDAPResult(del).writeTagged(bytes, classApplication, TagDelResponse) +} + +func (del DelResponse) size() int { + return LDAPResult(del).sizeTagged(TagDelResponse) +} -- cgit v1.2.3