<s> """<STR_LIT>""" <EOL> import uuid <EOL> def filter_null_keys ( dictionary ) : <EOL> return dict ( ( ( k , v ) for k , v in dictionary . items ( ) if v is not None ) ) <EOL> def validate_ref ( ref , entity ) : <EOL> """<STR_LIT>""" <EOL> try : <EOL> _ , entity_uuid = ref . rstrip ( '<STR_LIT:/>' ) . rsplit ( '<STR_LIT:/>' , <NUM_LIT:1> ) <EOL> uuid . UUID ( entity_uuid ) <EOL> except : <EOL> raise ValueError ( '<STR_LIT>' . format ( entity ) ) <EOL> return True <EOL> class ImmutableException ( Exception ) : <EOL> def __init__ ( self , attribute = None ) : <EOL> message = "<STR_LIT>" <EOL> super ( ImmutableException , self ) . __init__ ( message ) <EOL> class BaseEntityManager ( object ) : <EOL> def __init__ ( self , api , entity ) : <EOL> self . _api = api <EOL> self . _entity = entity <EOL> def total ( self ) : <EOL> """<STR_LIT>""" <EOL> params = { '<STR_LIT>' : <NUM_LIT:0> , '<STR_LIT>' : <NUM_LIT:0> } <EOL> resp = self . _api . get ( self . _entity , params = params ) <EOL> return resp [ '<STR_LIT>' ] </s>
