fr.paris.lutece.plugins.pluginwizard.business.model
Class PluginModelHome

java.lang.Object
  extended by fr.paris.lutece.plugins.pluginwizard.business.model.PluginModelHome

public final class PluginModelHome
extends Object

This class provides instances management methods (create, find, ...) for PluginModel objects


Method Summary
static PluginModel create(PluginModel pluginModel, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Create an instance of the pluginModel class
static int getPluginModelId(fr.paris.lutece.portal.service.plugin.Plugin plugin, String strName)
          Returns the identifier of the plugin model
static Collection<PluginModel> getPluginModelsList(fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Load the data of all the pluginModel objects and returns them in form of a collection
static boolean pluginExists(String strPluginName, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          A boolean to indicate if plugin exists
static void remove(int nPluginModelId, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Remove the pluginModel whose identifier is specified in parameter
static PluginModel update(PluginModel pluginModel, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Update of the pluginModel which is specified in parameter
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

create

public static PluginModel create(PluginModel pluginModel,
                                 fr.paris.lutece.portal.service.plugin.Plugin plugin)
Create an instance of the pluginModel class

Parameters:
pluginModel - The instance of the PluginModel which contains the informations to store
plugin - the Plugin
Returns:
The instance of pluginModel which has been created with its primary key.

update

public static PluginModel update(PluginModel pluginModel,
                                 fr.paris.lutece.portal.service.plugin.Plugin plugin)
Update of the pluginModel which is specified in parameter

Parameters:
pluginModel - The instance of the PluginModel which contains the data to store
plugin - the Plugin
Returns:
The instance of the pluginModel which has been updated

remove

public static void remove(int nPluginModelId,
                          fr.paris.lutece.portal.service.plugin.Plugin plugin)
Remove the pluginModel whose identifier is specified in parameter

Parameters:
nPluginModelId - The pluginModel Id
plugin - the Plugin

getPluginModelsList

public static Collection<PluginModel> getPluginModelsList(fr.paris.lutece.portal.service.plugin.Plugin plugin)
Load the data of all the pluginModel objects and returns them in form of a collection

Parameters:
plugin - the Plugin
Returns:
the collection which contains the data of all the pluginModel objects

getPluginModelId

public static int getPluginModelId(fr.paris.lutece.portal.service.plugin.Plugin plugin,
                                   String strName)
Returns the identifier of the plugin model

Parameters:
plugin - The plugin
strName - The name of the generated plugin
Returns:
The identifier of the plugin model

pluginExists

public static boolean pluginExists(String strPluginName,
                                   fr.paris.lutece.portal.service.plugin.Plugin plugin)
A boolean to indicate if plugin exists

Parameters:
strPluginName - The plugin name
plugin - The plugin
Returns:
A boolean value indicating if plugin exists


Copyright © 2013 Mairie de Paris. All Rights Reserved.