Search in sources :

Example 6 with JournalFilterManager

use of de.janrufmonitor.ui.jface.application.journal.JournalFilterManager in project janrufmonitor by tbrandt77.

the class Last10Calls method getConfiguration.

public Properties getConfiguration() {
    Properties saved = super.getConfiguration();
    Properties journalConfig = this.getRuntime().getConfigManagerFactory().getConfigManager().getProperties(Journal.NAMESPACE);
    if (journalConfig != null && journalConfig.size() > 0) {
        saved.setProperty(JournalConfigConst.CFG_REPOSITORY, journalConfig.getProperty(JournalConfigConst.CFG_REPOSITORY));
    }
    IFilter[] filters = new IFilter[1];
    int count = 10;
    try {
        count = Integer.parseInt(saved.getProperty(CFG_COUNT, "10"));
    } catch (Exception e) {
    }
    filters[0] = new ItemCountFilter(count);
    saved.setProperty("filter", new JournalFilterManager().getFiltersToString(filters));
    return saved;
}
Also used : IFilter(de.janrufmonitor.repository.filter.IFilter) ItemCountFilter(de.janrufmonitor.repository.filter.ItemCountFilter) JournalFilterManager(de.janrufmonitor.ui.jface.application.journal.JournalFilterManager) Properties(java.util.Properties)

Aggregations

JournalFilterManager (de.janrufmonitor.ui.jface.application.journal.JournalFilterManager)6 IFilter (de.janrufmonitor.repository.filter.IFilter)5 IFilterManager (de.janrufmonitor.ui.jface.application.IFilterManager)4 Properties (java.util.Properties)3 IPhonenumber (de.janrufmonitor.framework.IPhonenumber)2 ItemCountFilter (de.janrufmonitor.repository.filter.ItemCountFilter)2 ArrayList (java.util.ArrayList)2 List (java.util.List)2 IAttributeMap (de.janrufmonitor.framework.IAttributeMap)1 ICip (de.janrufmonitor.framework.ICip)1 IMsn (de.janrufmonitor.framework.IMsn)1 IMultiPhoneCaller (de.janrufmonitor.framework.IMultiPhoneCaller)1 AttributeFilter (de.janrufmonitor.repository.filter.AttributeFilter)1 CipFilter (de.janrufmonitor.repository.filter.CipFilter)1 MsnFilter (de.janrufmonitor.repository.filter.MsnFilter)1 PhonenumberFilter (de.janrufmonitor.repository.filter.PhonenumberFilter)1 FilterCallTypePage (de.janrufmonitor.ui.jface.wizards.pages.FilterCallTypePage)1 FilterCipPage (de.janrufmonitor.ui.jface.wizards.pages.FilterCipPage)1 FilterDatePage (de.janrufmonitor.ui.jface.wizards.pages.FilterDatePage)1 FilterItemCountPage (de.janrufmonitor.ui.jface.wizards.pages.FilterItemCountPage)1