Class TagHome
- java.lang.Object
-
- fr.paris.lutece.plugins.blog.business.TagHome
-
public final class TagHome extends java.lang.ObjectThis class provides instances management methods (create, find, ...) for Tag objects
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidcreate(int nIdTag, int nIdocument, int nPriority)Associating a tag with a documentstatic Tagcreate(Tag tag)Create an instance of the tag classstatic TagfindByName(java.lang.String strName)Returns an instance of a tag whose name is specified in parameterstatic TagfindByPrimaryKey(int nKey)Returns an instance of a tag whose identifier is specified in parameterstatic java.util.List<Tag>getTagList()Load the data of all the tag objects and returns them as a liststatic java.util.List<Tag>getTagListByDoc(int idDoc)Load the Tags associated with the document whose identifier is specified in parameterstatic fr.paris.lutece.util.ReferenceListgetTagsReferenceList()Load the data of all the tag objects and returns them as a liststatic java.util.List<Tag>loadByDoc(int nIdDco)Load the data of the tag objects whose identifier is specified in parameter and returns them as a liststatic voidremove(int nKey)Remove the tag whose identifier is specified in parameterstatic voidremoveTagDoc(int nIdDoc)Delete Association a tag with a document whose identifier is specified in parameterstatic Tagupdate(Tag tag)Update of the tag which is specified in parameter
-
-
-
Method Detail
-
create
public static Tag create(Tag tag)
Create an instance of the tag class- Parameters:
tag- The instance of the tag which contains the informations to store- Returns:
- The instance of tag which has been created with its primary key.
-
update
public static Tag update(Tag tag)
Update of the tag which is specified in parameter- Parameters:
tag- The instance of the tag which contains the data to store- Returns:
- The instance of the tag which has been updated
-
remove
public static void remove(int nKey)
Remove the tag whose identifier is specified in parameter- Parameters:
nKey- The tag Id
-
findByPrimaryKey
public static Tag findByPrimaryKey(int nKey)
Returns an instance of a tag whose identifier is specified in parameter- Parameters:
nKey- The tag primary key- Returns:
- an instance of Tag
-
findByName
public static Tag findByName(java.lang.String strName)
Returns an instance of a tag whose name is specified in parameter- Parameters:
strName- The tag name- Returns:
- an instance of Tag
-
getTagList
public static java.util.List<Tag> getTagList()
Load the data of all the tag objects and returns them as a list- Returns:
- the list which contains the data of all the tag objects
-
getTagsReferenceList
public static fr.paris.lutece.util.ReferenceList getTagsReferenceList()
Load the data of all the tag objects and returns them as a list- Returns:
- the list which contains the data of all the tag objects
-
loadByDoc
public static java.util.List<Tag> loadByDoc(int nIdDco)
Load the data of the tag objects whose identifier is specified in parameter and returns them as a list- Parameters:
nIdDco- The document identifiant- Returns:
- returns them as a list of the tag objects
-
create
public static void create(int nIdTag, int nIdocument, int nPriority)Associating a tag with a document- Parameters:
nIdTag- the Tag idnIdocument- The document identifiantnPriority- The priority of the document
-
removeTagDoc
public static void removeTagDoc(int nIdDoc)
Delete Association a tag with a document whose identifier is specified in parameter- Parameters:
nIdDoc- The Id Document
-
getTagListByDoc
public static java.util.List<Tag> getTagListByDoc(int idDoc)
Load the Tags associated with the document whose identifier is specified in parameter- Parameters:
idDoc- Id Document- Returns:
- list of Tag
-
-