It works like this: you detain a person for 48 hours, then release him and when he is at the exit, detain him once more. Repeat as needed. Probably you would need to find another formal reason for a detainment (I'm not sure though), but seems it is not very difficult. They did something like just this summer, when protests was going against infringements with voting.