// Indexer
ArrayList qParams = new ArrayList();
// qParams.add(new SimpleParameterEntry("indexDir", "target" + File.separator+ "temp" +
// File.separator +"index" + name));
qParams.add(new SimpleParameterEntry(QueryHandlerParams.PARAM_INDEX_DIR, "target/temp/index/" + name
+ System.currentTimeMillis()));
QueryHandlerEntry qEntry =
new QueryHandlerEntry("org.exoplatform.services.jcr.impl.core.query.lucene.SearchIndex", qParams);
ws1back.setQueryHandler(qEntry); // EXOMAN
ArrayList params = new ArrayList();
for (Iterator i = ws1e.getContainer().getParameters().iterator(); i.hasNext();)
{
SimpleParameterEntry p = (SimpleParameterEntry) i.next();
SimpleParameterEntry newp = new SimpleParameterEntry(p.getName(), p.getValue());
if (newp.getName().equals("source-name"))
newp.setValue(sourceName);
else if (newp.getName().equals("swap-directory"))
newp.setValue("target/temp/swap/" + name + System.currentTimeMillis());
params.add(newp);
}
ContainerEntry ce =
new ContainerEntry("org.exoplatform.services.jcr.impl.storage.jdbc.JDBCWorkspaceDataContainer", params);
ArrayList<ValueStorageEntry> list = new ArrayList<ValueStorageEntry>();
// value storage
ArrayList<ValueStorageFilterEntry> vsparams = new ArrayList<ValueStorageFilterEntry>();
ValueStorageFilterEntry filterEntry = new ValueStorageFilterEntry();
filterEntry.setPropertyType("Binary");
vsparams.add(filterEntry);
ValueStorageEntry valueStorageEntry =
new ValueStorageEntry("org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage", vsparams);
ArrayList<SimpleParameterEntry> spe = new ArrayList<SimpleParameterEntry>();
spe.add(new SimpleParameterEntry("path", "target/temp/values/" + name + "_" + System.currentTimeMillis()));
valueStorageEntry.setId("draft");
valueStorageEntry.setParameters(spe);
valueStorageEntry.setFilters(vsparams);
// containerEntry.setValueStorages();