public String buildNotFoundMessage(final DocRef docRef) {
        if (docRef != null) {
            final String type = NullSafe.requireNonNullElseGet(this.itemType, () ->
                    NullSafe.requireNonNullElse(docRef.getType(), "Document"));
            final String uuid = docRef.getUuid();
            final String displayName = NullSafe.getOrElse(
                    docRef.getName(),
                    name -> "'" + name + "' (" + uuid + ")",
                    uuid);

            return type +
                   " " +
                   displayName +
                   " doesn't exist or you do not have permission to view it.\n" +
                   "Select a different " + type.toLowerCase() + " or speak to your administrator.";
        } else {
            return null;
        }
    }
@param docRef             The {@link DocRef} to set as the selected value of the dropdown.
                          If docRef does not exist or is not visible to the user, a warning
                          will be displayed but the value will be as passed.
@param decorateDocRef     If true, force decorate docRef to ensure it has the correct name.
                          Set to false if you know docRef has an up-to-date name, is a constant,
                          is definitely null, or you don't care.
@param onDocRefDecoration Called when docRef is found to be different to a
                          decorated version of it, e.g. it's name has changed.
@param onDocRefNotFound   Called docRef does not exist, e.g. it has been deleted
                          or its permissions have changed.
stroom-core-client/src/main/java/stroom/explorer/client/presenter/DocSelectionBoxPresenter.java