alvinalexander.com | career | drupal | java | mac | mysql | perl | scala | uml | unix  

Hibernate example source code file (inheritance_mapping.po)

This example Hibernate source code file (inheritance_mapping.po) is included in the DevDaily.com "Java Source Code Warehouse" project. The intent of this project is to help you "Learn Java by Example" TM.

Java - Hibernate tags/keywords

hibernate, hibernate, il, la, payment, polymorphic, polymorphic, polymorphisme, table, tag, tag, the, une, une

The Hibernate inheritance_mapping.po source code

# translation of inheritance_mapping.po to French
# Myriam Malga <mmalga@redhat.com>, 2007.
# Xi HUANG <xhuang@redhat.com>, 2007.
# Corina Roe <croe@redhat.com>, 2009, 2010.
# translation of Collection_Mapping.po to
msgid ""
msgstr ""
"Project-Id-Version: inheritance_mapping\n"
"Report-Msgid-Bugs-To: http://bugs.kde.org\n"
"POT-Creation-Date: 2010-02-11T05:38:15\n"
"PO-Revision-Date: 2010-01-05 09:37+1000\n"
"Last-Translator: Corina Roe <croe@redhat.com>\n"
"Language-Team: French <i18@redhat.com>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Generator: KBabel 1.11.4\n"

#. Tag: title
#, no-c-format
msgid "Inheritance mapping"
msgstr "Mapping d'héritage de classe "

#. Tag: title
#, no-c-format
msgid "The three strategies"
msgstr "Les trois stratégies "

#. Tag: para
#, no-c-format
msgid "Hibernate supports the three basic inheritance mapping strategies:"
msgstr "Hibernate supporte les trois stratégies d'héritage de base :"

#. Tag: para
#, no-c-format
msgid "table per class hierarchy"
msgstr "une table par hiérarchie de classe"

#. Tag: para
#, fuzzy, no-c-format
msgid "table per subclass"
msgstr "Une table par classe fille"

#. Tag: para
#, no-c-format
msgid "table per concrete class"
msgstr "une table par classe concrète "

#. Tag: para
#, no-c-format
msgid ""
"In addition, Hibernate supports a fourth, slightly different kind of "
"polymorphism:"
msgstr ""
"Par ailleurs, Hibernate supporte une quatrième stratégie, avec un "
"polymorphisme légèrement différent : "

#. Tag: para
#, no-c-format
msgid "implicit polymorphism"
msgstr "le polymorphisme implicite"

#. Tag: para
#, no-c-format
msgid ""
"It is possible to use different mapping strategies for different branches of "
"the same inheritance hierarchy. You can then make use of implicit "
"polymorphism to achieve polymorphism across the whole hierarchy. However, "
"Hibernate does not support mixing <literal><subclass>, "
"<literal><joined-subclass> and <union-"
"subclass></literal> mappings under the same root <class><subclass> and "
"<literal><join> elements (see below for an example)."
msgstr ""
"Il est possible d'utiliser différentes stratégies de mapping pour "
"différentes branches d'une même hiérarchie d'héritage, et ensuite d'employer "
"le polymorphisme implicite pour réaliser le polymorphisme à travers toute la "
"hiérarchie. Toutefois, Hibernate ne supporte pas les mélanges de mappages "
"<literal><subclass>, <joined-subclass><union-subclass> pour le même élément "
"<literal><class> racine. Il est possible de mélanger les "
"stratégies d'une table par hiérarchie et d'une table par sous-classe, pour "
"le même élément <literal><class>, en combinant les éléments "
"<literal><subclass> et <join> (voir "
"ci-dessous). "

