Class SiteDAO
java.lang.Object
fr.paris.lutece.plugins.releaser.business.SiteDAO
- All Implemented Interfaces:
ISiteDAO
This class provides Data Access methods for Site objects
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddelete(int nKey, fr.paris.lutece.portal.service.plugin.Plugin plugin) Delete a record from the tablevoidInsert a new record in the table.load(int nKey, fr.paris.lutece.portal.service.plugin.Plugin plugin) Load the data from the tableintnewPrimaryKey(fr.paris.lutece.portal.service.plugin.Plugin plugin) Generates a new primary keysearchDuplicateSite(String siteName, String artifactId, String scmUrl, fr.paris.lutece.portal.service.plugin.Plugin plugin) Find if site is already existselectByCluster(int nClusterId, fr.paris.lutece.portal.service.plugin.Plugin plugin) Find all sites for a given clusterselectIdSitesList(fr.paris.lutece.portal.service.plugin.Plugin plugin) Load the id of all the site objects and returns them as a listselectSitesList(fr.paris.lutece.portal.service.plugin.Plugin plugin) Load the data of all the site objects and returns them as a listfr.paris.lutece.util.ReferenceListselectSitesReferenceList(fr.paris.lutece.portal.service.plugin.Plugin plugin) Load the data of all the site objects and returns them as a referenceListvoidUpdate the record in the table
-
Constructor Details
-
SiteDAO
public SiteDAO()
-
-
Method Details
-
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
Insert a new record in the table. -
load
Load the data from the table -
delete
public void delete(int nKey, fr.paris.lutece.portal.service.plugin.Plugin plugin) Delete a record from the table -
store
Update the record in the table -
selectSitesList
Load the data of all the site objects and returns them as a list- Specified by:
selectSitesListin interfaceISiteDAO- Parameters:
plugin- the Plugin- Returns:
- The list which contains the data of all the site objects
-
selectIdSitesList
Load the id of all the site objects and returns them as a list- Specified by:
selectIdSitesListin interfaceISiteDAO- Parameters:
plugin- the Plugin- Returns:
- The list which contains the id of all the site objects
-
selectSitesReferenceList
public fr.paris.lutece.util.ReferenceList selectSitesReferenceList(fr.paris.lutece.portal.service.plugin.Plugin plugin) Load the data of all the site objects and returns them as a referenceList- Specified by:
selectSitesReferenceListin interfaceISiteDAO- Parameters:
plugin- the Plugin- Returns:
- The referenceList which contains the data of all the site objects
-
selectByCluster
public List<Site> selectByCluster(int nClusterId, fr.paris.lutece.portal.service.plugin.Plugin plugin) Find all sites for a given cluster- Specified by:
selectByClusterin interfaceISiteDAO- Parameters:
nClusterId- The cluster IDplugin- The plugin- Returns:
- the list which contains the data of all the site objects
-
searchDuplicateSite
public String searchDuplicateSite(String siteName, String artifactId, String scmUrl, fr.paris.lutece.portal.service.plugin.Plugin plugin) Find if site is already exist- Specified by:
searchDuplicateSitein interfaceISiteDAO- Parameters:
siteName- The site NameartifactId- The artifactId of the siteplugin- The plugin- Returns:
- the cluster name which contains the existing site
-