コード例 #1
0
ファイル: consumer.py プロジェクト: astrofinch/djangoembed
 def extract_oembeds(self, text, maxwidth=None, maxheight=None, resource_type=None):
     """
     Scans a block of text and extracts oembed data on any urls,
     returning it in a list of dictionaries
     """
     parser = text_parser()
     urls = parser.extract_urls(text)
     return self.handle_extracted_urls(urls, maxwidth, maxheight, resource_type)
コード例 #2
0
ファイル: consumer.py プロジェクト: tiktuk/djangoembed
 def extract_oembeds(self,
                     text,
                     maxwidth=None,
                     maxheight=None,
                     resource_type=None):
     """
     Scans a block of text and extracts oembed data on any urls,
     returning it in a list of dictionaries
     """
     parser = text_parser()
     urls = parser.extract_urls(text)
     return self.handle_extracted_urls(urls, maxwidth, maxheight,
                                       resource_type)
コード例 #3
0
ファイル: consumer.py プロジェクト: tiktuk/djangoembed
 def parse_text(self, text, *args, **kwargs):
     parser = text_parser()
     return parser.parse(text, *args, **kwargs)
コード例 #4
0
ファイル: consumer.py プロジェクト: astrofinch/djangoembed
 def parse_text(self, text, *args, **kwargs):
     parser = text_parser()
     return parser.parse(text, *args, **kwargs)