Package java.util

Examples of java.util.Map.containsKey()


                     if (!E.hasAttributeNS(
                             XML_LANG_URI,
                             currentAncestorAttr.getLocalName())) {

                        // the xml:* attr is not in E
                        if (!loa.containsKey(currentAncestorAttr.getName())) {
                           loa.put(currentAncestorAttr.getName(),
                                   currentAncestorAttr);
                        }
                     }
                  }
View Full Code Here


     */
    public static Object checkContextKeys(final InvocationContext ic, final Object[] keys) throws Exception {
        Map mContext = ic.getContextData();
        if (keys != null) {
            for (Object o : keys) {
                if (!mContext.containsKey(o)) {
                    throw new Exception("Object not found.");
                }
            }
        }
        return ic.proceed();
View Full Code Here

            MetadataDeserializerFactory.getProperties(MetaBean.class, null);
       
        Method m = MetaBean.class.getMethod("getWorld", new Class[0] );
        assertTrue( Attributes.hasAttributeType(m, NonWebMethod.class) );
       
        assertTrue( properties.containsKey("hello") );
        assertTrue( !properties.containsKey("world") );
    }
}
View Full Code Here

       
        Method m = MetaBean.class.getMethod("getWorld", new Class[0] );
        assertTrue( Attributes.hasAttributeType(m, NonWebMethod.class) );
       
        assertTrue( properties.containsKey("hello") );
        assertTrue( !properties.containsKey("world") );
    }
}
View Full Code Here

    for (ConstraintViolation<ActionSupport> constrantViolation : constraintViolations) {
      Path fieldPath = constrantViolation.getPropertyPath();
      Map<String, Object> attrs = constrantViolation.getConstraintDescriptor().getAttributes();
      if (invalidFieldNames.contains(fieldPath))
        continue;
      if (parameters.containsKey(fieldPath.toString())) {
        invalidValuesFromRequest.add(constrantViolation);
        invalidFieldNames.add(fieldPath);
      }
    } 
    constraintViolations.clear();
View Full Code Here

    Map parameters = ActionContext.getContext().getParameters();
    for (InvalidValue invalidValue : invalidValues) {
      String fieldFullName = invalidValue.getPropertyPath();
      if (invalidFieldNames.contains(fieldFullName))
        continue;
      if (parameters.containsKey(fieldFullName)) {
        invalidValuesFromRequest.add(invalidValue);
        invalidFieldNames.add(fieldFullName);
      }
    }
    invalidValues=null;
View Full Code Here

                    // Get multiple output parts from the map
                    for ( int p = 0; p < fieldOutParameterNames.length; p++ )
                    {
                        String pName = fieldOutParameterNames[p];
                        if ( returnedMap.containsKey( pName ) )
                        {
                            Object outPart = returnedMap.get( pName );
                            output.setObjectPart( pName, outPart );
                        }
                        else
View Full Code Here

   
    String styleName = attributes.getValue(styleAttribute);
    if (styleName != null)
    {
      Map stylesMap = jasperDesign.getStylesMap();
      if (stylesMap.containsKey(styleName))
      {
        JRStyle style = (JRStyle) stylesMap.get(styleName);
        styleContainer.setStyle(style);
      }
      else
View Full Code Here

          }
        }
      }
    }
   
    if (!parameterValues.containsKey(JRParameter.REPORT_LOCALE))
    {
      parameterValues.put(JRParameter.REPORT_LOCALE, filler.getLocale());
    }

    if (!parameterValues.containsKey(JRParameter.REPORT_TIME_ZONE))
View Full Code Here

    if (!parameterValues.containsKey(JRParameter.REPORT_LOCALE))
    {
      parameterValues.put(JRParameter.REPORT_LOCALE, filler.getLocale());
    }

    if (!parameterValues.containsKey(JRParameter.REPORT_TIME_ZONE))
    {
      parameterValues.put(JRParameter.REPORT_TIME_ZONE, filler.getTimeZone());
    }

    if (
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.