changed  to protected and added get/set methods, modified code to use get/set methods
modified Rule to have a fluent interface