Recycling the diagram object for better performance.