(self, attrsD)
| 1536 | self._getContext()['cloud'] = FeedParserDict(attrsD) |
| 1537 | |
| 1538 | def _start_link(self, attrsD): |
| 1539 | attrsD.setdefault('rel', u'alternate') |
| 1540 | if attrsD['rel'] == u'self': |
| 1541 | attrsD.setdefault('type', u'application/atom+xml') |
| 1542 | else: |
| 1543 | attrsD.setdefault('type', u'text/html') |
| 1544 | context = self._getContext() |
| 1545 | attrsD = self._itsAnHrefDamnIt(attrsD) |
| 1546 | if 'href' in attrsD: |
| 1547 | attrsD['href'] = self.resolveURI(attrsD['href']) |
| 1548 | expectingText = self.infeed or self.inentry or self.insource |
| 1549 | context.setdefault('links', []) |
| 1550 | if not (self.inentry and self.inimage): |
| 1551 | context['links'].append(FeedParserDict(attrsD)) |
| 1552 | if 'href' in attrsD: |
| 1553 | expectingText = 0 |
| 1554 | if (attrsD.get('rel') == u'alternate') and (self.mapContentType(attrsD.get('type')) in self.html_types): |
| 1555 | context['link'] = attrsD['href'] |
| 1556 | else: |
| 1557 | self.push('link', expectingText) |
| 1558 | |
| 1559 | def _end_link(self): |
| 1560 | value = self.pop('link') |
no test coverage detected