def METHOD_NAME(c, shell, filter_):
    shellCells = shell.cells()
    smtk.mesh.for_each(shellCells, filter_)
    filteredCells = smtk.mesh.CellSet(c, filter_.validPoints)
    domains = c.domains()
    for dom in domains:
        domainMeshes = c.meshes(dom)
        domainCells = domainMeshes.cells()
        contactCells = smtk.mesh.point_intersect(
            domainCells, filteredCells, smtk.mesh.FullyContained)
        if not contactCells.is_empty():
            contactD = c.createMesh(contactCells)
            c.setDirichletOnMeshes(contactD,
                                   smtk.mesh.Dirichlet(
                                       METHOD_NAME.nextDirId))
            METHOD_NAME.nextDirId += 1
    return True