XMLRepositoryManager xmlRepositoryMgr = new XMLRepositoryManager();
xmlRepositoryMgr.executeWith(new XMLRepositoryManager.RepositoryCommand() {
public void execute(RepositoryConnection repositoryConnection,
XMLRepository repository,
String repositoryDir) throws Exception {
LinkComponent lc = new LinkComponent("/testRemoveLinkComponent.mlnk");
LinkRepositoryManager manager =
new LinkRepositoryManager(repositoryConnection);
manager.addLinkComponent(repositoryConnection, lc);
containerExists(lc.getName(), false, repositoryConnection,
repository);
manager.removeLinkComponent(repositoryConnection, lc.getName());
containerExists(lc.getName(), true, repositoryConnection,
repository);
}
});
}