#. Tag: para
#, no-c-format
msgid ""
"It is possible to define <literal>subclass, union-"
"subclass</literal>, and joined-subclass mappings in "
"separate mapping documents directly beneath <literal>hibernate-mapping attribute in "
"the subclass mapping, naming a previously mapped superclass. Previously this "
"feature made the ordering of the mapping documents important. Since "
"Hibernate3, the ordering of mapping files is irrelevant when using the "
"extends keyword. The ordering inside a single mapping file still needs to be "
"defined as superclasses before subclasses."
msgstr ""
"Il est possible de définir des mappages de <literal>subclass, "
"<literal>union-subclass, et joined-subclass "
"dans des documents de mappage séparés, directement sous <literal>hibernate-"
"mappage</literal>. Ceci vous permet d'étendre une hiérarchie de classe juste "
"en ajoutant un nouveau fichier de mappage. Vous devez spécifier un attribut "
"<literal>extends dans le mappage de la sous-classe, en nommant une "
"super-classe précédemment mappée. Note : précédemment cette fonctionnalité "
"rendait important l'ordre des documents de mappage. Depuis Hibernate3, "
"l'ordre des fichier de mappage n'importe plus lors de l'utilisation du mot-"
"clef \"extends\". L'ordre à l'intérieur d'un simple fichier de mappage "
"impose encore de définir les classes mères avant les classes filles. "

#. Tag: title
#, no-c-format
msgid "Table per class hierarchy"
msgstr "Une table par hiérarchie de classe"

#. Tag: para
#, no-c-format
msgid ""
"Suppose we have an interface <literal>Payment with the "
"implementors <literal>CreditCardPayment, CashPaymentChequePayment. The table per hierarchy "
"mapping would display in the following way:"
msgstr ""
"Supposons que nous ayons une interface <literal>Payment, "
"implémentée par <literal>CreditCardPayment, CashPaymentChequePayment. La stratégie une table par "
"hiérarchie serait : "

#. Tag: para
#, no-c-format
msgid ""
"Exactly one table is required. There is a limitation of this mapping "
"strategy: columns declared by the subclasses, such as <literal>CCTYPENOT NULL constraints."
msgstr ""
"Une seule table est requise. Une grande limitation de cette stratégie est "
"que les colonnes déclarées par les classes filles, telles que "
"<literal>CCTYPE, peuvent ne pas avoir de contrainte NOT "
"NULL</literal>. "

#. Tag: title
#, no-c-format
msgid "Table per subclass"
msgstr "Une table par classe fille"

#. Tag: para
#, no-c-format
msgid "A table per subclass mapping looks like this:"
msgstr "Une table par classe-fille de mappage serait : "

#. Tag: para
#, no-c-format
msgid ""
"Four tables are required. The three subclass tables have primary key "
"associations to the superclass table so the relational model is actually a "
"one-to-one association."
msgstr ""
"Quatre tables sont requises. Les trois tables des classes filles ont une clé "
"primaire associée à la table classe mère (le modèle relationnel est une "
"association un-à-un)."

#. Tag: title
#, no-c-format
msgid "Table per subclass: using a discriminator"
msgstr "Une table par classe fille, en utilisant un discriminant "

#. Tag: para
#, no-c-format
msgid ""
"Hibernate's implementation of table per subclass does not require a "
"discriminator column. Other object/relational mappers use a different "
"implementation of table per subclass that requires a type discriminator "
"column in the superclass table. The approach taken by Hibernate is much more "
"difficult to implement, but arguably more correct from a relational point of "
"view. If you want to use a discriminator column with the table per subclass "
"strategy, you can combine the use of <literal><subclass> and "
"<literal><join>, as follows:"
msgstr ""
"Notez que l'implémentation Hibernate de la stratégie une table par classe "
"fille, ne nécessite pas de colonne discriminante dans la table classe mère. "
"D'autres implémentations de mappers Objet/Relationnel utilisent une autre "
"implémentation de la stratégie une table par classe fille qui nécessite une "
"colonne de type discriminant dans la table de la classe mère. L'approche "
"prise par Hibernate est plus difficile à implémenter mais plus correcte "
"d'une point de vue relationnel. Si vous aimeriez utiliser une colonne "
"discriminante avec la stratégie d'une table par classe fille, vous pouvez "
"combiner l'utilisation de <literal><subclass> et "
"<literal><join>, comme suit : "

