Example #1
0
/* Return the query_string of this query. See notmuch_query_create. */
func (self *Query) String() string {
	// FIXME: do we own 'q' or not ?
	q := C.notmuch_query_get_query_string(self.query)
	//defer C.free(unsafe.Pointer(q))

	if q != nil {
		s := C.GoString(q)
		return s
	}

	return ""
}
Example #2
0
File: query.go Project: gmuch/gmuch
// String returns the query as a string, implements fmt.Stringer.
func (q *Query) String() string {
	return C.GoString(C.notmuch_query_get_query_string(q.toC()))
}