Ex's boyfriend with kids

What would it take to prove he is a danger and get this order? Would a judge order this if I say I believe he is a danger to the children?