What is a more Pythonic way of setting the value of multiple attributes? When a custom property is updated, this function is triggered and changes the boolean value of all the 10 others. It's a long and dirty code... is there better way to do it ?

def swap(prop):
    s = bpy.context.scene
    if prop == 'meshes':
        v = not s.meshes
        s.meshes = not v
        s.lights = v
        s.cameras = v
        s.nurbs = v
        s.lattices = v
        s.empties = v
        s.texts = v
        s.bones = v
        s.surfaces = v
        s.metaballs = v
        s.fields = v
    elif prop == 'lights':
        v = not s.lights
        s.meshes = v
        s.lights = not v
        s.cameras = v
        s.nurbs = v
        s.lattices = v
        s.empties = v
        s.texts = v
        s.bones = v
        s.surfaces = v
        s.metaballs = v
        s.fields = v
    elif prop == 'cameras':
        v = not s.cameras
        s.meshes = v
        s.lights = v
        s.cameras = not v
        s.nurbs = v
        ... and so on (11 times)
something like this

def swap(prop):
    s = bpy.context.scene
    v = not getattr(s, prop)

    attributes = 'meshes lights cameras nurbs lattices empties texts bones surfaces metaballs fields'.split(' ')
    for attribute in attributes:
        setattr(s, attribute, not v if prop == attribute else v)


but achieving pythonic code is a quest for a different stack exchange site, like stack overflow