Note: This ORM/SQL annotation is silently ignored by ObjectDB

javax.jdo.annotations.Element - JDO annotation

javax.jdo.annotations
Annotation Element

Target:
Fields (including property get methods)
Annotation for the element of a collection/array relation. Corresponds to the xml element "element".
Since:
JDO 2.1
String column
Name of the column to store the element in.
Name of the column to store the element in.
Returns:
name of the column to store the element in
Default value:
""
Since:
JDO 2.1
The column(s) for the element.
The column(s) for the element.
Returns:
the column(s) for the element
Default value:
{}
Since:
JDO 2.1
Delete action to apply to any foreign key for the element.
Delete action to apply to any foreign key for the element.
Returns:
delete action to apply to any foreign key for the element
Default value:
javax.jdo.annotations.ForeignKeyAction.UNSPECIFIED
Since:
JDO 2.1
String dependent
Whether the element is dependent on the owner, and will be deleted when the owner is deleted.
Whether the element is dependent on the owner, and will be deleted when the owner is deleted.
Returns:
whether the element is dependent on the owner, and will be deleted when the owner is deleted
Default value:
""
Since:
JDO 2.1
String embedded
Whether this element is embedded.
Whether this element is embedded.
Returns:
whether this element is embedded
Default value:
""
Since:
JDO 2.1
The embedded mapping for the element.
The embedded mapping for the element.
Returns:
the embedded mapping for the element
Default value:
{}
Since:
JDO 2.1
Vendor extensions.
Vendor extensions.
Returns:
the vendor extensions
Default value:
{}
Since:
JDO 2.1
String foreignKey
Name for a generated foreign key constraint.
Name for a generated foreign key constraint.
Returns:
the name of the generated foreign key constraint
Default value:
""
Since:
JDO 2.1
Generate or assume a foreign key constraint exists on the column or columns associated with this join.
Generate or assume a foreign key constraint exists on the column or columns associated with this join. Specify "true" or "false".
Returns:
whether to generate or assume a primary key constraint
Default value:
""
Since:
JDO 2.1
String index
The name of the index to generate.
The name of the index to generate.
Returns:
the name of the index
Default value:
""
Since:
JDO 2.1
String indexed
Whether the value column(s) should be indexed.
Whether the value column(s) should be indexed.
Returns:
whether the value column(s) should be indexed.
Default value:
""
Since:
JDO 2.1
String mappedBy
Name of the member in the target class that forms a bidirectional relationship with this member.
Name of the member in the target class that forms a bidirectional relationship with this member.
Returns:
name of the member in the target class that forms a bidirectional relationship with this member
Default value:
""
Since:
JDO 2.1
String serialized
Whether the element is to be stored serialized (into a join table)
Whether the element is to be stored serialized (into a join table)
Returns:
whether the element is to be stored serialized (into a join table)
Default value:
""
Since:
JDO 2.1
String table
Name of the table for the element.
Name of the table for the element.
Returns:
name of the table for the element
Default value:
""
Since:
JDO 2.1
Class[] types
Types of the elements.
Types of the elements. This can be determined if using JDK1.5 generics but is required otherwise. Multiple types can be specified if the implementation supports multiple types.
Returns:
the types of elements
Default value:
{}
Since:
JDO 2.1
String unique
Whether a unique constraint should be generated or assumed.
Whether a unique constraint should be generated or assumed.
Returns:
whether a unique constraint should be generated or assumed
Default value:
""
Since:
JDO 2.1
String uniqueKey
The name of the unique key constraint to generate.
The name of the unique key constraint to generate.
Returns:
the name of the unique key constraint
Default value:
""
Since:
JDO 2.1
Update action to apply to any foreign key for the element
Update action to apply to any foreign key for the element
Returns:
update action to apply to any foreign key for the element
Default value:
javax.jdo.annotations.ForeignKeyAction.UNSPECIFIED
Since:
JDO 2.1

This documentation page is derived (with some adjustments) from the JDO 2.2 API
and is available under the terms of the Apache License, v. 2.0.