public void setAsText(String text) throws IllegalArgumentException { try { String prefix = "DeployableUnitID[url="; if (text.startsWith(prefix) && text.charAt(text.length()-1) == ']') { this.setValue(new DeployableUnitID(text.substring(prefix.length(),text.length()-1))); return; } throw new IllegalArgumentException("Must be DeployableUnitID[url=X] where X is the du original URL"); } catch (Throwable ex) { throw new IllegalArgumentException("Must be DeployableUnitID[url=X] where X is the du original URL",ex); } }
@Override public boolean equals(Object obj) { if (obj != null && obj.getClass() == this.getClass()) { return ((DeployableUnitImpl) obj).id.equals(this.id); } else { return false; } }
@Override public int hashCode() { return id.hashCode(); }
public void put(DeployableUnitID value) { map.put(value.toString(), value); }
} else { for (DeployableUnitID deployedDU : deployedDUs) { sb.append("\n").append(deployedDU.getURL());
static public String toString(DeployableUnitID deployableUnitID) { if (deployableUnitID == null) return null; managementConsole.getDeployableUnitIDMap().put(deployableUnitID); return deployableUnitID.toString(); }
@Override public void invoke() throws Exception { getDeploymentMBean().uninstall(new DeployableUnitID(getDuURL())); }
.getReferringComponents(sleeComponent)) { if (!referringComponent.getDeployableUnit() .getDeployableUnitID().equals( deployableUnitID)) { throw new DependencyException("Component "
public DeployableUnitID getDeployableUnit(String deploymentUrl) throws NullPointerException, UnrecognizedDeployableUnitException, ManagementException { DeployableUnitID deployableUnitID = new DeployableUnitID(deploymentUrl); boolean duExists = true; try { if (getSleeContainer().getDeployableUnitManagement() .getDeployableUnit(deployableUnitID) == null) { duExists = false; } } catch (Throwable e) { throw new ManagementException(e.getMessage(), e); } if (duExists) { return deployableUnitID; } else { throw new UnrecognizedDeployableUnitException(deploymentUrl); } }
DeployableUnitID deployableUnitID = new DeployableUnitID(url);
DeployableUnitID deployableUnitID = new DeployableUnitID(url);