Coverage for /var/srv/projects/api.amasfac.comuna18.com/tmp/venv/lib/python3.9/site-packages/sendgrid/helpers/mail/subscription_text.py: 53%

13 statements  

« prev     ^ index     » next       coverage.py v6.4.4, created at 2023-07-17 14:22 -0600

1class SubscriptionText(object): 

2 """The text of an SubscriptionTracking.""" 

3 

4 def __init__(self, subscription_text=None): 

5 """Create a SubscriptionText object 

6 

7 :param subscription_text: Text to be appended to the email, with the 

8 subscription tracking link. You may control 

9 where the link is by using the tag <% %> 

10 :type subscription_text: string, optional 

11 """ 

12 self._subscription_text = None 

13 

14 if subscription_text is not None: 

15 self.subscription_text = subscription_text 

16 

17 @property 

18 def subscription_text(self): 

19 """Text to be appended to the email, with the subscription tracking link. 

20 You may control where the link is by using the tag <% %> 

21 

22 :rtype: string 

23 """ 

24 return self._subscription_text 

25 

26 @subscription_text.setter 

27 def subscription_text(self, value): 

28 """Text to be appended to the email, with the subscription tracking link. 

29 You may control where the link is by using the tag <% %> 

30 

31 :param value: Text to be appended to the email, with the subscription 

32 tracking link. You may control where the link is by using 

33 the tag <% %> 

34 :type value: string 

35 """ 

36 self._subscription_text = value 

37 

38 def get(self): 

39 """ 

40 Get a JSON-ready representation of this SubscriptionText. 

41 

42 :returns: This SubscriptionText, ready for use in a request body. 

43 :rtype: string 

44 """ 

45 return self.subscription_text