def _get_subnet_explicit_route_table(subnet_id, vpc_id, conn=None, region=None, key=None, keyid=None, profile=None):
 if (not conn):
  conn = _get_conn(region=region, key=key, keyid=keyid, profile=profile)
 if conn:
  vpc_route_tables = conn.get_all_route_tables(filters={'vpc_id': vpc_id})
  for vpc_route_table in vpc_route_tables:
   for rt_association in vpc_route_table.associations:
    if ((rt_association.subnet_id == subnet_id) and (not rt_association.main)):
     return rt_association.id
 return None

def _get_subnet_explicit_route_table ( subnet_id , vpc_id , conn = None , region = None , key = None , keyid = None , profile = None ) : if ( not conn ) : conn = _get_conn ( region = region , key = key , keyid = keyid , profile = profile ) if conn : vpc_route_tables = conn . get_all_route_tables ( filters = { 'vpc_id' : vpc_id } ) for vpc_route_table in vpc_route_tables : for rt_association in vpc_route_table . associations : if ( ( rt_association . subnet_id == subnet_id ) and ( not rt_association . main ) ) : return rt_association . id return None
helper function to find subnet explicit route table associations .