query
mlte/store/common/query.py
Query and filtering functionality for store operations.
AllFilter
Bases: Filter
A filter that matches all entries.
Source code in mlte/store/query.py
102 103 104 105 106 107 108 109 |
|
type = FilterType.ALL
class-attribute
instance-attribute
An identifier for the filter type.
AndFilter
Bases: CompositeFilter
A generic filter that implements a logical AND of filters.
Source code in mlte/store/query.py
180 181 182 183 184 185 186 187 |
|
type = FilterType.AND
class-attribute
instance-attribute
An identifier for the filter type.
CompositeFilter
Bases: Filter
Definition of a composite filter interface.
Source code in mlte/store/query.py
40 41 42 43 |
|
Filter
Bases: BaseModel
Definition of a filter interface.
Source code in mlte/store/query.py
30 31 32 33 34 35 36 37 |
|
FilterType
Bases: LowercaseStrEnum
An enumeration over filter types.
Source code in mlte/store/query.py
89 90 91 92 93 94 95 96 97 98 99 |
|
Filterable
Bases: BaseModel
Definition of a filterable interface.
Source code in mlte/store/query.py
46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 |
|
get_identifier()
abstractmethod
Returns the identifier for filtering.
Source code in mlte/store/query.py
49 50 51 52 53 54 |
|
get_property(property_name)
Returns the given property.
Source code in mlte/store/query.py
63 64 65 66 67 68 69 70 71 |
|
get_tags(property_name)
Returns the given tags.
Source code in mlte/store/query.py
73 74 75 76 77 78 79 80 81 |
|
get_type()
abstractmethod
Returns the class-specific type for filtering.
Source code in mlte/store/query.py
56 57 58 59 60 61 |
|
IdentifierFilter
Bases: Filter
A filter that matches an item's identifier.
Source code in mlte/store/query.py
122 123 124 125 126 127 128 129 130 131 132 |
|
id
instance-attribute
The identifier to match.
type = FilterType.IDENTIFIER
class-attribute
instance-attribute
An identifier for the filter type.
NoneFilter
Bases: Filter
A filter that matches no entries.
Source code in mlte/store/query.py
112 113 114 115 116 117 118 119 |
|
type = FilterType.NONE
class-attribute
instance-attribute
An identifier for the filter type.
OrFilter
Bases: CompositeFilter
A generic filter that implements a logical OR of filters.
Source code in mlte/store/query.py
190 191 192 193 194 195 196 197 |
|
type = FilterType.OR
class-attribute
instance-attribute
An identifier for the filter type.
PropertyFilter
Bases: Filter
A filter that matches a given property.
Source code in mlte/store/query.py
164 165 166 167 168 169 170 171 172 173 174 175 176 177 |
|
name
instance-attribute
The name of the property.
type = FilterType.PROPERTY
class-attribute
instance-attribute
An identifier for the filter type.
value
instance-attribute
The property to match.
Query
Bases: BaseModel
A Query object represents a query over entries.
Source code in mlte/store/query.py
200 201 202 203 204 |
|
filter = AllFilter()
class-attribute
instance-attribute
The filter that is applied to implement the query.
TagFilter
Bases: Filter
A filter that matches a given tag, from a field with a list of tags.
Source code in mlte/store/query.py
148 149 150 151 152 153 154 155 156 157 158 159 160 161 |
|
name
instance-attribute
The name of the property with the tags.
type = FilterType.TAG
class-attribute
instance-attribute
An identifier for the filter type.
value
instance-attribute
The property to match.
TypeFilter
Bases: Filter
A filter that matches an item's type.
Source code in mlte/store/query.py
135 136 137 138 139 140 141 142 143 144 145 |
|
item_type
instance-attribute
The type to match.
type = FilterType.TYPE
class-attribute
instance-attribute
An identifier for the filter type.