How to call the two function for the ON and OFF for the toggle button

i want two function in my toggle function for ON and OFF .
If the toggle is on i want to call the toggleon();
if the toggle is off i want to call the toggleoff();
help me someone please … how to get this one;

What’s the point ? Why you don’t call a function that will handle both cases and call the good function ?
So you just have to ng-model your toggle button