mirror of
https://github.com/ceph/go-ceph
synced 2024-12-23 22:53:47 +00:00
rados: fix doc comments for object iter related functions
This is a minor cleanup that only stops the checker from complaining rather than actually improving the documentation. Signed-off-by: John Mulligan <jmulligan@redhat.com>
This commit is contained in:
parent
9efbfd8518
commit
176e6cc198
@ -5,6 +5,7 @@ package rados
|
|||||||
//
|
//
|
||||||
import "C"
|
import "C"
|
||||||
|
|
||||||
|
// Iter supports iterating over objects in the ioctx.
|
||||||
type Iter struct {
|
type Iter struct {
|
||||||
ctx C.rados_list_ctx_t
|
ctx C.rados_list_ctx_t
|
||||||
err error
|
err error
|
||||||
@ -12,6 +13,7 @@ type Iter struct {
|
|||||||
namespace string
|
namespace string
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// IterToken supports reporting on and seeking to different positions.
|
||||||
type IterToken uint32
|
type IterToken uint32
|
||||||
|
|
||||||
// Iter returns a Iterator object that can be used to list the object names in the current pool
|
// Iter returns a Iterator object that can be used to list the object names in the current pool
|
||||||
@ -28,6 +30,7 @@ func (iter *Iter) Token() IterToken {
|
|||||||
return IterToken(C.rados_nobjects_list_get_pg_hash_position(iter.ctx))
|
return IterToken(C.rados_nobjects_list_get_pg_hash_position(iter.ctx))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Seek moves the iterator to the position indicated by the token.
|
||||||
func (iter *Iter) Seek(token IterToken) {
|
func (iter *Iter) Seek(token IterToken) {
|
||||||
C.rados_nobjects_list_seek(iter.ctx, C.uint32_t(token))
|
C.rados_nobjects_list_seek(iter.ctx, C.uint32_t(token))
|
||||||
}
|
}
|
||||||
@ -82,7 +85,7 @@ func (iter *Iter) Err() error {
|
|||||||
return iter.err
|
return iter.err
|
||||||
}
|
}
|
||||||
|
|
||||||
// Closes the iterator cursor on the server. Be aware that iterators are not closed automatically
|
// Close the iterator cursor on the server. Be aware that iterators are not closed automatically
|
||||||
// at the end of iteration.
|
// at the end of iteration.
|
||||||
func (iter *Iter) Close() {
|
func (iter *Iter) Close() {
|
||||||
C.rados_nobjects_list_close(iter.ctx)
|
C.rados_nobjects_list_close(iter.ctx)
|
||||||
|
Loading…
Reference in New Issue
Block a user