1 23 24 package com.sun.enterprise.deployment.client; 25 26 29 public class DeploymentFacilityFactory { 30 31 private static final String LOCAL_DF = 32 "com.sun.enterprise.deployment.client.local.LocalDeploymentFacilityImpl"; 33 34 public static DeploymentFacility getDeploymentFacility() { 35 return new DeploymentFacilityImpl(); 36 } 37 38 public static DeploymentFacility getLocalDeploymentFacility() { 39 DeploymentFacility df = null; 40 try { 41 df = (DeploymentFacility) Class.forName(LOCAL_DF).newInstance(); 42 } catch (Exception ex) { 43 ex.printStackTrace(); 45 return null; 46 } 47 ServerConnectionIdentifier sid = new ServerConnectionIdentifier(); 48 sid.setHostName("localhost"); 49 df.connect(sid); 50 return df; 51 } 52 } 53 | Popular Tags |