1 | while (it.hasNext()) {↵ | | |
|
2 | try {↵ | | |
|
3 | String addrStr = it.next();↵ | | |
|
4 | if (addrSt↵ | | 1 | try {↵
|
5 | r == null)↵ | | 2 | IExtensionHandler handler = ↵
|
6 | continue;↵ | | |
|
7 | Address address = Address.parse(addrStr);↵ | | |
|
|
8 | // add contact to addressbook↵ | | |
|
9 | IContactItem contactItem = modelFacade.createContactItem(↵ | | 3 | PluginManager↵
|
10 | );↵ | | 4 | .getInstance().getExtensionHandler(IExtensionHandlerKeys.ORG_COLUMBA_MAIL_SPAM);↵
|
11 | ↵ | | |
|
12 | FacadeUtil.getInstance().initContactItem(contactItem, address.getDisplayName(), address.getMailAddress());↵ | | 5 | IExtension extension = handler.getExtension("SpamAssassin");↵
|
|
13 | contactItems.add(contactItem);↵ | | 6 | spamPlugin = (ISpamPlugin) extension.instanciateExtension(null);↵
|
14 | ↵ | | |
|
15 | } catch (ParserException e) {↵ | | 7 | } catch (PluginHandlerNotFoundException e) {↵
|
| | | 8 | LOG.severe(e.getMessage());↵
|
| | | 9 | if (Logging.DEBUG)↵
|
16 | e.printStackTrace();↵ | | 10 | e.printStackTrace();↵
|
17 | ↵ | | |
|
18 | } catch (StoreException e) {↵ | | 11 | } catch (PluginException e) {↵
|
19 | ↵ | | 12 | LOG.severe(e.getMessage());↵
|
| | | 13 | if (Logging.DEBUG)↵
|
20 | e.printStackTrace();↵ | | 14 | e.printStackTrace();↵
|
21 | }↵ | | 15 | ↵
|
22 | } | | 16 | }
|