Changed methods to bean as attribute.