Package org.nuxeo.ecm.directory.sql
Class TableReference
- java.lang.Object
- 
- org.nuxeo.ecm.directory.AbstractReference
- 
- org.nuxeo.ecm.directory.sql.TableReference
 
 
- 
- All Implemented Interfaces:
- Reference
 
 public class TableReference extends AbstractReference 
- 
- 
Field SummaryFields Modifier and Type Field Description protected StringdataFileNameprotected StringsourceColumnprotected StringtableNameprotected StringtargetColumn- 
Fields inherited from class org.nuxeo.ecm.directory.AbstractReferencefieldName, sourceDirectory, sourceDirectoryName, targetDirectory, targetDirectoryName
 
- 
 - 
Constructor SummaryConstructors Constructor Description TableReference(String fieldName, String directory, String tableName, String sourceColumn, String targetColumn, String dataFileName)TableReference(ReferenceDescriptor descriptor)TableReference(TableReferenceDescriptor descriptor)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddLink(String sourceId, String targetId, SQLSession session, boolean checkExisting)voidaddLinks(String sourceId, List<String> targetIds)voidaddLinks(String sourceId, List<String> targetIds, Session session)Adds the links between the source id and the target idsvoidaddLinks(List<String> sourceIds, String targetId)voidaddLinks(List<String> sourceIds, String targetId, Session session)Adds the links between the source ids and the target idbooleanexists(String sourceId, String targetId, SQLSession session)StringgetDataFileName()protected List<String>getIdsFor(String valueColumn, String filterColumn, String filterValue)StringgetSourceColumn()List<String>getSourceIdsForTarget(String targetId)protected SQLSessiongetSQLSession()StringgetTableName()StringgetTargetColumn()StringgetTargetDirectoryName()List<String>getTargetIdsForSource(String sourceId)protected voidinitialize(Connection connection)voidremoveLinksFor(String column, String entryId, SQLSession session)voidremoveLinksForSource(String sourceId)voidremoveLinksForSource(String sourceId, Session session)Removes all the links for a given source idvoidremoveLinksForTarget(String targetId)voidremoveLinksForTarget(String targetId, Session session)Removes all the links for a given target idvoidsetIdsFor(String idsColumn, List<String> ids, String filterColumn, String filterValue, SQLSession session)voidsetSourceIdsForTarget(String targetId, List<String> sourceIds)voidsetSourceIdsForTarget(String targetId, List<String> sourceIds, Session session)Sets all source ids to be associated to the given target idvoidsetSourceIdsForTarget(String targetId, List<String> sourceIds, SQLSession session)voidsetTargetIdsForSource(String sourceId, List<String> targetIds)voidsetTargetIdsForSource(String sourceId, List<String> targetIds, Session session)Sets all target ids to be associated to the given source idvoidsetTargetIdsForSource(String sourceId, List<String> targetIds, SQLSession session)- 
Methods inherited from class org.nuxeo.ecm.directory.AbstractReferencegetFieldName, getSourceDirectory, getTargetDirectory, setSourceDirectoryName, setTargetDirectoryName
 
- 
 
- 
- 
- 
Constructor Detail- 
TableReferencepublic TableReference(String fieldName, String directory, String tableName, String sourceColumn, String targetColumn, String dataFileName) - Since:
- 9.2
 
 - 
TableReferencepublic TableReference(TableReferenceDescriptor descriptor) - Since:
- 9.2
 
 - 
TableReferencepublic TableReference(ReferenceDescriptor descriptor) - Since:
- 9.2
 
 
- 
 - 
Method Detail- 
initializeprotected void initialize(Connection connection) 
 - 
addLinkspublic void addLinks(String sourceId, List<String> targetIds, Session session) Description copied from interface:ReferenceAdds the links between the source id and the target ids- Parameters:
- sourceId- the source id
- targetIds- the target ids
- session- the session
 
 - 
addLinkspublic void addLinks(List<String> sourceIds, String targetId, Session session) Description copied from interface:ReferenceAdds the links between the source ids and the target id- Parameters:
- sourceIds- the source ids
- targetId- the target id
- session- the session
 
 - 
existspublic boolean exists(String sourceId, String targetId, SQLSession session) 
 - 
addLinkpublic void addLink(String sourceId, String targetId, SQLSession session, boolean checkExisting) 
 - 
getIdsForprotected List<String> getIdsFor(String valueColumn, String filterColumn, String filterValue) 
 - 
removeLinksForpublic void removeLinksFor(String column, String entryId, SQLSession session) 
 - 
removeLinksForSourcepublic void removeLinksForSource(String sourceId, Session session) Description copied from interface:ReferenceRemoves all the links for a given source id- Parameters:
- sourceId- the source id
- session- the session
 
 - 
removeLinksForTargetpublic void removeLinksForTarget(String targetId, Session session) Description copied from interface:ReferenceRemoves all the links for a given target id- Parameters:
- targetId- the target id
- session- the session
 
 - 
removeLinksForSourcepublic void removeLinksForSource(String sourceId) 
 - 
removeLinksForTargetpublic void removeLinksForTarget(String targetId) 
 - 
setIdsForpublic void setIdsFor(String idsColumn, List<String> ids, String filterColumn, String filterValue, SQLSession session) 
 - 
setSourceIdsForTargetpublic void setSourceIdsForTarget(String targetId, List<String> sourceIds, SQLSession session) 
 - 
setTargetIdsForSourcepublic void setTargetIdsForSource(String sourceId, List<String> targetIds, SQLSession session) 
 - 
setSourceIdsForTargetpublic void setSourceIdsForTarget(String targetId, List<String> sourceIds, Session session) Description copied from interface:ReferenceSets all source ids to be associated to the given target id- Parameters:
- targetId- the target id
- sourceIds- the source ids
- session- the session
 
 - 
setTargetIdsForSourcepublic void setTargetIdsForSource(String sourceId, List<String> targetIds, Session session) Description copied from interface:ReferenceSets all target ids to be associated to the given source id- Parameters:
- sourceId- the source id
- targetIds- the target ids
- session- the session
 
 - 
getSQLSessionprotected SQLSession getSQLSession() 
 - 
getSourceColumnpublic String getSourceColumn() 
 - 
getTargetColumnpublic String getTargetColumn() 
 - 
getTargetDirectoryNamepublic String getTargetDirectoryName() 
 - 
getTableNamepublic String getTableName() 
 - 
getDataFileNamepublic String getDataFileName() 
 
- 
 
-