MCPcopy Create free account
hub / github.com/STIXProject/python-stix / add_campaign

Method add_campaign

stix/core/stix_package.py:121–127  ·  view source on GitHub ↗

Adds a :class:`Campaign` object to the :attr:`campaigns` collection.

(self, campaign)

Source from the content-addressed store, hash-verified

119 self.indicators.append(indicator)
120
121 def add_campaign(self, campaign):
122 """Adds a :class:`Campaign` object to the :attr:`campaigns` collection.
123
124 """
125 if self.campaigns is None:
126 self.campaigns = Campaigns()
127 self.campaigns.append(campaign)
128
129 def add_observable(self, observable):
130 """Adds an ``Observable`` object to the :attr:`observables` collection.

Callers 1

mainFunction · 0.95

Calls 1

CampaignsClass · 0.70

Tested by

no test coverage detected