MCPcopy Index your code
hub / github.com/pyload/pyload / processTypeValue

Method processTypeValue

module/lib/feedparser.py:2181–2191  ·  view source on GitHub ↗
(sProperty, arDefaultType, arForceType=None)

Source from the content-addressed store, hash-verified

2179 arLines.append(self.vcardFold(sProperty.upper() + sEncoding + sContentType + sValueKey + ':' + sValue))
2180
2181 def processTypeValue(sProperty, arDefaultType, arForceType=None):
2182 arResults = self.getPropertyValue(elmCard, sProperty, bAllowMultiple=1)
2183 for elmResult in arResults:
2184 arType = self.getPropertyValue(elmResult, 'type', self.STRING, 1, 1)
2185 if arForceType:
2186 arType = self.unique(arForceType + arType)
2187 if not arType:
2188 arType = arDefaultType
2189 sValue = self.getPropertyValue(elmResult, 'value', self.EMAIL, 0)
2190 if sValue:
2191 arLines.append(self.vcardFold(sProperty.upper() + ';TYPE=' + ','.join(arType) + ':' + sValue))
2192
2193 # AGENT
2194 # must do this before all other properties because it is destructive

Callers

nothing calls this directly

Calls 5

getPropertyValueMethod · 0.95
uniqueMethod · 0.95
vcardFoldMethod · 0.95
joinMethod · 0.80
appendMethod · 0.45

Tested by

no test coverage detected