1# coding: utf-8
2# Copyright (c) 2016, 2021, Oracle and/or its affiliates.  All rights reserved.
3# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
4
5
6from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel  # noqa: F401
7from oci.decorators import init_model_state_from_kwargs
8
9
10@init_model_state_from_kwargs
11class FacetedSearchDateFilterRequest(object):
12    """
13    Object with date filter criteria
14    """
15
16    def __init__(self, **kwargs):
17        """
18        Initializes a new FacetedSearchDateFilterRequest object with values from keyword arguments.
19        The following keyword arguments are supported (corresponding to the getters/setters of this class):
20
21        :param field_name:
22            The value to assign to the field_name property of this FacetedSearchDateFilterRequest.
23        :type field_name: str
24
25        :param time_after:
26            The value to assign to the time_after property of this FacetedSearchDateFilterRequest.
27        :type time_after: datetime
28
29        :param time_before:
30            The value to assign to the time_before property of this FacetedSearchDateFilterRequest.
31        :type time_before: datetime
32
33        """
34        self.swagger_types = {
35            'field_name': 'str',
36            'time_after': 'datetime',
37            'time_before': 'datetime'
38        }
39
40        self.attribute_map = {
41            'field_name': 'fieldName',
42            'time_after': 'timeAfter',
43            'time_before': 'timeBefore'
44        }
45
46        self._field_name = None
47        self._time_after = None
48        self._time_before = None
49
50    @property
51    def field_name(self):
52        """
53        Gets the field_name of this FacetedSearchDateFilterRequest.
54        Date field name that needs to be filtered by.
55
56
57        :return: The field_name of this FacetedSearchDateFilterRequest.
58        :rtype: str
59        """
60        return self._field_name
61
62    @field_name.setter
63    def field_name(self, field_name):
64        """
65        Sets the field_name of this FacetedSearchDateFilterRequest.
66        Date field name that needs to be filtered by.
67
68
69        :param field_name: The field_name of this FacetedSearchDateFilterRequest.
70        :type: str
71        """
72        self._field_name = field_name
73
74    @property
75    def time_after(self):
76        """
77        Gets the time_after of this FacetedSearchDateFilterRequest.
78        The date and time the request was created, as described in
79        `RFC 3339`__, section 14.29.
80
81        __ https://tools.ietf.org/rfc/rfc3339
82
83
84        :return: The time_after of this FacetedSearchDateFilterRequest.
85        :rtype: datetime
86        """
87        return self._time_after
88
89    @time_after.setter
90    def time_after(self, time_after):
91        """
92        Sets the time_after of this FacetedSearchDateFilterRequest.
93        The date and time the request was created, as described in
94        `RFC 3339`__, section 14.29.
95
96        __ https://tools.ietf.org/rfc/rfc3339
97
98
99        :param time_after: The time_after of this FacetedSearchDateFilterRequest.
100        :type: datetime
101        """
102        self._time_after = time_after
103
104    @property
105    def time_before(self):
106        """
107        Gets the time_before of this FacetedSearchDateFilterRequest.
108        The date and time the request was created, as described in
109        `RFC 3339`__, section 14.29.
110
111        __ https://tools.ietf.org/rfc/rfc3339
112
113
114        :return: The time_before of this FacetedSearchDateFilterRequest.
115        :rtype: datetime
116        """
117        return self._time_before
118
119    @time_before.setter
120    def time_before(self, time_before):
121        """
122        Sets the time_before of this FacetedSearchDateFilterRequest.
123        The date and time the request was created, as described in
124        `RFC 3339`__, section 14.29.
125
126        __ https://tools.ietf.org/rfc/rfc3339
127
128
129        :param time_before: The time_before of this FacetedSearchDateFilterRequest.
130        :type: datetime
131        """
132        self._time_before = time_before
133
134    def __repr__(self):
135        return formatted_flat_dict(self)
136
137    def __eq__(self, other):
138        if other is None:
139            return False
140
141        return self.__dict__ == other.__dict__
142
143    def __ne__(self, other):
144        return not self == other
145