Lines Matching refs:p
98 for p in prop_list.get_all_props():
99 if len(p.value) > PROP_VALUE_MAX and not p.name.startswith("ro."):
102 (p.name, PROP_VALUE_MAX))
103 sys.stderr.write("%s (%d)\n" % (p.value, len(p.value)))
105 if p.is_optional():
108 sys.stderr.write(str(p) + "\n")
125 optional_props = [p for p in props if p.is_optional()]
126 overriding_props = [p for p in props if not p.is_optional()]
129 if all(overriding_props[0].value == p.value for p in overriding_props):
130 for p in optional_props:
131 p.delete("overridden by %s" % str(overriding_props[0]))
138 for p in optional_props:
139 p.optional = False
144 for p in overriding_props:
145 sys.stderr.write("%s\n" % str(p))
147 for p in optional_props:
148 p.delete("overridden by %s" % str(overriding_props[0]))
151 for p in optional_props[:-1]:
152 p.delete("overridden by %s" % str(optional_props[-1]))
218 return [p for p in self.props if not p.is_comment()]
221 return set([p.name for p in self.get_all_props()])
224 return [p for p in self.get_all_props() if p.name == name]
228 return next((p.value for p in self.props if p.name == name), "")
235 index = next((i for i,p in enumerate(self.props)
236 if p.name == name and not p.is_optional()), -1)
248 for p in self.props:
249 f.write(str(p) + "\n")
275 for p in props.get_props(key):
276 p.delete("%s is a disallowed key" % key)