(self, item)
| 143 | def __init__(self): |
| 144 | self.count = {} |
| 145 | def append(self, item): |
| 146 | kv = item.split(b':') |
| 147 | if len(kv) > 1: |
| 148 | # item is a 'Key: Value' header string |
| 149 | lcKey = kv[0].decode('ascii').lower() |
| 150 | self.count.setdefault(lcKey, 0) |
| 151 | self.count[lcKey] += 1 |
| 152 | list.append(self, item) |
| 153 | |
| 154 | for explicit_header in True, False: |
| 155 | for header in 'Content-length', 'Host', 'Accept-encoding': |
no test coverage detected