de.greenrobot.daogenerator
Class ToOne

java.lang.Object
  extended by de.greenrobot.daogenerator.ToOne

public class ToOne
extends java.lang.Object

    

To-one relationship from a source entity to one (or zero) target entity.


Constructor Summary
ToOne(Schema schema, Entity sourceEntity, Entity targetEntity, Property[] fkProperties, boolean useFkProperty)
           
 
Method Summary
protected  boolean checkUseEquals(PropertyType propertyType)
           
 Property[] getFkProperties()
           
 java.lang.String getName()
           
 java.lang.String[] getResolvedKeyJavaType()
           
 boolean[] getResolvedKeyUseEquals()
           
 Entity getSourceEntity()
           
 Entity getTargetEntity()
           
 boolean isUseFkProperty()
           
 void setName(java.lang.String name)
          Sets the name of the relation, which is used as the property name in the entity (the source entity owning the to-many relationship).
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ToOne

public ToOne(Schema schema,
             Entity sourceEntity,
             Entity targetEntity,
             Property[] fkProperties,
             boolean useFkProperty)
Method Detail

getSourceEntity

public Entity getSourceEntity()

getTargetEntity

public Entity getTargetEntity()

getFkProperties

public Property[] getFkProperties()

getResolvedKeyJavaType

public java.lang.String[] getResolvedKeyJavaType()

getResolvedKeyUseEquals

public boolean[] getResolvedKeyUseEquals()

getName

public java.lang.String getName()

setName

public void setName(java.lang.String name)
Sets the name of the relation, which is used as the property name in the entity (the source entity owning the to-many relationship).


isUseFkProperty

public boolean isUseFkProperty()

checkUseEquals

protected boolean checkUseEquals(PropertyType propertyType)

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2011-2012 greenrobot.de. All Rights Reserved.