1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 package net.sf.magicproject.modifier;
20
21 import java.awt.Graphics;
22
23 import net.sf.magicproject.test.Test;
24
25
26 /***
27 * @author <a href="mailto:fabdouglas@users.sourceforge.net">Fabrice Daugan </a>
28 * @since 0.86
29 */
30 public interface ObjectModifier {
31
32 /***
33 * remove from the manager a occurence of object with the specified name
34 *
35 * @param objectName
36 * the object's name to remove
37 * @param objectTest
38 * The test applied on specific modifier to be removed.
39 * @return the new chain
40 */
41 Modifier removeObject(String objectName, Test objectTest);
42
43 /***
44 * Paint all objects of the given MCard component.
45 *
46 * @param g
47 * the graphics used ot paint this object.
48 * @param startX
49 * the x position where this object can be paint.
50 * @param startY
51 * the y position where this object can be paint.
52 * @return the next free object position.
53 */
54 int paintObject(Graphics g, int startX, int startY);
55
56 /***
57 * Return occurences number of the given object with the given name.
58 *
59 * @param objectName
60 * the object's name to find within this chain.
61 * @param objectTest
62 * The test applied on specific modifier to be removed.
63 * @return occurences number of the given object with the given name.
64 */
65 int getNbObjects(String objectName, Test objectTest);
66
67 }