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

Hibernate example source code file (association_mapping.po)

This example Hibernate source code file (association_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

a, address, address, associations, cdata, cdata, hibernate, nous, person, person, personaddress, tag, tag, une

The Hibernate association_mapping.po source code

# translation of association_mapping.po to French
# Myriam Malga <mmalga@redhat.com>, 2007.
# Xi HUANG <xhuang@redhat.com>, 2007.
# Corina Roe <croe@redhat.com>, 2009.
# translation of Collection_Mapping.po to
msgid ""
msgstr ""
"Project-Id-Version: association_mapping\n"
"Report-Msgid-Bugs-To: http://bugs.kde.org\n"
"POT-Creation-Date: 2010-02-10T07:25:34\n"
"PO-Revision-Date: 2009-11-10 14:49+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 "Association Mappings"
msgstr "Mapper les associations"

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

#. Tag: para
#, no-c-format
msgid ""
"Association mappings are often the most difficult thing to implement "
"correctly. In this section we examine some canonical cases one by one, "
"starting with unidirectional mappings and then bidirectional cases. We will "
"use <literal>Person and Address in all the "
"examples."
msgstr ""
"Mapper les associations correctement, est souvent la tâche la plus "
"difficile. Dans cette section, nous traiterons les cas classiques, un par "
"un, en commençant par les mappages unidirectionnels, puis nous aborderons la "
"question des mappages bidirectionnels. Nous illustrons tous nos exemples "
"avec les classes <literal>Person et Address."

#. Tag: para
#, no-c-format
msgid ""
"Associations will be classified by multiplicity and whether or not they map "
"to an intervening join table."
msgstr ""
"Nous classifions les associations selon qu'elles sont ou non bâties sur une "
"table de jointure supplémentaire et sur la multiplicité. "

#. Tag: para
#, no-c-format
msgid ""
"Nullable foreign keys are not considered to be good practice in traditional "
"data modelling, so our examples do not use nullable foreign keys. This is "
"not a requirement of Hibernate, and the mappings will work if you drop the "
"nullability constraints."
msgstr ""
"Autoriser une clé étrangère nulle est considéré comme un mauvais choix dans "
"la construction d'un modèle de données. Nous supposerons donc que dans tous "
"les exemples qui vont suivre on aura interdit la valeur nulle pour les clés "
"étrangères. Attention, ceci ne veut pas dire que Hibernate ne supporte pas "
"les clés étrangères pouvant prendre des valeurs nulles, et les exemples qui "
"suivent continueront de fonctionner si vous décidiez ne plus imposer la "
"contrainte de non-nullité sur les clés étrangères."

#. Tag: title
#, no-c-format
msgid "Unidirectional associations"
msgstr "Associations unidirectionnelles"

#. Tag: title
#, no-c-format
msgid "Many-to-one"
msgstr "plusieurs-à-un "

#. Tag: para
#, no-c-format
msgid ""
"A <emphasis>unidirectional many-to-one association is the most "
"common kind of unidirectional association."
msgstr ""
"Une <emphasis>association plusieurs-à-un unidirectionnelle  est "
"le type que l'on rencontre le plus souvent dans les associations "
"unidirectionnelles."

#. Tag: title
#, no-c-format
msgid "One-to-one"
msgstr "Un-à-un"

#. Tag: para
#, no-c-format
msgid ""
"A <emphasis>unidirectional one-to-one association on a foreign key est "
"presque identique. La seule différence est sur la contrainte d'unicité que "
"l'on impose à cette colonne."

#. Tag: para
#, no-c-format
msgid ""
"A <emphasis>unidirectional one-to-one association on a primary keyunique=\"true\", on a changé la multiplicité plusieurs-à-"
"plusieurs pour un-à-plusieurs. "

#. Tag: para
#, no-c-format
msgid ""
"A <emphasis>unidirectional many-to-one association on a join table "
"is possible, but extremely unusual."
msgstr ""
"Une <emphasis>association unidirectionnelle un-à-un sur une table de "
"jointure</emphasis> est extrêmement rare mais envisageable. "

#. Tag: title
#, no-c-format
msgid "Many-to-many"
msgstr "Plusieurs-à-plusieurs "

#. Tag: para
#, no-c-format
msgid ""
"Finally, here is an example of a <emphasis>unidirectional many-to-many "
"association</emphasis>."
msgstr ""
"Finalement, nous avons un exemple d' <emphasis>association unidirectionnelle "
"plusieurs-à-plusieurs</emphasis>."

#. Tag: title
#, no-c-format
msgid "Bidirectional associations"
msgstr "Associations bidirectionnelles "

#. Tag: title
#, no-c-format
msgid "one-to-many / many-to-one"
msgstr "un-à-plusieurs / plusieurs-à-un "

#. Tag: para
#, no-c-format
msgid ""
"A <emphasis>bidirectional many-to-one association is the most "
"common kind of association. The following example illustrates the standard "
"parent/child relationship."
msgstr ""
"Une <emphasis>association bidirectionnelle plusieurs-à-un est le "
"type d'association que l'on rencontre le plus fréquemment. L'exemple suivant "
"illustre la façon standard de créer des relations parents/enfants."

#. Tag: para
#, no-c-format
msgid ""
"If you use a <literal>List, or other indexed collection, set the "
"<literal>key column of the foreign key to not null and insert=\"false"
"\"</literal>:"
msgstr ""
"Si vous utilisez une <literal>List, ou toute autre collection "
"indexée, vous devez paramétrer la colonne <literal>key de la clé "
"étrangère à <literal>not null, et laisser Hibernate gérer "
"l'association depuis l'extrémité collection pour maintenir l'index de chaque "
"élément (rendant l'autre extrémité virtuellement inverse en paramétrant "
"<literal>update=\"false\" et insert=\"false\") :"

#. Tag: para
#, no-c-format
msgid ""
"If the underlying foreign key column is <literal>NOT NULL, it is "
"important that you define <literal>not-null=\"true\" on the "
"<literal><key> element of the collection mapping. Do not "
"only declare <literal>not-null=\"true\" on a possible nested "
"<literal><column> element, but on the <key> sur l'élément "
"<literal><key> du mapping de la collection si la colonne de "
"clé étrangère sous-jacente est <literal>NOT NULL. Ne déclarez pas "
"seulement <literal>not-null=\"true\" sur un élément imbriqué "
"possible<literal><column>, mais sur l'élément <"
"key></literal>."

#. Tag: para
#, no-c-format
msgid ""
"A <emphasis>bidirectional one-to-one association on a foreign key "
"is common:"
msgstr ""
"Une <emphasis>association bidirectionnelle un-à-un sur une clé étrangère "
"uses the special id generator:"
msgstr ""
"Une <emphasis>association bidirectionnelle un-à-un sur une clé primaireinverse=\"true\"inverse=\"true\" peut "
"s'appliquer sur les deux extrémités de l'association, sur la collection, ou "
"sur la jointure."

#. Tag: title
#, no-c-format
msgid "one to one"
msgstr "un-à-un"

#. Tag: para
#, no-c-format
msgid ""
"A <emphasis>bidirectional one-to-one association on a join table "
"is possible, but extremely unusual."
msgstr ""
"Une <emphasis>association bidirectionnelle un-à-un sur une table de "
"jointure</emphasis> est extrêmement rare mais envisageable. "

#. Tag: para
#, no-c-format
msgid ""
"Here is an example of a <emphasis>bidirectional many-to-many association rare. "
"Hibernate handles more complex situations by using SQL fragments embedded in "
"the mapping document. For example, if a table with historical account "
"information data defines <literal>accountNumber, "
"<literal>effectiveEndDate and effectiveStartDate "
"rares. Hibernate permet de gérer des situations plus complexes en utilisant "
"des extraits SQL embarqués dans le fichier de mapping. Par exemple, si une "
"table avec des informations historiques sur un compte définit les colonnes "
"<literal>accountNumber, effectiveEndDate et "
"<literal>effectiveStartDate, elle sera mappée de la façon "
"suivante : "

#. Tag: para
#, no-c-format
msgid ""
"You can then map an association to the <emphasis>current "
"instance, the one with null <literal>effectiveEndDate, by using:"
msgstr ""
"Nous pouvons mapper une association à l'instance <emphasis>couranteeffectiveEndDate nulle, en "
"utilisant :"

#. Tag: para
#, no-c-format
msgid ""
"In a more complex example, imagine that the association between "
"<literal>Employee and Organization is "
"maintained in an <literal>Employment table full of historical "
"employment data. An association to the employee's <emphasis>most recentstartDate et Organization soit gérée "
"dans une table <literal>Employment pleine de données historiques. "
"Dans ce cas, une association vers l'employeur <emphasis>le plus récentstartDate (date de commencement "
"de travail la plus récente) pourrait être mappée comme suit :"

#. Tag: para
#, no-c-format
msgid ""
"This functionality allows a degree of creativity and flexibility, but it is "
"more practical to handle these kinds of cases using HQL or a criteria query."
msgstr ""
"Vous pouvez être créatif grâce à ces possibilités, mais il est généralement "
"plus pratique de gérer ce genre de cas en utilisant des requêtes HQL ou par "
"critère."

#~ msgid ""
#~ "<![CDATA["
#~ msgstr ""
#~ "<![CDATA["

#~ msgid ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key, addressId "
#~ "bigint not null )\n"
#~ "create table Address ( addressId bigint not null primary key )\n"
#~ "        ]]>"
#~ msgstr ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key, addressId "
#~ "bigint not null )\n"
#~ "create table Address ( addressId bigint not null primary key )\n"
#~ "        ]]>"

#~ msgid ""
#~ "<![CDATA["
#~ msgstr ""
#~ "<![CDATA["

#~ msgid ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key, addressId "
#~ "bigint not null unique )\n"
#~ "create table Address ( addressId bigint not null primary key )\n"
#~ "        ]]>"
#~ msgstr ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key, addressId "
#~ "bigint not null unique )\n"
#~ "create table Address ( addressId bigint not null primary key )\n"
#~ "        ]]>"

#~ msgid ""
#~ "<![CDATA[\n"
#~ "        </generator>\n"
#~ "    </id>\n"
#~ "    <one-to-one name=\"person\" constrained=\"true\"/>\n"
#~ "</class>]]>"
#~ msgstr ""
#~ "<![CDATA[\n"
#~ "        </generator>\n"
#~ "    </id>\n"
#~ "    <one-to-one name=\"person\" constrained=\"true\"/>\n"
#~ "</class>]]>"

#~ msgid ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key )\n"
#~ "create table Address ( personId bigint not null primary key )\n"
#~ "        ]]>"
#~ msgstr ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key )\n"
#~ "create table Address ( personId bigint not null primary key )\n"
#~ "        ]]>"

#~ msgid ""
#~ "<![CDATA["
#~ msgstr ""
#~ "<![CDATA["

#~ msgid ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key )\n"
#~ "create table Address ( addressId bigint not null primary key, personId "
#~ "bigint not null )\n"
#~ "        ]]>"
#~ msgstr ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key )\n"
#~ "create table Address ( addressId bigint not null primary key, personId "
#~ "bigint not null )\n"
#~ "        ]]>"

#~ msgid ""
#~ "<![CDATA["
#~ msgstr ""
#~ "<![CDATA["

#~ msgid ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key )\n"
#~ "create table PersonAddress ( personId not null, addressId bigint not null "
#~ "primary key )\n"
#~ "create table Address ( addressId bigint not null primary key )\n"
#~ "        ]]>"
#~ msgstr ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key )\n"
#~ "create table PersonAddress ( personId not null, addressId bigint not null "
#~ "primary key )\n"
#~ "create table Address ( addressId bigint not null primary key )\n"
#~ "        ]]>"

#~ msgid ""
#~ "<![CDATA["
#~ msgstr ""
#~ "<![CDATA["

#~ msgid ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key )\n"
#~ "create table PersonAddress ( personId bigint not null primary key, "
#~ "addressId bigint not null )\n"
#~ "create table Address ( addressId bigint not null primary key )\n"
#~ "        ]]>"
#~ msgstr ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key )\n"
#~ "create table PersonAddress ( personId bigint not null primary key, "
#~ "addressId bigint not null )\n"
#~ "create table Address ( addressId bigint not null primary key )\n"
#~ "        ]]>"

#~ msgid ""
#~ "<![CDATA["
#~ msgstr ""
#~ "<![CDATA["

#~ msgid ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key )\n"
#~ "create table PersonAddress ( personId bigint not null primary key, "
#~ "addressId bigint not null unique )\n"
#~ "create table Address ( addressId bigint not null primary key )\n"
#~ "        ]]>"
#~ msgstr ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key )\n"
#~ "create table PersonAddress ( personId bigint not null primary key, "
#~ "addressId bigint not null unique )\n"
#~ "create table Address ( addressId bigint not null primary key )\n"
#~ "        ]]>"

#~ msgid ""
#~ "<![CDATA["
#~ msgstr ""
#~ "<![CDATA["

#~ msgid ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key )\n"
#~ "create table PersonAddress ( personId bigint not null, addressId bigint "
#~ "not null, primary key (personId, addressId) )\n"
#~ "create table Address ( addressId bigint not null primary key )\n"
#~ "        ]]>"
#~ msgstr ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key )\n"
#~ "create table PersonAddress ( personId bigint not null, addressId bigint "
#~ "not null, primary key (personId, addressId) )\n"
#~ "create table Address ( addressId bigint not null primary key )\n"
#~ "        ]]>"

#~ msgid ""
#~ "<![CDATA["
#~ msgstr ""
#~ "<![CDATA["

#~ msgid ""
#~ "<![CDATA["
#~ msgstr ""
#~ "<![CDATA["

#~ msgid ""
#~ "<![CDATA["
#~ msgstr ""
#~ "<![CDATA["

#~ msgid ""
#~ "<![CDATA[\n"
#~ "        </generator>\n"
#~ "    </id>\n"
#~ "    <one-to-one name=\"person\" \n"
#~ "        constrained=\"true\"/>\n"
#~ "</class>]]>"
#~ msgstr ""
#~ "<![CDATA[\n"
#~ "        </generator>\n"
#~ "    </id>\n"
#~ "    <one-to-one name=\"person\" \n"
#~ "        constrained=\"true\"/>\n"
#~ "</class>]]>"

#~ msgid ""
#~ "<![CDATA["
#~ msgstr ""
#~ "<![CDATA["

#~ msgid ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key )\n"
#~ "create table PersonAddress ( personId bigint not null, addressId bigint "
#~ "not null primary key )\n"
#~ "create table Address ( addressId bigint not null primary key )\n"
#~ "        ]]>"
#~ msgstr ""
#~ "<![CDATA[\n"
#~ "create table Person ( personId bigint not null primary key )\n"
#~ "create table PersonAddress ( personId bigint not null, addressId bigint "
#~ "not null primary key )\n"
#~ "create table Address ( addressId bigint not null primary key )\n"
#~ "        ]]>"

#~ msgid ""
#~ "<![CDATA["
#~ msgstr ""
#~ "<![CDATA["

#~ msgid ""
#~ "<![CDATA["
#~ msgstr ""
#~ "<![CDATA["

#~ msgid ""
#~ "<![CDATA["
#~ msgstr ""
#~ "<![CDATA["

#~ msgid ""
#~ "<![CDATA[\n"
#~ "</many-to-one>]]>"
#~ msgstr ""
#~ "<![CDATA[\n"
#~ "</many-to-one>]]>"

#~ msgid ""
#~ "<![CDATA["
#~ msgstr ""
#~ "<![CDATA["

Other Hibernate examples (source code examples)

Here is a short list of links related to this Hibernate association_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.