Rapsys\AirBundle\Entity\Application:
    type: entity
    repositoryClass: Rapsys\AirBundle\Repository\ApplicationRepository
    table: applications
    id:
        id:
            type: integer
            generator: 
                strategy: AUTO
            options:
                unsigned: true
    fields:
        score:
            type: float
            nullable: true
        canceled:
            type: datetime
            nullable: true
        created:
            type: datetime
        updated:
            type: datetime
    manyToOne:
        dance:
            targetEntity: Rapsys\AirBundle\Entity\Dance
            inversedBy: applications
        session:
            targetEntity: Rapsys\AirBundle\Entity\Session
            inversedBy: applications
        user:
            targetEntity: Rapsys\AirBundle\Entity\User
            inversedBy: applications
    lifecycleCallbacks:
        preUpdate: ['preUpdate']
#    oneToMany:
#        votes:
#            targetEntity: Rapsys\AirBundle\Entity\Vote
#            mappedBy: application
#    indexes:
#        #XXX: used in SessionRepository::XXX
#        id_user:
#            columns: [ id, user_id ]
#        id_user_canceled:
#            columns: [ id, user_id, canceled ]