IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

Persistance des données Java Discussion :

Erreur "The hierarchy of the type is inconsistent"


Sujet :

Persistance des données Java

  1. #1
    Nouveau membre du Club
    Femme Profil pro
    etudiante
    Inscrit en
    Mars 2012
    Messages
    51
    Détails du profil
    Informations personnelles :
    Sexe : Femme
    Localisation : Tunisie

    Informations professionnelles :
    Activité : etudiante
    Secteur : Enseignement

    Informations forums :
    Inscription : Mars 2012
    Messages : 51
    Points : 38
    Points
    38
    Par défaut Erreur "The hierarchy of the type is inconsistent"
    Bonjour,

    Je suis en train de créer un projet J2EE sous Eclipse avec les frameworks Spring + iBatis mais lors de la génération des classes coresspondantes aux tables client et voiture, le compilateur m'indique cette erreur :
    The hierarchy of the type ClientDAOImpl is inconsistent
    sous le nom de la classe générée:
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    package com.AgenceLocation.server.ibatis.daoImpl;
     
    import com.AgenceLocation.server.ibatis.dao.ClientDAO;
    import com.AgenceLocation.server.ibatis.model.Client;
    import org.springframework.orm.ibatis.support.SqlMapClientDaoSupport;
     
    public class ClientDAOImpl extends SqlMapClientDaoSupport implements ClientDAO {
     
        /**
         * This method was generated by Apache iBATIS ibator. This method corresponds to the database table client
         * @ibatorgenerated  Sun Aug 12 10:19:53 CEST 2012
         */
        public ClientDAOImpl() {
            super();
        }
     
        /**
         * This method was generated by Apache iBATIS ibator. This method corresponds to the database table client
         * @ibatorgenerated  Sun Aug 12 10:19:53 CEST 2012
         */
        public int deleteByPrimaryKey(Integer carteIdentite) {
            Client key = new Client();
            key.setCarteIdentite(carteIdentite);
            int rows = getSqlMapClientTemplate().delete(
                    "client.ibatorgenerated_deleteByPrimaryKey", key);
            return rows;
        }
     
        /**
         * This method was generated by Apache iBATIS ibator. This method corresponds to the database table client
         * @ibatorgenerated  Sun Aug 12 10:19:53 CEST 2012
         */
        public void insert(Client record) {
            getSqlMapClientTemplate().insert("client.ibatorgenerated_insert",
                    record);
        }
     
        /**
         * This method was generated by Apache iBATIS ibator. This method corresponds to the database table client
         * @ibatorgenerated  Sun Aug 12 10:19:53 CEST 2012
         */
        public void insertSelective(Client record) {
            getSqlMapClientTemplate().insert(
                    "client.ibatorgenerated_insertSelective", record);
        }
     
        /**
         * This method was generated by Apache iBATIS ibator. This method corresponds to the database table client
         * @ibatorgenerated  Sun Aug 12 10:19:53 CEST 2012
         */
        public Client selectByPrimaryKey(Integer carteIdentite) {
            Client key = new Client();
            key.setCarteIdentite(carteIdentite);
            Client record = (Client) getSqlMapClientTemplate().queryForObject(
                    "client.ibatorgenerated_selectByPrimaryKey", key);
            return record;
        }
     
        /**
         * This method was generated by Apache iBATIS ibator. This method corresponds to the database table client
         * @ibatorgenerated  Sun Aug 12 10:19:53 CEST 2012
         */
        public int updateByPrimaryKeySelective(Client record) {
            int rows = getSqlMapClientTemplate().update(
                    "client.ibatorgenerated_updateByPrimaryKeySelective", record);
            return rows;
        }
     
        /**
         * This method was generated by Apache iBATIS ibator. This method corresponds to the database table client
         * @ibatorgenerated  Sun Aug 12 10:19:53 CEST 2012
         */
        public int updateByPrimaryKey(Client record) {
            int rows = getSqlMapClientTemplate().update(
                    "client.ibatorgenerated_updateByPrimaryKey", record);
            return rows;
        }
    }
    J'ai paramétré le Build Path et j'ai actualisé le projet mais le problème persiste.

    Quelqu'un saurait-il m'indiquer comment résoudre ce problème ?

    Merci d'avance pour votre aide.

  2. #2
    Membre averti
    Homme Profil pro
    Inscrit en
    Octobre 2011
    Messages
    250
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : Belgique

    Informations forums :
    Inscription : Octobre 2011
    Messages : 250
    Points : 403
    Points
    403
    Par défaut
    Peux-tu poster la stacktrace complète, est-ce que c'est spring ou ibatis qui génère l'erreur ?

  3. #3
    Expert éminent sénior
    Avatar de tchize_
    Homme Profil pro
    Ingénieur développement logiciels
    Inscrit en
    Avril 2007
    Messages
    25 481
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Âge : 44
    Localisation : Belgique

    Informations professionnelles :
    Activité : Ingénieur développement logiciels
    Secteur : High Tech - Éditeur de logiciels

    Informations forums :
    Inscription : Avril 2007
    Messages : 25 481
    Points : 48 806
    Points
    48 806
    Par défaut
    De mémoire, ce genre d'erreur arrive quand une des classes parentes ou interfaces implémentées par ClientDAOImpl n'est pas présente dans le classpath ou a changé de nature depuis la compilation de ClientDAOImpl (par exemple ClientDAO serait devenu un classe abstraite ou SqlMapClientDaoSupport serait devenu une interface)

Discussions similaires

  1. [Kepler ou Luna] The hierarchy of the type .. is inconsistent
    Par regis1512 dans le forum Eclipse Java
    Réponses: 12
    Dernier message: 03/12/2014, 21h31
  2. [SimpleXML] Erreur LibXml "Extra content at the end of the document" malgré XML valide
    Par saintbios dans le forum Bibliothèques et frameworks
    Réponses: 3
    Dernier message: 26/07/2012, 14h57
  3. The hierarchy of the type is inconsistent
    Par ramijrad dans le forum Débuter avec Java
    Réponses: 3
    Dernier message: 30/03/2011, 15h28
  4. Réponses: 1
    Dernier message: 22/04/2010, 12h24
  5. Réponses: 2
    Dernier message: 14/04/2009, 16h22

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo