aboutsummaryrefslogtreecommitdiffstats
path: root/org.openembedded.bc.ui/src/org/openembedded/bc/ui/wizards/install/Flavor.java
blob: 7462047d185aabc2a0a16b77644b3525c70e1a79 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
/**
 * 
 */
package org.openembedded.bc.ui.wizards.install;

import java.io.IOException;

// # Flavor Label (shows in UI)| description text| image URL| script URL

/**
 * Data class for flavor definition.
 * @author kgilmer
 *
 */
public class Flavor {
	private final String label;
	private final String description;
	private final String imageURL;
	private final String scriptURL;
	
	public Flavor(String line) throws IOException {
		String [] e = line.split("\\|");
		
		if (e.length != 4) {
			throw new IOException("Invalid flavor line: " + line);
		}
		
		label = e[0];
		description = e[1];
		imageURL = e[2];
		scriptURL = e[3];
	}
	
	public String getLabel() {
		return label;
	}

	public String getDescription() {
		return description;
	}

	public String getImageURL() {
		return imageURL;
	}

	public String getScriptURL() {
		return scriptURL;
	}
	
}