Rights of the child, European Pact on Migration and Asylum, Immigration detention, Measure of protection, Jurisprudence