<s> """<STR_LIT>""" <EOL> import json <EOL> class Filter ( object ) : <EOL> """<STR_LIT>""" <EOL> def __init__ ( self , type , property_name , value ) : <EOL> """<STR_LIT>""" <EOL> self . type = type <EOL> self . property_name = property_name <EOL> self . value = value <EOL> def __repr__ ( self ) : <EOL> return "<STR_LIT>" . format ( name = self . __class__ . __name__ , <EOL> value = self ) <EOL> def __str__ ( self ) : <EOL> return "<STR_LIT>" . format ( <EOL> type = self . type , property = self . property_name , <EOL> value = json . dumps ( self . value ) ) <EOL> def __eq__ ( self , other ) : <EOL> return self . type == other . type and self . property_name == other . property_name and self . value == other . value <EOL> class EQ ( Filter ) : <EOL> """<STR_LIT>""" <EOL> def __init__ ( self , property_name , value ) : <EOL> return super ( EQ , self ) . __init__ ( "<STR_LIT>" , property_name , value ) <EOL> class LT ( Filter ) : <EOL> """<STR_LIT>""" <EOL> def __init__ ( self , property_name , value ) : <EOL> return super ( LT , self ) . __init__ ( "<STR_LIT>" , property_name , value ) <EOL> class LE ( Filter ) : <EOL> """<STR_LIT>""" <EOL> def __init__ ( self , property_name , value ) : <EOL> return super ( LE , self ) . __init__ ( "<STR_LIT>" , property_name , value ) <EOL> class GT ( Filter ) : <EOL> """<STR_LIT>""" <EOL> def __init__ ( self , property_name , value ) : <EOL> return super ( GT , self ) . __init__ ( "<STR_LIT>" , property_name , value ) <EOL> class GE ( Filter ) : <EOL> """<STR_LIT>""" <EOL> def __init__ ( self , property_name , value ) : <EOL> return super ( GE , self ) . __init__ ( "<STR_LIT>" , property_name , value ) <EOL> class NE ( Filter ) : <EOL> """<STR_LIT>""" <EOL> def __init__ ( self , property_name , value ) : <EOL> return super ( NE , self ) . __init__ ( "<STR_LIT>" , property_name , value ) <EOL> class RE ( Filter ) : <EOL> """<STR_LIT>""" <EOL> def __init__ ( self , property_name , value ) : <EOL> return super ( RE , self ) . __init__ ( "<STR_LIT>" , property_name , value ) <EOL> class IN ( Filter ) : <EOL> """<STR_LIT>""" <EOL> def __init__ ( self , property_name , value ) : <EOL> return super ( IN , self ) . __init__ ( "<STR_LIT>" , property_name , <EOL> [ x for x in value ] ) <EOL> class StartsWith ( RE ) : <EOL> """<STR_LIT>""" <EOL> def __init__ ( self , property_name , value ) : <EOL> v = "<STR_LIT>" . format ( value = value ) <EOL> return super ( StartsWith , self ) . __init__ ( property_name , v ) <EOL> class EndsWith ( RE ) : <EOL> """<STR_LIT>""" <EOL> def __init__ ( self , property_name , value ) : <EOL> v = "<STR_LIT>" . format ( value = value ) <EOL> return super ( EndsWith , self ) . __init__ ( property_name , v ) </s>
