blob: bd1bd64a09274b4aada95f47b5739f036248c973 [file] [log] [blame]
/*******************************************************************************
* Copyright (c) 2004-2010, Andras Schmidt, Andras Balogh, Istvan Rath and Daniel Varro
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Istvan Rath - initial API and implementation
*******************************************************************************/
package org.eclipse.viatra2.tags;
import java.util.Set;
import org.eclipse.core.resources.IMarker;
import org.eclipse.viatra2.core.IModelElement;
/**
* An annotation object that can be attached to a set of VPM model elements.
* @author Istvan Rath
*
*/
public class InfoTag implements ITag
{
public InfoTag(String message, Set<IModelElement> associatedElements, int foreground, int background)
{
this.message = message;
this.associatedElements = associatedElements;
this.bColor = background;
this.fColor = foreground;
}
public void setAssociatedElements(Set<IModelElement> associatedElements) {
this.associatedElements = associatedElements;
}
public void setMessage(String message) {
this.message = message;
}
protected Set<IModelElement> associatedElements;
protected String message;
public Set<IModelElement> getAssociatedElements()
{
return associatedElements;
}
public TagKind getKind() {
return TagKind.MODELING_INFO;
}
public String getMessage() {
return message;
}
protected IMarker marker;
public IMarker getMarker() {
return marker;
}
public void setMarker(IMarker marker) {
this.marker = marker;
}
private int bColor;
private int fColor;
public int getForegroundColor() {
return fColor;
}
public int getBackgroundColor() {
return bColor;
}
public void setForegroundColor(int c) {
this.fColor = c;
}
public void setBackgroundColor(int c) {
this.bColor = c;
}
}