rbd: improve doc comment style for remove & rename

Signed-off-by: John Mulligan <jmulligan@redhat.com>
This commit is contained in:
John Mulligan 2019-12-16 13:56:34 -05:00 committed by Niels de Vos
parent 7c4bd22ee2
commit e63f863edb
1 changed files with 8 additions and 4 deletions

View File

@ -391,9 +391,10 @@ func (image *Image) Clone(snapname string, c_ioctx *rados.IOContext, c_name stri
}, nil
}
// int rbd_remove(rados_ioctx_t io, const char *name);
// int rbd_remove_with_progress(rados_ioctx_t io, const char *name,
// librbd_progress_fn_t cb, void *cbdata);
// Remove the specified rbd image.
//
// Implements:
// int rbd_remove(rados_ioctx_t io, const char *name);
func (image *Image) Remove() error {
if err := image.validate(imageNeedsIOContext | imageNeedsName); err != nil {
return err
@ -418,7 +419,10 @@ func (image *Image) Trash(delay time.Duration) error {
C.uint64_t(delay.Seconds())))
}
// int rbd_rename(rados_ioctx_t src_io_ctx, const char *srcname, const char *destname);
// Rename an rbd image.
//
// Implements:
// int rbd_rename(rados_ioctx_t src_io_ctx, const char *srcname, const char *destname);
func (image *Image) Rename(destname string) error {
if err := image.validate(imageNeedsIOContext | imageNeedsName); err != nil {
return err