def is_valid_state(state):
 return (state in const.BGP_FSM_VALID_STATES)

def is_valid_state ( state ) : return ( state in const . BGP_FSM_VALID_STATES )
returns true if given state is a valid bgp finite state machine state .