Sets a value for the product element. If a product element does not already exist, one will be created
(self, product)
| 584 | return self.element |
| 585 | |
| 586 | def setProduct(self, product): |
| 587 | """ |
| 588 | Sets a value for the product element. If a product element does not already exist, one will be created |
| 589 | """ |
| 590 | if self.element is None: |
| 591 | return False |
| 592 | |
| 593 | if product is None: |
| 594 | return False |
| 595 | |
| 596 | child = self.element.find("oval:product_name", OvalDocument.NS_OVAL) |
| 597 | if child is not None: |
| 598 | child.text = product |
| 599 | else: |
| 600 | child = Element("{" + OvalDocument.NS_DEFAULT.get("def") + "}product_name") |
| 601 | child.text = product |
| 602 | self.element.append(child) |
| 603 | |
| 604 | def getSchemaVersion(self): |
| 605 | """ |
no test coverage detected