private static void deleteNode(final NodePK pk, final Connection connection) throws SQLException {
    NodeNotificationService notificationService = NodeNotificationService.getService();
    notificationService.notifyOnDeletionOf(pk);

    NodeDAO.deleteRow(connection, pk);
    NodeI18NDAO.removeTranslations(connection, Integer.parseInt(pk.getId()));
    IndexEntryPK indexEntry = new IndexEntryPK(pk.getComponentName(), "Node", pk.getId());
    IndexEngineProxy.removeIndexEntry(indexEntry);
  }
 @Override
 public void create(Connection con, String spaceId, String componentId, String userId)
     throws InstanciationException {
   InfoLetterDataInterface dataInterface = ServiceFactory.getInfoLetterData();
   InfoLetter il = dataInterface.createDefaultLetter(componentId);
   FullIndexEntry indexEntry = new FullIndexEntry(componentId, "Lettre", il.getPK().getId());
   indexEntry.setTitle(il.getName());
   IndexEngineProxy.addIndexEntry(indexEntry);
 }
  /**
   * Indexing a group
   *
   * @param group
   */
  public void indexGroup(GroupRow group) {

    FullIndexEntry indexEntry =
        new FullIndexEntry("groups", "GroupRow", Integer.toString(group.id));
    indexEntry.setLastModificationDate(new Date());
    indexEntry.setTitle(group.name);
    indexEntry.setPreView(group.description);

    // index some group informations
    indexEntry.addField("DomainId", Integer.toString(group.domainId));
    indexEntry.addField("SpecificId", group.specificId);
    indexEntry.addField("SuperGroupId", Integer.toString(group.superGroupId));
    indexEntry.addField("SynchroRule", group.rule);

    IndexEngineProxy.addIndexEntry(indexEntry);
  }
  /*
   * (non-Javadoc)
   * @see org.silverpeas.process.AbstractProcess#onSuccessful()
   */
  @Override
  public void onSuccessful() throws Exception {
    super.onSuccessful();

    SilverTrace.info(
        "gallery",
        "GalleryBmEJB.deleteIndex()",
        "root.MSG_GEN_ENTER_METHOD",
        "PhotoPK = " + getPhoto().getPhotoPK().toString());

    final IndexEntryPK indexEntry =
        new IndexEntryPK(
            getPhoto().getPhotoPK().getComponentName(), "Photo", getPhoto().getPhotoPK().getId());

    IndexEngineProxy.removeIndexEntry(indexEntry);
  }
 /**
  * Unindexing a group
  *
  * @param groupId
  */
 public void unindexGroup(String groupId) {
   FullIndexEntry indexEntry = new FullIndexEntry("groups", "GroupRow", groupId);
   IndexEngineProxy.removeIndexEntry(indexEntry.getPK());
 }