1 17 18 package org.apache.geronimo.plugin.assembly; 19 20 import java.io.File ; 21 import java.net.URI ; 22 23 import org.apache.geronimo.system.configuration.LocalConfigStore; 24 25 30 public class LocalConfigInstaller { 31 private File root; 32 private File artifact; 33 34 public File getRoot() { 35 return root; 36 } 37 38 public void setRoot(File root) { 39 this.root = root; 40 } 41 42 public File getArtifact() { 43 return artifact; 44 } 45 46 public void setArtifact(File artifact) { 47 this.artifact = artifact; 48 } 49 50 public void execute() throws Exception { 51 LocalConfigStore store = new LocalConfigStore(root); 52 store.doStart(); 53 try { 54 URI uri = store.install(artifact.toURL()); 55 System.out.println("Installed configuration " + uri); 56 } finally{ 57 store.doStop(); 58 } 59 } 60 } 61 | Popular Tags |