#. Tag: para
#, no-c-format
msgid ""
"The optional <literal>fetch=\"select\" declaration tells Hibernate "
"not to fetch the <literal>ChequePayment subclass data using an "
"outer join when querying the superclass."
msgstr ""
"La déclaration optionnelle <literal>fetch=\"select\" indique à "
"Hibernate de ne pas récupérer les données de la classe fille "
"<literal>ChequePayment par une jointure externe lors des requêtes "
"sur la classe mère. "

#. Tag: title
#, no-c-format
msgid "Mixing table per class hierarchy with table per subclass"
msgstr ""
"Mélange d'une table par hiérarchie de classe avec une table par classe fille"

#. Tag: para
#, no-c-format
msgid ""
"You can even mix the table per hierarchy and table per subclass strategies "
"using the following approach:"
msgstr ""
"Vous pouvez même mélanger les stratégies d'une table par hiérarchie de "
"classe et d'une table par classe fille en utilisant cette approche : "

#. Tag: para
#, no-c-format
msgid ""
"For any of these mapping strategies, a polymorphic association to the root "
"<literal>Payment class is mapped using <many-to-one>"
"</literal>."
msgstr ""
"Pour importe laquelle de ces stratégies, une association polymorphique vers "
"la classe racine <literal>Payment est mappée en utilisant "
"<literal><many-to-one>."

#. Tag: title
#, no-c-format
msgid "Table per concrete class"
msgstr "Une table par classe concrète"

#. Tag: para
#, no-c-format
msgid ""
"There are two ways we can map the table per concrete class strategy. First, "
"you can use <literal><union-subclass>."
msgstr ""
"Il y a deux manières d'utiliser la stratégie d'une table par classe "
"concrète. La première est d'employer <literal><union-subclass> in the example above), is needed to hold "
"instances of the superclass."
msgstr ""
"Si votre classe mère est abstraite, mappez la avec <literal>abstract=\"true"
"\"</literal>. Bien sûr, si elle n'est pas abstraite, une table "
"supplémentaire (par défaut, <literal>PAYMENT dans l'exemple ci-"
"dessus) est requise pour contenir des instances de la classe mère. "

#. Tag: title
#, no-c-format
msgid "Table per concrete class using implicit polymorphism"
msgstr ""
"Une table par classe concrète, en utilisant le polymorphisme implicite "

#. Tag: para
#, no-c-format
msgid "An alternative approach is to make use of implicit polymorphism:"
msgstr "Une approche alternative est l'emploi du polymorphisme implicite :"

#. Tag: para
#, fuzzy, no-c-format
msgid ""
"Notice that the <literal>Payment interface is not mentioned "
"explicitly. Also notice that properties of <literal>Payment are "
"mapped in each of the subclasses. If you want to avoid duplication, consider "
"using XML entities (for example, <literal>[ <!ENTITY allproperties SYSTEM "
"\"allproperties.xml\"> ]</literal> in the DOCTYPE "
"declaration and <literal>&allproperties; in the mapping)."
msgstr ""
"Notez que nulle part nous ne mentionnons l'interface <literal>PaymentPayment et dans le mappage "
"<literal>&allproperties;). "

#. Tag: para
#, no-c-format
msgid ""
"The disadvantage of this approach is that Hibernate does not generate SQL "
"<literal>UNIONs when performing polymorphic queries."
msgstr ""
"L'inconvénient de cette approche est que Hibernate ne génère pas de SQL "
"<literal>UNION s lors de l'exécution des requêtes polymorphiques. "

#. Tag: para
#, no-c-format
msgid ""
"For this mapping strategy, a polymorphic association to <literal>Payment<any>."
msgstr ""
"Pour cette stratégie de mappage, une association polymorphique pour "
"<literal>Payment est habituellement mappée en utilisant "
"<literal><any>. "

#. Tag: title
#, no-c-format
msgid "Mixing implicit polymorphism with other inheritance mappings"
msgstr "Mélange du polymorphisme implicite avec d'autres mappages d'héritage "

