Coverage for fingerprint_pro_server_api_sdk/models/seen_at.py: 54%

52 statements  

« prev     ^ index     » next       coverage.py v7.4.4, created at 2024-03-27 22:39 +0000

1# coding: utf-8 

2 

3""" 

4 Fingerprint Pro Server API 

5 

6 Fingerprint Pro Server API allows you to get information about visitors and about individual events in a server environment. It can be used for data exports, decision-making, and data analysis scenarios. Server API is intended for server-side usage, it's not intended to be used from the client side, whether it's a browser or a mobile device. # noqa: E501 

7 

8 OpenAPI spec version: 3 

9 Contact: support@fingerprint.com 

10 Generated by: https://github.com/swagger-api/swagger-codegen.git 

11""" 

12 

13import pprint 

14import re # noqa: F401 

15 

16import six 

17 

18class SeenAt(object): 

19 """NOTE: This class is auto generated by the swagger code generator program. 

20 

21 Do not edit the class manually. 

22 """ 

23 """ 

24 Attributes: 

25 swagger_types (dict): The key is attribute name 

26 and the value is attribute type. 

27 attribute_map (dict): The key is attribute name 

28 and the value is json key in definition. 

29 """ 

30 swagger_types = { 

31 '_global': 'datetime', 

32 'subscription': 'datetime' 

33 } 

34 

35 attribute_map = { 

36 '_global': 'global', 

37 'subscription': 'subscription' 

38 } 

39 

40 def __init__(self, _global=None, subscription=None): # noqa: E501 

41 """SeenAt - a model defined in Swagger""" # noqa: E501 

42 self.__global = None 

43 self._subscription = None 

44 self.discriminator = None 

45 self._global = _global 

46 self.subscription = subscription 

47 

48 @property 

49 def _global(self): 

50 """Gets the _global of this SeenAt. # noqa: E501 

51 

52 

53 :return: The _global of this SeenAt. # noqa: E501 

54 :rtype: datetime 

55 """ 

56 return self.__global 

57 

58 @_global.setter 

59 def _global(self, _global): 

60 """Sets the _global of this SeenAt. 

61 

62 

63 :param _global: The _global of this SeenAt. # noqa: E501 

64 :type: datetime 

65 """ 

66 

67 self.__global = _global 

68 

69 @property 

70 def subscription(self): 

71 """Gets the subscription of this SeenAt. # noqa: E501 

72 

73 

74 :return: The subscription of this SeenAt. # noqa: E501 

75 :rtype: datetime 

76 """ 

77 return self._subscription 

78 

79 @subscription.setter 

80 def subscription(self, subscription): 

81 """Sets the subscription of this SeenAt. 

82 

83 

84 :param subscription: The subscription of this SeenAt. # noqa: E501 

85 :type: datetime 

86 """ 

87 

88 self._subscription = subscription 

89 

90 def to_dict(self): 

91 """Returns the model properties as a dict""" 

92 result = {} 

93 

94 for attr, _ in six.iteritems(self.swagger_types): 

95 value = getattr(self, attr) 

96 if isinstance(value, list): 

97 result[attr] = list(map( 

98 lambda x: x.to_dict() if hasattr(x, "to_dict") else x, 

99 value 

100 )) 

101 elif hasattr(value, "to_dict"): 

102 result[attr] = value.to_dict() 

103 elif isinstance(value, dict): 

104 result[attr] = dict(map( 

105 lambda item: (item[0], item[1].to_dict()) 

106 if hasattr(item[1], "to_dict") else item, 

107 value.items() 

108 )) 

109 else: 

110 result[attr] = value 

111 if issubclass(SeenAt, dict): 

112 for key, value in self.items(): 

113 result[key] = value 

114 

115 return result 

116 

117 def to_str(self): 

118 """Returns the string representation of the model""" 

119 return pprint.pformat(self.to_dict()) 

120 

121 def __repr__(self): 

122 """For `print` and `pprint`""" 

123 return self.to_str() 

124 

125 def __eq__(self, other): 

126 """Returns true if both objects are equal""" 

127 if not isinstance(other, SeenAt): 

128 return False 

129 

130 return self.to_dict() == other.to_dict() 

131 

132 def __ne__(self, other): 

133 """Returns true if both objects are not equal""" 

134 if not isinstance(other, SeenAt): 

135 return True 

136 

137 return self.to_dict() != other.to_dict()