java.lang.Object
fr.paris.lutece.plugins.wiki.modules.ai.business.AiFeatureDAO
All Implemented Interfaces:
IAiFeatureDAO

@ApplicationScoped public class AiFeatureDAO extends Object implements IAiFeatureDAO
AiFeatureDAO implementation for database operations
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    delete(int nId, fr.paris.lutece.portal.service.plugin.Plugin plugin)
    Deletes an AI feature by identifier
    void
    insert(AiFeature aiFeature, fr.paris.lutece.portal.service.plugin.Plugin plugin)
    Inserts a new AI feature into the database
    load(int nId, fr.paris.lutece.portal.service.plugin.Plugin plugin)
    Loads an AI feature by identifier
    selectActiveFeatures(fr.paris.lutece.portal.service.plugin.Plugin plugin)
    Retrieves all active AI features
    selectAll(fr.paris.lutece.portal.service.plugin.Plugin plugin)
    Retrieves all AI features
    selectFeaturesByType(String strType, fr.paris.lutece.portal.service.plugin.Plugin plugin)
    Retrieves active AI features by type
    void
    shiftOrdersDown(int nOrder, int nExcludeId, fr.paris.lutece.portal.service.plugin.Plugin plugin)
    Shifts order numbers down after removing a feature from specified position
    void
    shiftOrdersUp(int nOrder, int nExcludeId, fr.paris.lutece.portal.service.plugin.Plugin plugin)
    Shifts order numbers up to make room for insertion at specified position
    void
    store(AiFeature aiFeature, fr.paris.lutece.portal.service.plugin.Plugin plugin)
    Updates an existing AI feature

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • AiFeatureDAO

      public AiFeatureDAO()
  • Method Details

    • insert

      public void insert(AiFeature aiFeature, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Inserts a new AI feature into the database
      Specified by:
      insert in interface IAiFeatureDAO
      Parameters:
      aiFeature - the AI feature to insert
      plugin - the plugin
    • load

      public Optional<AiFeature> load(int nId, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Loads an AI feature by identifier
      Specified by:
      load in interface IAiFeatureDAO
      Parameters:
      nId - the feature identifier
      plugin - the plugin
      Returns:
      an Optional containing the AI feature if found, empty otherwise
    • store

      public void store(AiFeature aiFeature, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Updates an existing AI feature
      Specified by:
      store in interface IAiFeatureDAO
      Parameters:
      aiFeature - the AI feature to update
      plugin - the plugin
    • delete

      public void delete(int nId, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Deletes an AI feature by identifier
      Specified by:
      delete in interface IAiFeatureDAO
      Parameters:
      nId - the feature identifier
      plugin - the plugin
    • selectAll

      public List<AiFeature> selectAll(fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Retrieves all AI features
      Specified by:
      selectAll in interface IAiFeatureDAO
      Parameters:
      plugin - the plugin
      Returns:
      a list of all AI features
    • selectActiveFeatures

      public List<AiFeature> selectActiveFeatures(fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Retrieves all active AI features
      Specified by:
      selectActiveFeatures in interface IAiFeatureDAO
      Parameters:
      plugin - the plugin
      Returns:
      a list of active AI features
    • selectFeaturesByType

      public List<AiFeature> selectFeaturesByType(String strType, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Retrieves active AI features by type
      Specified by:
      selectFeaturesByType in interface IAiFeatureDAO
      Parameters:
      strType - the feature type
      plugin - the plugin
      Returns:
      a list of active AI features matching the specified type
    • shiftOrdersUp

      public void shiftOrdersUp(int nOrder, int nExcludeId, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Description copied from interface: IAiFeatureDAO
      Shifts order numbers up to make room for insertion at specified position
      Specified by:
      shiftOrdersUp in interface IAiFeatureDAO
      Parameters:
      nOrder - the order position where the feature will be inserted
      nExcludeId - the feature id to exclude from shifting (-1 for new features)
      plugin - the plugin
    • shiftOrdersDown

      public void shiftOrdersDown(int nOrder, int nExcludeId, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Description copied from interface: IAiFeatureDAO
      Shifts order numbers down after removing a feature from specified position
      Specified by:
      shiftOrdersDown in interface IAiFeatureDAO
      Parameters:
      nOrder - the order position being vacated
      nExcludeId - the feature id to exclude from shifting
      plugin - the plugin