#. Tag: para
#, no-c-format
msgid ""
"Since the subclasses are each mapped in their own <literal><class>Payment is just an "
"interface), each of the subclasses could easily be part of another "
"inheritance hierarchy. You can still use polymorphic queries against the "
"<literal>Payment interface."
msgstr ""
"Il y a une chose supplémentaire à noter à propos de ce mappage. Puisque les "
"classes filles sont chacune mappées avec leur propre élément <literal><"
"class></literal> (et puisque Payment est juste une "
"interface), chaque classe fille pourrait facilement faire partie d'une autre "
"hiérarchie d'héritage ! (Et vous pouvez encore faire des requêtes "
"polymorphiques pour l'interface <literal>Payment). "

#. Tag: para
#, no-c-format
msgid ""
"Once again, <literal>Payment is not mentioned explicitly. If we "
"execute a query against the <literal>Payment interface, for "
"example <literal>from Payment, Hibernate automatically returns "
"instances of <literal>CreditCardPayment (and its subclasses, since "
"they also implement <literal>Payment), CashPaymentChequePayment, but not instances of "
"<literal>NonelectronicTransaction."
msgstr ""
"Encore une fois, nous ne mentionnons pas explicitement <literal>PaymentPaymentfrom Payment - Hibernate "
"retournera automatiquement les instances de <literal>CreditCardPayment), CashPayment et "
"<literal>ChequePayment mais pas les instances de "
"<literal>NonelectronicTransaction. "

#. Tag: title
#, no-c-format
msgid "Limitations"
msgstr "Limitations"

#. Tag: para
#, no-c-format
msgid ""
"There are limitations to the \"implicit polymorphism\" approach to the table "
"per concrete-class mapping strategy. There are somewhat less restrictive "
"limitations to <literal><union-subclass> mappings."
msgstr ""
"Il y a certaines limitations à l'approche du \"polymorphisme implicite\" "
"pour la stratégie de mappage d'une table par classe concrète. Il y a plutôt "
"moins de limitations restrictives aux mappages <literal><union-"
"subclass></literal>. "

#. Tag: para
#, fuzzy, no-c-format
msgid ""
"The following table shows the limitations of table per concrete-class "
"mappings, and of implicit polymorphism, in Hibernate."
msgstr ""
"La table suivante montre les limitations des mappages d'une table par classe "
"concrète, et du polymorphisme implicite, dans Hibernate. "

#. Tag: title
#, fuzzy, no-c-format
msgid "Features of inheritance mappings"
msgstr "Mapping d'héritage de classe "

#. Tag: entry
#, fuzzy, no-c-format
msgid "Inheritance strategy"
msgstr "Mapping d'héritage de classe "

#. Tag: entry
#, fuzzy, no-c-format
msgid "Polymorphic many-to-one"
msgstr "Polymorphisme many-to-one : <code><any>"

#. Tag: entry
#, no-c-format
msgid "Polymorphic one-to-one"
msgstr ""

#. Tag: entry
#, no-c-format
msgid "Polymorphic one-to-many"
msgstr ""

#. Tag: entry
#, fuzzy, no-c-format
msgid "Polymorphic many-to-many"
msgstr "Polymorphisme many-to-one : <code><any>"

#. Tag: entry
#, no-c-format
msgid "Polymorphic <literal>load()/get()"
msgstr ""

#. Tag: entry
#, no-c-format
msgid "Polymorphic queries"
msgstr ""

#. Tag: entry
#, no-c-format
msgid "Polymorphic joins"
msgstr ""

#. Tag: entry
#, fuzzy, no-c-format
msgid "Outer join fetching"
msgstr "Récupération par jointure externe supportée."

#. Tag: entry
#, fuzzy, no-c-format
msgid "table per class-hierarchy"
msgstr "une table par hiérarchie de classe"

#. Tag: entry
#, no-c-format
msgid "<literal><many-to-one>"
msgstr ""

#. Tag: entry
#, no-c-format
msgid "<literal><one-to-one>"
msgstr ""

