0
내가하는 .eml 파일을 가지고 있다는 점에서 내가 문제 동안 속성
Received: by exchange.mail.com
id <[email protected]>; Fri, 5 Aug 2011 19:54:38 +0530
Content-class: urn:content-classes:dsn
Subject: Undeliverable: Prudential mail
Date: Fri, 5 Aug 2011 19:54:38 +0530
MIME-Version: 1.0
Content-Type: multipart/report;
report-type=delivery-status;
boundary="----_=_NextPart_001_01CC537B.684C4154"
This is a multi-part message in MIME format.
아래 메신저려고 할 때 키의 고려 '아이디'와 같은 몇 가지 주요 값 쌍을 파일로 .eml 파일을 읽고,
내가 어떻게 키 - 값의 내 자신의 분리 ...
을 설정할 수 있습니다 (그리고 '=': '' '이'또한 키로서,하지만 내 요구 사항은 기호로 키 - 값을 얻을 수 있습니다 추가 정보 나는 자바 코드를 사용하여 다음과 같습니다 ....)
strMailPath = "E:\\BMT_work\\Sample.eml";
File f = new File(strMailPath);
Properties pro = new Properties();
FileInputStream in = new FileInputStream(f);
pro.load(in);
System.out.println("All key are given: " + pro.keySet());
System.out.println("All values are given: " + pro.values());
ArrayList al = new ArrayList(pro.keySet());
ArrayList al2 = new ArrayList(pro.values());
for (int i = 0; i < al.size(); i++) {
System.out.println((i+1)+" "+al.get(i)+" = "+al2.get(i));
}
감사합니다.