def explode_rdn(rdn, notypes=0, flags=0):
 if (not rdn):
  return []
 rdn_decomp = str2dn(rdn, flags)[0]
 if notypes:
  return [(avalue or '') for (atype, avalue, dummy) in rdn_decomp]
 else:
  return ['='.join((atype, escape_dn_chars((avalue or '')))) for (atype, avalue, dummy) in rdn_decomp]

def explode_rdn ( rdn , notypes = 0 , flags = 0 ) : if ( not rdn ) : return [ ] rdn_decomp = str2dn ( rdn , flags ) [ 0 ] if notypes : return [ ( avalue or '' ) for ( atype , avalue , dummy ) in rdn_decomp ] else : return [ '=' . join ( ( atype , escape_dn_chars ( ( avalue or '' ) ) ) ) for ( atype , avalue , dummy ) in rdn_decomp ]
explode_rdn -> list this function takes a rdn and breaks it up into its component parts if it is a multi-valued rdn .