(self, value)
| 819 | super(_RelatedCampaignRefList, self).__init__(type=RelatedCampaignRef, *args) |
| 820 | |
| 821 | def _fix_value(self, value): |
| 822 | from stix.campaign import Campaign |
| 823 | |
| 824 | if isinstance(value, Campaign) and value.id_: |
| 825 | return RelatedCampaignRef(CampaignRef(idref=value.id_)) |
| 826 | |
| 827 | msg = "Cannot insert object of type '%s' into '%s'" |
| 828 | msg = msg % (type(value), self.__class__.__name__) |
| 829 | raise TypeError(msg) |
| 830 | |
| 831 | |
| 832 | class RelatedCampaignRefs(GenericRelationshipList): |
nothing calls this directly
no test coverage detected