def METHOD_NAME(state):
    proto_map = {
        ip_descriptor.IPState.FREE: IPDesc.FREE,
        ip_descriptor.IPState.ALLOCATED: IPDesc.ALLOCATED,
        ip_descriptor.IPState.RELEASED: IPDesc.RELEASED,
        ip_descriptor.IPState.REAPED: IPDesc.REAPED,
        ip_descriptor.IPState.RESERVED: IPDesc.RESERVED,
    }
    proto = proto_map[state]
    return proto