#. Tag: entry
#, no-c-format
msgid "<literal><one-to-many>"
msgstr ""

#. Tag: entry
#, no-c-format
msgid "<literal><many-to-many>"
msgstr ""

#. Tag: entry
#, no-c-format
msgid "<literal>s.get(Payment.class, id)"
msgstr ""

#. Tag: entry
#, no-c-format
msgid "<literal>from Payment p"
msgstr ""

#. Tag: entry
#, fuzzy, no-c-format
msgid "<literal>from Order o join o.payment p"
msgstr "Jointures polymorphiques <code>from o join o.payment p"

#. Tag: entry
#, no-c-format
msgid "<emphasis>supported"
msgstr ""

#. Tag: entry
#, no-c-format
msgid "table per concrete-class (union-subclass)"
msgstr "une table par classe concrète (union-classe fille)"

#. Tag: entry
#, fuzzy, no-c-format
msgid ""
"<literal><one-to-many> (for inverse=\"true\" "
"(uniquement pour <literal>inverse=\"true\")"

#. Tag: entry
#, fuzzy, no-c-format
msgid "table per concrete class (implicit polymorphism)"
msgstr "une table par classe concrète (polymorphisme implicite) "

#. Tag: entry
#, no-c-format
msgid "<literal><any>"
msgstr ""

#. Tag: entry
#, no-c-format
msgid "<emphasis>not supported"
msgstr ""

#. Tag: entry
#, no-c-format
msgid "<literal><many-to-any>"
msgstr ""

#. Tag: entry
#, fuzzy, no-c-format
msgid ""
"<literal>s.createCriteria(Payment.class).add( Restrictions.idEq(id) )."
"uniqueResult()</literal>"
msgstr ""
"Polymorphisme <literal>load() ou get(): s."
"createCriteria(Payment.class).add( Restrictions.idEq(id) ).uniqueResult()</"
"code>"

#~ msgid "table per class-heirarchy"
#~ msgstr "une table par hiérarchie de classe "

#~ msgid "Polymorphic many-to-one: <code><many-to-one>"
#~ msgstr "Polymorphisme many-to-one : <code><many-to-one>"

#~ msgid "Polymorphic one-to-one: <code><one-to-one>"
#~ msgstr "Polymorphisme one-to-one : <code><one-to-one>"

#~ msgid "Polymorphic one-to-many: <code><one-to-many>"
#~ msgstr "Polymorphisme one-to-many : <code><one-to-many>"

#~ msgid "Polymorphic many-to-many: <code><many-to-many>"
#~ msgstr "Polymorphisme many-to-many : <code><many-to-many>"

#~ msgid ""
#~ "Polymorphic <literal>load() or get(): "
#~ "<code>s.get(Payment.class, id)"
#~ msgstr ""
#~ "Polymorphisme <literal>load() ou get(): "
#~ "<code>s.get(Payment.class, id)"

#~ msgid "Polymorphic queries: <code>from Payment p"
#~ msgstr "Requêtes polymorphiques : <code>from Payment p"

#~ msgid ""
#~ "Polymorphic one-to-one, polymorphic one-to-many, polymorphic joins, and "
#~ "outer join fetching are not supported."
#~ msgstr ""
#~ "Polymorphisme one-to-one, polymorphisme one-to-many, les jointures "
#~ "polymorphiques, et les récupération de jointures externes ne sont pas "
#~ "supportées."

#, fuzzy
#~ msgid "<para>table per subclass"
#~ msgstr "Une table par classe fille "

#, fuzzy
#~ msgid "<term>table per subclass"
#~ msgstr "Une table par classe fille "

Other Hibernate examples (source code examples)

Here is a short list of links related to this Hibernate inheritance_mapping.po source code file:

... this post is sponsored by my books ...

#1 New Release!

FP Best Seller

 

new blog posts

 

Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.

A percentage of advertising revenue from
pages under the /java/jwarehouse URI on this website is
paid back to open source projects.