Serializes this StickerSet to a dictionary.

        :return: dictionary representation of this object.
        :rtype: dict
5569
def to_array(self):
        
        array = super(StickerSet, self).to_array()
        array['name'] = u(self.name)  # py2: type unicode, py3: type str

        array['title'] = u(self.title)  # py2: type unicode, py3: type str

        array['contains_masks'] = bool(self.contains_masks)  # type bool
        array['stickers'] = self._as_array(self.stickers)  # type list of Sticker

        return array
1077482
def as_dict(self):
        

        d = {"@module": self.__class__.__module__,
             "@class": self.__class__.__name__,
             "molecule": self.molecule.as_dict(),
             "graphs": json_graph.adjacency_data(self.graph)}

        return d
593404
def as_dict(self):
        
        d = {"@module": self.__class__.__module__,
             "@class": self.__class__.__name__,
             "name": self.name, "options": self.options}
        if len(self.subkeys) > 0:
            subkeys = []
            for subkey in self.subkeys:
                subkeys.append(subkey.as_dict())
            d.update({"subkeys": subkeys})
        return d
710912
def to_dict(self) -> dict:
        
        return {
            key: getattr(self, key)
            for key in self.__slots__
            if getattr(self, key) is not None
        }
1348259
def to_array(self):
        
        array = super(StickerMessage, self).to_array()
        if isinstance(self.sticker, InputFile):
            array['sticker'] = self.sticker.to_array()  # type InputFile
        elif isinstance(self.sticker, str):
            array['sticker'] = u(self.sticker)  # py2: type unicode, py3: type str
        else:
            raise TypeError('Unknown type, must be one of InputFile, str.')
        # end if

        if self.receiver is not None:
            if isinstance(self.receiver, None):
                array['chat_id'] = None(self.receiver)  # type Noneelif isinstance(self.receiver, str):
                array['chat_id'] = u(self.receiver)  # py2: type unicode, py3: type str
            elif isinstance(self.receiver, int):
                array['chat_id'] = int(self.receiver)  # type intelse:
                raise TypeError('Unknown type, must be one of None, str, int.')
            # end if

        if self.reply_id is not None:
            if isinstance(self.reply_id, DEFAULT_MESSAGE_ID):
                array['reply_to_message_id'] = DEFAULT_MESSAGE_ID(self.reply_id)  # type DEFAULT_MESSAGE_IDelif isinstance(self.reply_id, int):
                array['reply_to_message_id'] = int(self.reply_id)  # type intelse:
                raise TypeError('Unknown type, must be one of DEFAULT_MESSAGE_ID, int.')
            # end if

        if self.disable_notification is not None:
            array['disable_notification'] = bool(self.disable_notification)  # type bool
        if self.reply_markup is not None:
            if isinstance(self.reply_markup, InlineKeyboardMarkup):
                array['reply_markup'] = self.reply_markup.to_array()  # type InlineKeyboardMarkup
            elif isinstance(self.reply_markup, ReplyKeyboardMarkup):
                array['reply_markup'] = self.reply_markup.to_array()  # type ReplyKeyboardMarkup
            elif isinstance(self.reply_markup, ReplyKeyboardRemove):
                array['reply_markup'] = self.reply_markup.to_array()  # type ReplyKeyboardRemove
            elif isinstance(self.reply_markup, ForceReply):
                array['reply_markup'] = self.reply_markup.to_array()  # type ForceReply
            else:
                raise TypeError('Unknown type, must be one of InlineKeyboardMarkup, ReplyKeyboardMarkup, ReplyKeyboardRemove, ForceReply.')
            # end if

        return array
749188
def to_dict(self):
        
        obj_dict = super(Row, self).to_dict()
        cells_dict = [c.to_dict() for c in self.cells]
        child_dict = {
            'type': self.__class__.__name__,
            'cells': cells_dict
        }
        obj_dict.update(child_dict)
        return child_dict
868061
def to_dict(self):
        
        return {
            'type': self.__class__.__name__,
            'element_id': self.element_id,
            'style_class': self.style_class,
            'icon': self.icon,
            'attributes': self.attributes
        }
1262084
def to_serializable_dict(self, attrs_to_serialize=None,
                             rels_to_expand=None,
                             rels_to_serialize=None,
                             key_modifications=None):
        
        return self.todict(
            attrs_to_serialize=attrs_to_serialize,
            rels_to_expand=rels_to_expand, rels_to_serialize=rels_to_serialize,
            key_modifications=key_modifications)
489937
def CopyToDict(self):
    
    result_dict = {
        'labels': self.labels
    }
    if self.comment:
      result_dict['comment'] = self.comment

    return result_dict
1116229
def to_dict(self):
        
        return dict({'title': self.title,
                     'album': self.album,
                     'year': self.year,
                     'lyrics': self.lyrics,
                     'image': self.song_art_image_url})
1011396
def to_dict(self):
        
        doc = {
            'filename' : self.filename,
            'mimeType' : self.mime_type
        }
        # Add path if present
        if self.filename != self.path:
            doc['path'] = self.path
        return doc
490093
def to_dict(self):
        

        return {
            "total": self.total,
            "subtotal": self.subtotal,
            "items": self.items,
            "extra_amount": self.extra_amount
        }
415544
def to_dict(self):
        
        return dict((k, str(self.get(k))) for k in self.raw_dict)
900606
def to_dict(self):
        
        out_dict = dict(self)
        for k, v in out_dict.items():
            if v is self:
                out_dict[k] = out_dict
            elif hasattr(v, 'to_dict'):
                out_dict[k] = v.to_dict()
            elif hasattr(v, 'to_list'):
                out_dict[k] = v.to_list()
        return out_dict
1298086
def to_dict(self):
        
        d = dict(individual_doses=self.individual_doses, responses=self.responses)
        d.update(self.kwargs)
        return d
871366
def as_dict(self):
        
        return {"@module": self.__class__.__module__,
                "@class": self.__class__.__name__,
                "element": self.symbol}
1254211
def to_json(self):
        
        return json.dumps(self.to_dict(), sort_keys=True, indent=2, separators=(',', ': '))