Created method for generating charges