pl.edu.agh.cast.data.model.general
Interface IOneToOneRelation
- All Superinterfaces:
- Identifiable, IDisposable, IDomainElement, IElement, IGeneralElement, IManyToManyRelation, IPropertyContainer, IReplicable, IValidatable, Observer, Serializable
- All Known Subinterfaces:
- ITimedOneToOneRelation
- All Known Implementing Classes:
- OneToOneRelation, TimedOneToOneRelation
public interface IOneToOneRelation
- extends IManyToManyRelation
An interface of one-to-one relations which have exactly one source and exactly one target entity. A one-to-one
relation is a special case of many-to-many relation and may be treated as such.
- Author:
- AGH CAST Team
- See Also:
IManyToManyRelation
Field Summary |
static Type |
TYPE
The type of one-to-one relation elements. |
Methods inherited from interface pl.edu.agh.cast.data.model.general.IManyToManyRelation |
addSourceEntitiy, addTargetEntitiy, getSourceEntities, getSourceEntitiy, getTargetEntities, getTargetEntitiy, isDirected, removeSourceEntitiy, removeTargetEntitiy, setDirected, setSourceEntities, setTargetEntities |
TYPE
static final Type TYPE
- The type of one-to-one relation elements.
getSourceEntity
IEntity getSourceEntity()
- Returns the source entity.
- Returns:
- the source entity (non-
null
)
setSourceEntity
void setSourceEntity(IEntity entity)
- Sets the source entity.
- Parameters:
entity
- the source entity
- Throws:
IllegalArgumentException
- if entity is null
getTargetEntity
IEntity getTargetEntity()
- Returns the target entity.
- Returns:
- the target entity (non-
null
)
setTargetEntity
void setTargetEntity(IEntity entity)
- Sets the target entity.
- Parameters:
entity
- the target entity
- Throws:
IllegalArgumentException
- if entity is null
Copyright © 2007-2009 IISG AGH-UST Krakow, Poland. All Rights Reserved.