}
protected void handleImageRel(ConversionImageHandler imageHandler, String imgRelId, Part sourcePart) {
Relationship rel = sourcePart.getRelationshipsPart().getRelationshipByID(imgRelId);
Part part = null;
String uri = null;
boolean ignoreImage = false;
setID(imgRelId);
part = sourcePart.getRelationshipsPart().getPart(rel);
/* a part == null is ok if it is an external image,
* and hasn't been loaded (loadExternalTargets == false)
* but the relationship can be external,
* but the part avaiable (loadExternalTargets == true)
*/
if ((part != null) && (!(part instanceof BinaryPart))) {
log.error("Invalid part type id: " + imgRelId + ", class = " + part.getClass().getName());
ignoreImage = true;
}
if (!ignoreImage) {
uri = handlePart(imageHandler, this, rel, (BinaryPart)part);
if (uri != null) {