2.17.2: 2011-06-17

net.sf.basedb.core.data
Class AnnotationSetData

java.lang.Object
  extended by net.sf.basedb.core.data.BasicData
      extended by net.sf.basedb.core.data.AnnotationSetData
All Implemented Interfaces:
IdentifiableData, LoggableData

public class AnnotationSetData
extends BasicData
implements LoggableData

This class holds information about a set of annotations.

Version:
2.0
Author:
Nicklas
See Also:
AnnotationSet, Annotations overview
Hibernate: class
table="`AnnotationSets`" lazy="true" batch-size="10"

Field Summary
private  Map<AnnotationTypeData,AnnotationData> annotations
           
private  Set<AnnotationData> inherited
           
private  Set<AnnotationSetData> inheritedSets
           
private  Set<AnnotationSetData> inheritingSets
           
private  Integer itemId
           
private  int itemType
           
 
Constructor Summary
AnnotationSetData()
           
 
Method Summary
 Map<AnnotationTypeData,AnnotationData> getAnnotations()
          The primary annotations in this annotation set.
 Set<AnnotationData> getInherited()
          Annotations that are inherited from other annotation sets.
 Set<AnnotationSetData> getInheritedSets()
          Annotation sets from which this set should inherit all annotations.
(package private)  Set<AnnotationSetData> getInheritingSets()
          Annotation sets inherting annotations from this set.
 Integer getItemId()
          The ID if the item this annotation set is associated with.
 int getItemType()
          Get the item type this annotation set is associated with.
(package private)  void setAnnotations(Map<AnnotationTypeData,AnnotationData> annotations)
           
(package private)  void setInherited(Set<AnnotationData> inherited)
           
(package private)  void setInheritedSets(Set<AnnotationSetData> inheritedSets)
           
(package private)  void setInheritingSets(Set<AnnotationSetData> inheritingSets)
           
 void setItemId(Integer itemId)
           
 void setItemType(int itemType)
           
 
Methods inherited from class net.sf.basedb.core.data.BasicData
equals, getId, getVersion, hashCode, setId, setVersion, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

itemType

private int itemType

itemId

private Integer itemId

annotations

private Map<AnnotationTypeData,AnnotationData> annotations

inherited

private Set<AnnotationData> inherited

inheritedSets

private Set<AnnotationSetData> inheritedSets

inheritingSets

private Set<AnnotationSetData> inheritingSets
Constructor Detail

AnnotationSetData

public AnnotationSetData()
Method Detail

getItemType

public int getItemType()
Get the item type this annotation set is associated with.

Hibernate: property
column="`item_type`" type="int" not-null="true" update="false"

setItemType

public void setItemType(int itemType)

getItemId

public Integer getItemId()
The ID if the item this annotation set is associated with. Can be null if this is not know. Use a query based on the itemType and annotation set ID to find the item in this case.

Since:
2.14
Hibernate: property
column="`item_id`" type="int" not-null="false"

setItemId

public void setItemId(Integer itemId)

getAnnotations

public Map<AnnotationTypeData,AnnotationData> getAnnotations()
The primary annotations in this annotation set. This is the inverse end.

See Also:
AnnotationData.getAnnotationSet(), AnnotationData.getAnnotationType()
Hibernate: map
lazy="true" cascade="delete" inverse="true"
Hibernate: index-many-to-many
column="`annotationtype_id`" class="net.sf.basedb.core.data.AnnotationTypeData"
Hibernate: collection-key
column="`annotationset_id`"
Hibernate: collection-one-to-many
class="net.sf.basedb.core.data.AnnotationData"

setAnnotations

void setAnnotations(Map<AnnotationTypeData,AnnotationData> annotations)

getInherited

public Set<AnnotationData> getInherited()
Annotations that are inherited from other annotation sets.

See Also:
getInheritingSets()
Hibernate: set
table="`InheritedAnnotations`" lazy="true"
Hibernate: collection-key
column="`annotationset_id`"
Hibernate: collection-many-to-many
column="`annotation_id`" class="net.sf.basedb.core.data.AnnotationData"

setInherited

void setInherited(Set<AnnotationData> inherited)

getInheritedSets

public Set<AnnotationSetData> getInheritedSets()
Annotation sets from which this set should inherit all annotations.

See Also:
getInheritingSets()
Hibernate: set
table="`InheritedAnnotationSets`" lazy="true"
Hibernate: collection-key
column="`annotationset_id`"
Hibernate: collection-many-to-many
column="`inherited_id`" class="net.sf.basedb.core.data.AnnotationSetData"

setInheritedSets

void setInheritedSets(Set<AnnotationSetData> inheritedSets)

getInheritingSets

Set<AnnotationSetData> getInheritingSets()
Annotation sets inherting annotations from this set. This is the inverse end.

See Also:
getInheritedSets()
Hibernate: set
table="`InheritedAnnotationSets`" lazy="true"
Hibernate: collection-key
column="`inherited_id`"
Hibernate: collection-many-to-many
column="`annotationset_id`" class="net.sf.basedb.core.data.AnnotationSetData"

setInheritingSets

void setInheritingSets(Set<AnnotationSetData> inheritingSets)

2.17.2: 2011-06-17