Passing attribute name and value in rebuild() method