1 16 package org.apache.cocoon.components.slide.impl; 17 18 import java.io.File ; 19 import java.util.Hashtable ; 20 21 import org.apache.slide.common.Domain; 22 import org.apache.slide.common.ServiceParameterErrorException; 23 import org.apache.slide.common.ServiceParameterMissingException; 24 import org.apache.slide.store.txfile.TxFileContentStore; 25 26 32 public class ContextTxFileContentStore extends TxFileContentStore { 33 34 public ContextTxFileContentStore() { 35 } 36 37 public void setParameters(Hashtable parameters) 38 throws ServiceParameterErrorException, ServiceParameterMissingException { 39 40 String rootpath = (String ) parameters.get(STORE_DIR_PARAMETER); 42 rootpath = new File (Domain.getParameter("contextpath"),rootpath).toString(); 43 parameters.put(STORE_DIR_PARAMETER,rootpath); 44 45 String workpath = (String ) parameters.get(WORK_DIR_PARAMETER); 47 workpath = new File (Domain.getParameter("workdir"),workpath).toString(); 48 parameters.put(WORK_DIR_PARAMETER,workpath); 49 50 super.setParameters(parameters); 51 } 52 53 } 54 | Popular Tags |