package SCHUNK.EndOfArm.impl;

import com.ur.urcap.api.contribution.InstallationNodeContribution;
import com.ur.urcap.api.contribution.InstallationNodeService;
import com.ur.urcap.api.domain.URCapAPI;
import com.ur.urcap.api.domain.URCapAPIFacade;

import java.io.InputStream;

import com.ur.urcap.api.domain.data.DataModel;
import com.ur.urcap.api.domain.system.localization.Localization;

import eoa_Language.LanguagePack;


public class GrpInstallationNodeService implements InstallationNodeService {

	public GrpInstallationNodeService() { }

	@Override
	public InstallationNodeContribution createInstallationNode(URCapAPI api, DataModel model) {
		return new GrpInstallationNodeContribution(api,model);
	}

	@Override
	public String getTitle() {
		final Localization localization = URCapAPIFacade.getURCapAPI().getSystemSettings().getLocalization();
		LanguagePack.getInstance().setLocalization(localization);
		return LanguagePack.getInstance().getTextResource().getTitle();
	}

	@Override
	public InputStream getHTML() {
		InputStream is = this.getClass().getResourceAsStream("/Schunk/Gripper/impl/installation.html");
		return is;
	}
}
