Class TagDAO
- java.lang.Object
-
- fr.paris.lutece.plugins.blog.business.TagDAO
-
-
Constructor Summary
Constructors Constructor Description TagDAO()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddelete(int idTag, fr.paris.lutece.portal.service.plugin.Plugin plugin)Remove the tag whose identifier is specified in parametervoiddeleteByDoc(int idDoc, fr.paris.lutece.portal.service.plugin.Plugin plugin)Delete Association a tag with a document whose identifier is specified in parametervoiddeleteByTAG(int idTag, int idDoc, fr.paris.lutece.portal.service.plugin.Plugin plugin)Delete Association a tag with a document whose identifier is specified in parametervoidinsert(int nIdTag, int nIdDoc, int nPriority, fr.paris.lutece.portal.service.plugin.Plugin plugin)Associating a tag with a documentvoidinsert(Tag tag, fr.paris.lutece.portal.service.plugin.Plugin plugin)Create an instance of the tag classTagload(int idTag, fr.paris.lutece.portal.service.plugin.Plugin plugin)Returns an instance of a tag whose identifier is specified in parameterjava.util.List<Tag>loadAllTag(fr.paris.lutece.portal.service.plugin.Plugin plugin)Load the data of all the tag objects and returns them as a listjava.util.List<Tag>loadByDoc(int idDoc, fr.paris.lutece.portal.service.plugin.Plugin plugin)Load the data of the tag objects whose identifier is specified in parameter and returns them as a listTagloadByName(java.lang.String strName, fr.paris.lutece.portal.service.plugin.Plugin plugin)Returns an instance of a tag whose name is specified in parameterjava.util.List<Tag>loadListTagByIdDoc(int idDoc, fr.paris.lutece.portal.service.plugin.Plugin plugin)Load the Tags associated with the document whose identifier is specified in parameterintnewPrimaryKey(fr.paris.lutece.portal.service.plugin.Plugin plugin)Generates a new primary keyfr.paris.lutece.util.ReferenceListselectTagsReferenceList(fr.paris.lutece.portal.service.plugin.Plugin plugin)Load the data of all the tag objects and returns them as a listvoidstore(Tag tag, fr.paris.lutece.portal.service.plugin.Plugin plugin)Update of the tag which is specified in parameter
-
-
-
Method Detail
-
newPrimaryKey
public int newPrimaryKey(fr.paris.lutece.portal.service.plugin.Plugin plugin)
Generates a new primary key- Parameters:
plugin- The Plugin- Returns:
- The new primary key
-
insert
public void insert(Tag tag, fr.paris.lutece.portal.service.plugin.Plugin plugin)
Create an instance of the tag class
-
load
public Tag load(int idTag, fr.paris.lutece.portal.service.plugin.Plugin plugin)
Returns an instance of a tag whose identifier is specified in parameter
-
loadAllTag
public java.util.List<Tag> loadAllTag(fr.paris.lutece.portal.service.plugin.Plugin plugin)
Load the data of all the tag objects and returns them as a list- Specified by:
loadAllTagin interfaceITagDAO- Parameters:
plugin- the plugin- Returns:
- the list which contains the data of all the tag objects
-
delete
public void delete(int idTag, fr.paris.lutece.portal.service.plugin.Plugin plugin)Remove the tag whose identifier is specified in parameter
-
store
public void store(Tag tag, fr.paris.lutece.portal.service.plugin.Plugin plugin)
Update of the tag which is specified in parameter
-
insert
public void insert(int nIdTag, int nIdDoc, int nPriority, fr.paris.lutece.portal.service.plugin.Plugin plugin)Associating a tag with a document
-
deleteByTAG
public void deleteByTAG(int idTag, int idDoc, fr.paris.lutece.portal.service.plugin.Plugin plugin)Delete Association a tag with a document whose identifier is specified in parameter- Specified by:
deleteByTAGin interfaceITagDAO- Parameters:
idTag- Id TagidDoc- Id Documentplugin- the plugin
-
deleteByDoc
public void deleteByDoc(int idDoc, fr.paris.lutece.portal.service.plugin.Plugin plugin)Delete Association a tag with a document whose identifier is specified in parameter- Specified by:
deleteByDocin interfaceITagDAO- Parameters:
idDoc- The Id Documentplugin- the plugin
-
loadByDoc
public java.util.List<Tag> loadByDoc(int idDoc, fr.paris.lutece.portal.service.plugin.Plugin plugin)
Load the data of the tag objects whose identifier is specified in parameter and returns them as a list
-
selectTagsReferenceList
public fr.paris.lutece.util.ReferenceList selectTagsReferenceList(fr.paris.lutece.portal.service.plugin.Plugin plugin)
Load the data of all the tag objects and returns them as a list- Specified by:
selectTagsReferenceListin interfaceITagDAO- Parameters:
plugin- the plugin- Returns:
- the list which contains the data of all the tag objects
-
loadListTagByIdDoc
public java.util.List<Tag> loadListTagByIdDoc(int idDoc, fr.paris.lutece.portal.service.plugin.Plugin plugin)
Load the Tags associated with the document whose identifier is specified in parameter- Specified by:
loadListTagByIdDocin interfaceITagDAO- Parameters:
idDoc- Id Documentplugin- the plugin- Returns:
- list of Tag
-
loadByName
public Tag loadByName(java.lang.String strName, fr.paris.lutece.portal.service.plugin.Plugin plugin)
Returns an instance of a tag whose name is specified in parameter- Specified by:
loadByNamein interfaceITagDAO- Parameters:
strName- The tag nameplugin- the plugin- Returns:
- an instance of Tag
-
-