class LienzoPictureUtils {

    public static void tryDestroy(final Picture picture,
                                  final Consumer<Picture> retryCallback) {
        // Destroy the <img..> related to the Glyph added to the DOM root by Picture's use of ImageLoader.
        // If the image has not completed loading attempts to remove from the DOM result in an error; therefore
        // schedule successive attempts until success.
        if (!retryDestroy(picture)) {
            retryCallback.accept(picture);
        }
    }

}