class SpotifySpeech {

	@Intent()
	public String getDevices(Map<String, EntityData> entites) {
		List<DeviceEntity> devices = this.deviceLogic.getDevices();
		StringBuilder builder = new StringBuilder();
		for (int i = 0; i < devices.size(); i++) {
			builder = builder.append(String.valueOf(i)).append(". ").append(devices.get(i).getName().concat("\n"));
		}
		if (builder.length() > 0) {
			builder.insert(0, "Following Devices are online: \n");
		} else {
			builder.append("No devices are online");
		}
		return builder.toString();
	}

}