Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
Copyright (c) 2011 Michael Ruflin, Andr´┐Ż Locher, Claudia von Bastian. This file is part of Tatool. Tatool is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Tatool is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with Tatool. If not, see <>. /
package ch.tatool.core.executable;
This executable displays a set of images as instructions. The images need to be provided as complete (classpath) paths for each image.

Andre Locher
	private Logger logger = LoggerFactory.getLogger(ImageListInstructionExecutable.class);

Holds the paths to the images to display as instructions.
	private List<Stringimages;

Default constructor.

This method is called before the element is executed. We use it to initialize the panels
    public void initialize(Element element) {
    	// load the images

Loads the images provided as classpath paths.

See also:
getImages, setImages
	private void loadImages() {
		List<JPanelpanels = new ArrayList<JPanel>();
		for (String path : ) {
			// fetch the image url
				.debug("Searching resource " + path);
			URL imageURL = getClass().getResource(path);
			if (imageURL == null) {
				.warn("Resource file not found: " + path);
			// Create a panel displaying the image
			ImageIcon icon = new ImageIcon(imageURL);
		// set the loaded panels to the ListInstructionsExecutable
	public List<StringgetImages() {
		return ;
	public void setImages(List<Stringimages) {
		this. = images;
New to GrepCode? Check out our FAQ X