#NEWLINE# def pins_return_results( line , pintypes ) : #NEWLINE# #INDENT# if ( pintypes == 'stop' ) : #NEWLINE# #INDENT# return { #NEWLINE# #INDENT# 'id' : int ( line . split ( '|||' ) [ 0 ] ) , #NEWLINE# 'name' : line . split ( '||' ) [ 1 ] . split ( '|' ) [ 1 ] , #NEWLINE# 'coords' : pincoords_to_object ( int ( line . split ( '||' ) [ 1 ] . split ( '|' ) [ 2 ] ) , int ( line . split ( '||' ) [ 1 ] . split ( '|' ) [ 3 ] ) ) , #NEWLINE# 'connections' : line . split ( '||' ) [ 2 ] , #NEWLINE# #UNINDENT# } #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( pintypes == 'platform' ) : #NEWLINE# #INDENT# return { #NEWLINE# #INDENT# 'name' : line . split ( '||' ) [ 1 ] . split ( '|' ) [ 0 ] , #NEWLINE# 'coords' : pincoords_to_object ( int ( line . split ( '||' ) [ 1 ] . split ( '|' ) [ 1 ] ) , int ( line . split ( '||' ) [ 1 ] . split ( '|' ) [ 2 ] ) ) , #NEWLINE# '?' : line . split ( '||' ) [ 1 ] . split ( '|' ) [ 3 ] , #NEWLINE# #UNINDENT# } #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( ( pintypes == 'poi' ) or ( pintypes == 'rentabike' ) or ( pintypes == 'ticketmachine' ) or ( pintypes == 'carsharing' ) or ( pintypes == 'parkandride' ) ) : #NEWLINE# #INDENT# return { #NEWLINE# #INDENT# 'id' : ':' . join ( line . split ( '||' ) [ 0 ] . split ( ':' ) [ : 3 ] ) , #NEWLINE# 'name' : line . split ( '||' ) [ 1 ] . split ( '|' ) [ 0 ] , #NEWLINE# 'coords' : pincoords_to_object ( int ( line . split ( '||' ) [ 1 ] . split ( '|' ) [ 1 ] ) , int ( line . split ( '||' ) [ 1 ] . split ( '|' ) [ 2 ] ) ) , #NEWLINE# #UNINDENT# }