Package org.apache.commons.collections.map

Examples of org.apache.commons.collections.map.ListOrderedMap$ListOrderedMapEntry


        OrderedMap children = (OrderedMap) element2children.get(parent);

        if (children == null) {
            synchronized (this) {
                if (children == null) {
                    children = new ListOrderedMap();

                    for (Iterator i = Schemas.getChildElementParticles(parent.getType(), true)
                                             .iterator(); i.hasNext();) {
                        XSDParticle particle = (XSDParticle) i.next();
                        XSDElementDeclaration child = (XSDElementDeclaration) particle.getContent();
View Full Code Here


    /**
    * Remove the stamp from stack (when resuming)
    */
    private static void popTransactionStartStamp() {
        ListOrderedMap map = (ListOrderedMap) suspendedTxStartStamps.get();
        if (map.size() > 0) {
            transactionStartStamp.set(map.remove(map.lastKey()));
        } else {
            Debug.logError("Error in transaction handling - no saved start stamp found - using NOW.", module);
            transactionStartStamp.set(UtilDateTime.nowTimestamp());
        }
    }
View Full Code Here

     * Retrieve list of published processes available to the current user
     * @param appId Optional filter by appId
     * @return
     */
    public Map<AppDefinition, Collection<WorkflowProcess>> getPublishedProcesses(String appId) {
        Map<AppDefinition, Collection<WorkflowProcess>> appProcessMap = new ListOrderedMap();

        // get list of published apps.
        Collection<AppDefinition> appDefinitionList = null;
        if (appId == null || appId.trim().isEmpty()) {
            // get list of published apps.
            appDefinitionList = appDefinitionDao.findPublishedApps("name", Boolean.FALSE, null, null);
        } else {
            // get specific app
            appDefinitionList = new ArrayList<AppDefinition>();
            Long version = getPublishedVersion(appId);
            if (version != null && version > 0) {
                AppDefinition appDef = getAppDefinition(appId, version.toString());
                if (appDef != null) {
                    appDefinitionList.add(appDef);
                }
            }
        }

        // filter based on availability of processes to run.
        for (Iterator<AppDefinition> i = appDefinitionList.iterator(); i.hasNext();) {
            AppDefinition appDef = i.next();
            Collection<PackageDefinition> packageDefList = appDef.getPackageDefinitionList();
            if (packageDefList != null && !packageDefList.isEmpty()) {
                PackageDefinition packageDef = packageDefList.iterator().next();
                Collection<WorkflowProcess> processList = workflowManager.getProcessList(packageDef.getId(), packageDef.getVersion().toString());
               
                Collection<WorkflowProcess> processListWithPermission = new ArrayList<WorkflowProcess>();
               
                for (WorkflowProcess process : processList) {
                    if (workflowManager.isUserInWhiteList(process.getId())) {
                        processListWithPermission.add(process);
                    }
                }
               
                if (!processListWithPermission.isEmpty()) {
                    appProcessMap.put(appDef, processListWithPermission);
                }
            } else {
                i.remove();
            }
        }
View Full Code Here

    private TimeZoneUtil() {
    }

    public static Map<String, String> getList() {
        if (list == null) {
            list = new ListOrderedMap();

            list.put("-12", "(GMT -12:00) Eniwetok, Kwajalein");
            list.put("-11", "(GMT -11:00) Midway Island, Samoa");
            list.put("-10", "(GMT -10:00) Hawaii");
            list.put("-9", "(GMT -09:00) Alaska");
            list.put("-8", "(GMT -08:00) Pacific Time (US & Canada), Tijuana");
            list.put("-7", "(GMT -07:00) Mountain Time (US & Canada), Arizona");
            list.put("-6", "(GMT -06:00) Central Time (US & Canada), Mexico City");
            list.put("-5", "(GMT -05:00) Eastern Time (US & Canada), Bogota, Lima, Quito");
            list.put("-4", "(GMT -04:00) Atlantic Time (Canada), Caracas, La Paz");
            list.put("-3.5", "(GMT -03:30) Newfoundland");
            list.put("-3", "(GMT -03:00) Brassila, Buenos Aires, Georgetown, Falkland Is");
            list.put("-2", "(GMT -02:00) Mid-Atlantic, Ascension Is., St. Helena");
            list.put("-1", "(GMT -01:00) Azores, Cape Verde Islands");
            list.put("0", "(GMT  00:00) Casablanca, Dublin, Edinburgh, London, Lisbon, Monrovia");
            list.put("1", "(GMT +01:00) Amsterdam, Berlin, Brussels, Madrid, Paris, Rome");
            list.put("2", "(GMT +02:00) Cairo, Helsinki, Kaliningrad, South Africa");
            list.put("3", "(GMT +03:00) Baghdad, Riyadh, Moscow, Nairobi");
            list.put("3.5", "(GMT +03:30) Tehran");
            list.put("4", "(GMT +04:00) Abu Dhabi, Baku, Muscat, Tbilisi");
            list.put("4.5", "(GMT +04:30) Kabul");
            list.put("5", "(GMT +05:00) Ekaterinburg, Islamabad, Karachi, Tashkent");
            list.put("5.5", "(GMT +05:30) Bombay, Calcutta, Madras, New Delhi");
            list.put("5.75", "(GMT +05:45) Katmandu");
            list.put("6", "(GMT +06:00) Almaty, Colombo, Dhaka, Novosibirsk");
            list.put("6.5", "(GMT +06:30) Rangoon");
            list.put("7", "(GMT +07:00) Bangkok, Hanoi, Jakarta");
            list.put("8", "(GMT +08:00) Beijing, Hong Kong, Perth, Kuala Lumpur, Singapore, Taipei");
            list.put("9", "(GMT +09:00) Osaka, Sapporo, Seoul, Tokyo, Yakutsk");
            list.put("9.5", "(GMT +09:30) Adelaide, Darwin");
            list.put("10", "(GMT +10:00) Canberra, Guam, Melbourne, Sydney, Vladivostok");
            list.put("11", "(GMT +11:00) Magadan, New Caledonia, Solomon Islands");
            list.put("12", "(GMT +12:00) Auckland, Wellington, Fiji, Marshall Island");
           
            String[] timezones = TimeZone.getAvailableIDs();
            List<String> sortedKeys=new ArrayList<String>(Arrays.asList(timezones));
            Collections.sort(sortedKeys);
           
            ListOrderedMap otherList = new ListOrderedMap();
            for (String tzid : sortedKeys) {
                TimeZone tz = TimeZone.getTimeZone(tzid);
                if (!tz.getDisplayName(true, TimeZone.SHORT).startsWith("GMT")) {
                    String display = "(" + tz.getDisplayName(true, TimeZone.SHORT) + ") ";
                    String tzname = tzid.replace("/", " - ");
                    tzname = tzname.replace("_", " ");
                    display += tzname;
                    otherList.put(tzid, display);
                }
            }
           
            list.putAll(otherList);
        }
View Full Code Here

        return "console/apps/builderItems";
    }

    protected Map<String, String> getPluginType() {
        Map<String, String> pluginTypeMap = new ListOrderedMap();
        pluginTypeMap.put("org.joget.plugin.base.AuditTrailPlugin", "Audit Trail");
        pluginTypeMap.put("org.joget.apps.datalist.model.DataListAction", "Data List Action");
        pluginTypeMap.put("org.joget.apps.datalist.model.DataListBinder", "Data List Binder");
        pluginTypeMap.put("org.joget.apps.datalist.model.DataListColumnFormat", "Data List Column Format");
        pluginTypeMap.put("org.joget.apps.datalist.model.DataListFilterType", "Data List Filter Type");
        pluginTypeMap.put("org.joget.workflow.model.DeadlinePlugin", "Deadline");
        pluginTypeMap.put("org.joget.directory.model.service.DirectoryManagerPlugin", "Directory Manager");
        pluginTypeMap.put("org.joget.apps.form.model.Element", "Form Element");
        pluginTypeMap.put("org.joget.apps.form.model.FormLoadElementBinder", "Form Load Binder");
        pluginTypeMap.put("org.joget.apps.form.model.FormLoadOptionsBinder", "Form Options Binder");
        pluginTypeMap.put("org.joget.apps.form.model.FormStoreBinder", "Form Store Binder");
        pluginTypeMap.put("org.joget.apps.form.model.FormPermission", "Form Permission");
        pluginTypeMap.put("org.joget.apps.form.model.FormValidator", "Form Validator");
        pluginTypeMap.put("org.joget.apps.app.model.HashVariablePlugin", "Hash Variable");
        pluginTypeMap.put("org.joget.workflow.model.ParticipantPlugin", "Process Participant");
        pluginTypeMap.put("org.joget.plugin.base.ApplicationPlugin", "Process Tool");
        pluginTypeMap.put("org.joget.apps.userview.model.UserviewMenu", "Userview Menu");
        pluginTypeMap.put("org.joget.apps.userview.model.UserviewPermission", "Userview Permission");
        pluginTypeMap.put("org.joget.apps.userview.model.UserviewTheme", "Userview Theme");

        return pluginTypeMap;
    }
View Full Code Here

        return pluginTypeMap;
    }

    protected Map<String, String> getPluginTypeForDefaultProperty() {
        Map<String, String> pluginTypeMap = new ListOrderedMap();
        pluginTypeMap.put("org.joget.plugin.base.AuditTrailPlugin", "Audit Trail");
        pluginTypeMap.put("org.joget.workflow.model.DeadlinePlugin", "Deadline");
        pluginTypeMap.put("org.joget.workflow.model.ParticipantPlugin", "Process Participant");
        pluginTypeMap.put("org.joget.plugin.base.ApplicationPlugin", "Process Tool");

        return pluginTypeMap;
    }
View Full Code Here

TOP

Related Classes of org.apache.commons.collections.map.ListOrderedMap$ListOrderedMapEntry

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.