Coverage report

  %line %branch
com.ozacc.mail.fetch.impl.sk_jp.HtmlPartExtractor
0% 
0% 

 1  
 /*
 2  
  * @(#) $Id: HtmlPartExtractor.java,v 1.1.2.1 2004/09/29 00:57:59 otsuka Exp $
 3  
  * $Revision: 1.1.2.1 $
 4  
  * Copyright (c) 2000 Shin Kinoshita All Rights Reserved.
 5  
  */
 6  
 package com.ozacc.mail.fetch.impl.sk_jp;
 7  
 
 8  
 import java.io.IOException;
 9  
 
 10  
 import javax.mail.MessagingException;
 11  
 import javax.mail.Part;
 12  
 import javax.mail.internet.ContentType;
 13  
 
 14  
 /**
 15  
  * text/html¤ò·?¹ç¤·¤¿Ê¸»úÎó¤òÆÀ¤?PartHandler¤Ç¤¹¡£
 16  
  * 
 17  
  * @version $Revision: 1.1.2.1 $ $Date: 2004/09/29 00:57:59 $
 18  
  * @author Shin
 19  
  */
 20  0
 public class HtmlPartExtractor implements PartHandler {
 21  
 
 22  0
 	private String html = null;
 23  
 
 24  
 	public boolean processPart(Part part, ContentType context) throws MessagingException,
 25  
 																IOException {
 26  0
 		if (!part.isMimeType("text/html")) {
 27  0
 			return true;
 28  
 		}
 29  0
 		if (html == null) {
 30  
 			// ºÇ½é¤Î¥Æ¥­¥¹¥È¥Ñ¡¼¥È¤ò̵¾ò·?¤ËÃ?½Ð
 31  0
 			html = (String)MultipartUtility.getContent(part);
 32  
 		} else {
 33  0
 			String disposition = part.getDisposition();
 34  0
 			if (disposition == null || disposition.equalsIgnoreCase(Part.INLINE)) {
 35  0
 				html += "\r\n\r\n-- inline --\r\n\r\n" + (String)MultipartUtility.getContent(part);
 36  
 			}
 37  
 		}
 38  0
 		return true;
 39  
 	}
 40  
 
 41  
 	public String getHtml() {
 42  0
 		return html;
 43  
 	}
 44  
 
 45  
 }

This report is generated by jcoverage, Maven and Maven JCoverage Plugin.