'Work function'

def work(self):

    self.check_params()
    self.get_proposed()
    self.get_existing()
    if (self.state == 'present'):
        self.present_stp()
    else:
        self.absent_stp()
    self.get_end_state()
    self.results['changed'] = self.changed
    self.results['proposed'] = self.proposed
    self.results['existing'] = self.existing
    self.results['end_state'] = self.end_state
    self.results['updates'] = self.updates_cmd
    self.module.exit_json(**self.results)
