Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -65,13 +65,13 @@ public class LimbOption {
private Image image;

public DHParameterKinematics getLimb(CSGDatabaseInstance db,String uniqueName) throws Exception {
String xmlContent = ScriptingEngine.codeFromGit(url, file)[0];
String xmlContent = ScriptingEngine.codeFromGit(getUrl(), getSourceFile())[0];
if (!composite) {
DHParameterKinematics newLimb = new DHParameterKinematics(null, IOUtils.toInputStream(xmlContent, "UTF-8"));
newLimb.setScriptingName(uniqueName);
return newLimb;
} else {
MobileBase base = RobotHelper.fileToRobot(db,url, file);
MobileBase base = RobotHelper.fileToRobot(db,getUrl(), getSourceFile());
DHParameterKinematics newLimb = base.getAllDHChains().get(0);
newLimb.setScriptingName(uniqueName);
return newLimb;
Expand All @@ -96,7 +96,7 @@ public static ArrayList<LimbOption> getOptions()

@Override
public String toString() {
return getType() + " " + getName() + " " + url + "/" + file + "\n\tConsumes:" + getConsumes() + "\n\tProvides:" + getProvides();
return getType() + " " + getName() + " " + getUrl() + "/" + getSourceFile() + "\n\tConsumes:" + getConsumes() + "\n\tProvides:" + getProvides();
}

public ControllerFeatures getConsumes() {
Expand Down Expand Up @@ -191,4 +191,20 @@ public javafx.scene.image.Image getImage() {
public CSG getIndicator() {
return indicator;
}

public String getUrl() {
return url;
}

public void setUrl(String url) {
this.url = url;
}

public String getSourceFile() {
return file;
}

public void setSourceFile(String file) {
this.file = file;
}
}
Loading