Boundary condition for a wild object

As all of them are lines you can use subdomains to mark a mesh function, as shown here: