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

Hibernate example source code file (component_mapping.po)

This example Hibernate source code file (component_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, componentes, declare, el, hibernate, hibernate, la, la, los, tag, tag, the, the, you

The Hibernate component_mapping.po source code

# translation of component_mapping.po to
# Michael H. Smith <mhideo@redhat.com>, 2007.
# Angela Garcia <agarcia@redhat.com>, 2009, 2010.
# translation of Collection_Mapping.po to
# translation of Collection_Mapping.po to
# translation of Collection_Mapping.po to
# translation of Collection_Mapping.po to
# translation of Collection_Mapping.po to
# translation of Collection_Mapping.po to
# translation of Collection_Mapping.po to
# translation of Collection_Mapping.po to
# translation of Collection_Mapping.po to
msgid ""
msgstr ""
"Project-Id-Version: component_mapping\n"
"Report-Msgid-Bugs-To: http://bugs.kde.org\n"
"POT-Creation-Date: 2010-02-11T05:38:15\n"
"PO-Revision-Date: 2010-03-15 12:54+1000\n"
"Last-Translator: Angela Garcia <agarcia@redhat.com>\n"
"Language-Team:  <en@li.org>\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 "Component Mapping"
msgstr "Mapeo de componentes"

#. Tag: para
#, no-c-format
msgid ""
"The notion of a <emphasis>component is re-used in several "
"different contexts and purposes throughout Hibernate."
msgstr ""
"La noción de un <emphasis>componente se reutiliza en muchos "
"contextos diferentes, para propósitos diferentes a través de Hibernate."

#. Tag: title
#, no-c-format
msgid "Dependent objects"
msgstr "Objetos dependientes"

#. Tag: para
#, no-c-format
msgid ""
"A component is a contained object that is persisted as a value type and not "
"an entity reference. The term \"component\" refers to the object-oriented "
"notion of composition and not to architecture-level components. For example, "
"you can model a person like this:"
msgstr ""
"Un componente es un objeto contenido que es persistido como un tipo de "
"valor, no una referencia de entidad. El término \"componente\" hace "
"referencia a la noción orientada a objetos de composición y no a componentes "
"a nivel de arquitectura. Por ejemplo, puede modelar una persona así:"

#. Tag: para
#, no-c-format
msgid ""
"Now <literal>Name can be persisted as a component of "
"<literal>Person. Name defines getter and setter "
"methods for its persistent properties, but it does not need to declare any "
"interfaces or identifier properties."
msgstr ""
"Ahora <literal>Name puede ser persistido como un componente de "
"<literal>Person. Name define métodos getter y "
"setter para sus propiedades persistentes, pero no necesita declarar ninguna "
"interfaz ni propiedades identificadoras."

#. Tag: para
#, no-c-format
msgid "Our Hibernate mapping would look like this:"
msgstr "Nuestro mapeo de Hibernate se vería así: "

#. Tag: para
#, no-c-format
msgid ""
"The person table would have the columns <literal>pid, "
"<literal>birthday, initial, firstlast."
msgstr ""
"La tabla person tendría las columnas <literal>pid, "
"<literal>birthday, initial, firstlast."

#. Tag: para
#, no-c-format
msgid ""
"Like value types, components do not support shared references. In other "
"words, two persons could have the same name, but the two person objects "
"would contain two independent name objects that were only \"the same\" by "
"value. The null value semantics of a component are <emphasis>ad hoc. Cuando se recargue el objeto contenedor, "
"Hibernate asumirá que si todas las columnas del componente son nulas, el "
"componente entero es nulo. Esto es apropiado para la mayoría de propósitos."

#. Tag: para
#, no-c-format
msgid ""
"The properties of a component can be of any Hibernate type (collections, "
"many-to-one associations, other components, etc). Nested components should "
"<emphasis>not be considered an exotic usage. Hibernate is "
"intended to support a fine-grained object model."
msgstr ""
"Las propiedades de un componente pueden ser de cualquier tipo de Hibernate "
"(colecciones, asociaciones muchos-a-uno, otros componentes, etc). Los "
"componentes anidados <emphasis>no deben ser considerados como un "
"uso exótico. Hibernate está concebido para soportar un modelo de objetos muy "
"detallado."

#. Tag: para
#, no-c-format
msgid ""
"The <literal><component> element allows a <"
"parent></literal> subelement that maps a property of the component class "
"as a reference back to the containing entity."
msgstr ""
"El elemento <literal><component> permite un subelemento "
"<literal><parent> que mapea una propiedad de la clase del "
"componente como una referencia a la entidad contenedora."

#. Tag: title
#, no-c-format
msgid "Collections of dependent objects"
msgstr "Colecciones de objetos dependientes"

#. Tag: para
#, no-c-format
msgid ""
"Collections of components are supported (e.g. an array of type "
"<literal>Name). Declare your component collection by replacing the "
"<literal><element> tag with a <composite-"
"element></literal> tag:"
msgstr ""
"Las colecciones de componentes se encuentran soportadas (por ejemplo, un "
"array de tipo <literal>Name). Declare su colección de componentes "
"remplazando la etiqueta <literal><element> por una etiqueta "
"<literal><composite-element>:"

#. Tag: para
#, no-c-format
msgid ""
"If you define a <literal>Set of composite elements, it is "
"important to implement <literal>equals() and hashCode() de elementos compuestos, es muy "
"importante implementar <literal>equals() y hashCode(). Este es un caso de una "
"colección de componentes que a su vez tienen componentes. Se debe estar "
"preguntando si una asociación uno-a-muchos es más apropiada. Remodele el "
"elemento compuesto como una entidad - pero observe que aunque el modelo Java "
"es el mismo, el modelo relacional y la semántica de persistencia siguen "
"siendo ligeramente diferentes."

#. Tag: para
#, no-c-format
msgid ""
"A composite element mapping does not support null-able properties if you are "
"using a <literal><set>. There is no separate primary key "
"column in the composite element table. Hibernate uses each column's value to "
"identify a record when deleting objects, which is not possible with null "
"values. You have to either use only not-null properties in a composite-"
"element or choose a <literal><list>, <map><bag> or <idbag>."
msgstr ""
"Un mapeo de elemento compuesto no soporta propiedades nulables si está "
"utilizando un <literal><set>. No hay una columna clave "
"principal separada en la tabla del elemento compuesto. Hibernate utiliza el "
"valor de cada columna para identificar un registro al borrar objetos, lo "
"cual es imposible con valores nulos. Tiene que usar sólo propiedades no "
"nulas en un elemento compuesto o elegir un <literal><list>, "
"<literal><map>, <bag> o "
"<literal><idbag>."

#. Tag: para
#, no-c-format
msgid ""
"A special case of a composite element is a composite element with a nested "
"<literal><many-to-one> element. This mapping allows you to "
"map extra columns of a many-to-many association table to the composite "
"element class. The following is a many-to-many association from "
"<literal>Order to Item, where "
"<literal>purchaseDate, price and "
"<literal>quantity are properties of the association:"
msgstr ""
"Un caso especial de un elemento compuesto es un elemento compuesto con un "
"elemento anidado <literal><many-to-one>. Este mapeo le "
"permite mapear columnas extra de una tabla de asociación muchos-a-muchos a "
"la clase del elemento compuesto. La siguiente es una asociación muchos-a-"
"muchos de <literal>Order a Item, donde "
"<literal>purchaseDate, price y "
"<literal>quantity son propiedades de la asociación:"

#. Tag: para
#, no-c-format
msgid ""
"There cannot be a reference to the purchase on the other side for "
"bidirectional association navigation. Components are value types and do not "
"allow shared references. A single <literal>Purchase can be in the "
"set of an <literal>Order, but it cannot be referenced by the "
"<literal>Item at the same time."
msgstr ""
"No puede haber una referencia a la compra del otro lado para la navegación "
"bidireccional de la asociación. Los componentes son tipos de valor y no "
"permiten referencias compartidas. Una sola <literal>Purchase puede "
"estar en el conjunto de una <literal>Order, pero no puede ser "
"referenciada por el <literal>Item al mismo tiempo."

#. Tag: para
#, no-c-format
msgid "Even ternary (or quaternary, etc) associations are possible:"
msgstr "Incluso son posibles las asociaciones ternarias (o cuaternarias, etc):"

#. Tag: para
#, no-c-format
msgid ""
"Composite elements can appear in queries using the same syntax as "
"associations to other entities."
msgstr ""
"Los elementos compuestos pueden aparecer en consultas usando la misma "
"sintáxis que las asociaciones a otras entidades. "

#. Tag: title
#, no-c-format
msgid "Components as Map indices"
msgstr "Componentes como índices de Mapeo"

#. Tag: para
#, no-c-format
msgid ""
"The <literal><composite-map-key> element allows you to map a "
"component class as the key of a <literal>Map. Ensure that you "
"override <literal>hashCode() and equals() "
"correctly on the component class."
msgstr ""
"El elemento <literal><composite-map-key> le permite mapear "
"una clase componente como la clave de un <literal>Map. Asegúrese "
"de sobrescribir <literal>hashCode() y equals() "
"correctamente en la clase componente. "

#. Tag: title
#, no-c-format
msgid "Components as composite identifiers"
msgstr "Componentes como identificadores compuestos"

#. Tag: para
#, no-c-format
msgid ""
"You can use a component as an identifier of an entity class. Your component "
"class must satisfy certain requirements:"
msgstr ""
"Puede utilizar un componente como un identidicador de una clase entidad. Su "
"clase componente tiene que satisfacer ciertos requerimientos: "

#. Tag: para
#, no-c-format
msgid "It must implement <literal>java.io.Serializable."
msgstr "Tiene que implementar <literal>java.io.Serializable."

#. Tag: para
#, no-c-format
msgid ""
"It must re-implement <literal>equals() and hashCode() y hashCode() to generate "
"composite keys. Instead the application must assign its own identifiers."
msgstr ""
"No puede utilizar un <literal>IdentifierGenerator para generar "
"claves compuestas. En cambio, la aplicación debe asignar sus propios "
"identificadores. "

#. Tag: para
#, no-c-format
msgid ""
"Use the <literal><composite-id> tag, with nested "
"<literal><key-property> elements, in place of the usual "
"<literal><id> declaration. For example, the "
"<literal>OrderLine class has a primary key that depends upon the "
"(composite) primary key of <literal>Order."
msgstr ""
"Use la etiqueta <literal><composite-id>, con elementos "
"anidados <literal><key-property>, en lugar de la declaración "
"usual <literal><id>. Por ejemplo, la clase "
"<literal>OrderLine tiene una clave principal que depende de la "
"clave principal (compuesta) de <literal>Order."

#. Tag: para
#, no-c-format
msgid ""
"Any foreign keys referencing the <literal>OrderLine table are now "
"composite. Declare this in your mappings for other classes. An association "
"to <literal>OrderLine is mapped like this:"
msgstr ""
"Cualquier clave foránea que referencie la tabla de <literal>OrderLine se mapea así:"

#. Tag: para
#, no-c-format
msgid ""
"The <literal>column element is an alternative to the "
"<literal>column attribute everywhere. Using the column"
msgstr ""
"El elemento <literal>column es una alternativa al atributo column en cualquier lugar. El uso del elemento columnhbm2ddl."

#. Tag: para
#, no-c-format
msgid ""
"A <literal>many-to-many association to OrderLine a OrderLines in Order "
"would use:"
msgstr ""
"La colección de <literal>OrderLines en Order "
"utilizaría: "

#. Tag: para
#, no-c-format
msgid "The <literal><one-to-many> element declares no columns."
msgstr "El elemento <literal><one-to-many> declara ninguna columna."

#. Tag: para
#, no-c-format
msgid ""
"If <literal>OrderLine itself owns a collection, it also has a "
"composite foreign key."
msgstr ""
"Si <literal>OrderLine posee una colección por sí misma, tiene "
"también una clave foránea compuesta."

#. Tag: title
#, no-c-format
msgid "Dynamic components"
msgstr "Componentes dinámicos"

#. Tag: para
#, no-c-format
msgid "You can also map a property of type <literal>Map:"
msgstr "También puede mapear una propiedad del tipo <literal>Map:"

#. Tag: para
#, no-c-format
msgid ""
"The semantics of a <literal><dynamic-component> mapping are "
"identical to <literal><component>. The advantage of this "
"kind of mapping is the ability to determine the actual properties of the "
"bean at deployment time just by editing the mapping document. Runtime "
"manipulation of the mapping document is also possible, using a DOM parser. "
"You can also access, and change, Hibernate's configuration-time metamodel "
"via the <literal>Configuration object."
msgstr ""
"La semántica de un mapeo <literal><dynamic-component> es "
"ídentica a la de <literal><component>. La ventaja de este "
"tipo de mapeos es la habilidad para determinar las propiedades reales del "
"bean en tiempo de despliegue, sólo con editar el documento de mapeo. La "
"manipulación del documento de mapeo en tiempo de ejecución también es "
"posible, usando un analizador DOM. También puede acceder y cambiar el "
"metamodelo de tiempo de configuración de Hibernate por medio del objeto "
"<literal>Configuration."

Other Hibernate examples (source code examples)

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