reduced BeanDefinition footprint by initializing Sets and Maps with 0 (SPR-7491)

master
Juergen Hoeller 14 years ago
parent 125b843cf7
commit e971ad56b6
  1. 4
      org.springframework.core/src/main/java/org/springframework/core/AttributeAccessorSupport.java

@ -1,5 +1,5 @@
/* /*
* Copyright 2002-2008 the original author or authors. * Copyright 2002-2011 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -35,7 +35,7 @@ import org.springframework.util.Assert;
public abstract class AttributeAccessorSupport implements AttributeAccessor, Serializable { public abstract class AttributeAccessorSupport implements AttributeAccessor, Serializable {
/** Map with String keys and Object values */ /** Map with String keys and Object values */
private final Map<String, Object> attributes = new LinkedHashMap<String, Object>(); private final Map<String, Object> attributes = new LinkedHashMap<String, Object>(0);
public void setAttribute(String name, Object value) { public void setAttribute(String name, Object value) {

Loading…
Cancel
Save