Package org.apache.commons.collections.map

Examples of org.apache.commons.collections.map.MultiKeyMap


        final QName service = (QName) map.get("service");
        final String port = (String) map.get("port");
        EndpointConfiguration endpointConfig = null;

        if (bpelPackageConfiguration != null) {
            MultiKeyMap endpointConfigs = bpelPackageConfiguration.getEndpoints();
            if (endpointConfigs.size() > 0) {
                endpointConfig = (EndpointConfiguration) endpointConfigs.get(service.getLocalPart(),
                                                            service.getNamespaceURI(), port);
                if (endpointConfig == null) {
                    endpointConfig = (EndpointConfiguration) endpointConfigs.get(
                            service.getLocalPart(), service.getNamespaceURI(), null);
                }
            }
        }
        return endpointConfig;
View Full Code Here


   * la 86 chei pe row si 212 chei pe column am 18.232 (86 x 212) combinatii.
   * Daca in getValues se sta 3,25 ms (cum am obtinut) rezulta un total de
   * 5576 ms. Cred ca ar trebuii sa parcurg o singura data inregistrarile din baza.
   */
  private MultiKeyMap getData(PivotField dataField) {
    MultiKeyMap data = new MultiKeyMap();
    List<List<Object>> rowKeys = getRowKeys();
    System.out.println("rowKeys.size() = " + rowKeys.size());
    List<List<Object>> columnKeys = getColumnKeys();
    System.out.println("columnKeys.size() = " + columnKeys.size());
   
    List<PivotField> rowFields = getFields(PivotField.Area.ROW);
    List<PivotField> columnFields = getFields(PivotField.Area.COLUMN);
    for (List<Object> rowKey : rowKeys) {
      for (List<Object> columnKey : columnKeys) {
        Map<Integer, Object> rowFilter = getFilter(rowFields, rowKey);
        Map<Integer, Object> columnFilter = getFilter(columnFields, columnKey);
        final Map<Integer, Object> filter = new HashMap<Integer, Object>(rowFilter);
        filter.putAll(columnFilter);       
        List<Object> values = getValues(dataField, filter);
        if (!CollectionUtils.isEmpty(values) || dataField.getFieldCalculation()!=null) {
          /*
          System.out.println("filter = " + filter);
          System.out.println("values = " + values);
          System.out.println(values.size());
          */
          Object summary = PivotUtils.getSummary(dataField, values, new FieldValueProvider() {           
            @Override
            public Object getFieldValue(PivotField field) {         
              List<Object> fieldValues = getValues(field, filter);
              return field.getAggregator().init().addAll(fieldValues).getResult();
            }
          });
//          System.out.println("summary = " + summary);
          data.put(rowKey, columnKey, summary);
        }
      }
    }
   
    return data;
View Full Code Here

        if (cachedValues == null) {
            if ( value == null) {
                // nothing to cache and no cached values.
                return;
            }
            cachedValues = new MultiKeyMap();
            flowManagement.registerForCacheClearing();
        }
        if ( value == null ) {
            cachedValues.remove(namespace, key);
        } else {
View Full Code Here

TOP

Related Classes of org.apache.commons.collections.map.MultiKeyMap

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.