Updates this segment.

def update(self, title, rulegroups):
        """Updates this segment."""
        body = {
            "Title": title,
            "RuleGroups": rulegroups}
        response = self._put("/segments/%s.json" %
                             self.segment_id, json.dumps(body))