1 package jp.sourceforge.stigmata;
7 import java.util.Iterator;
10 * This interface represents a birthmark.
11 * The birthmark is native characteristics of a program.
13 * @author Haruaki TAMADA
15 public interface Birthmark extends Iterable<BirthmarkElement>{
17 * return all elements of this birthmark.
19 * @return all elements.
21 public BirthmarkElement[] getElements();
24 * returns the iterator for all elements of this birthmark.
25 * @return iterator for accessing to elements of this birthmark.
28 public Iterator<BirthmarkElement> iterator();
31 * returns the number of elements of this birthmark.
33 * @return element count
35 public int getElementCount();
38 * add element to this birthmark.
40 * @param element new element
42 public void addElement(BirthmarkElement element);
45 * return the type of this birthmark.
47 * @return birthmark type
49 public String getType();
52 * This method check types of this birthmark and given birthmark are matched.
54 * @param birthmark check target.
55 * @return true: same type, false: not same type.
57 public boolean isSameType(Birthmark birthmark);