1 /*
2 * $Id: ISelectionCardinalityCapability.java,v 1.18 2011/06/16 09:29:40 jbmeslin Exp $
3 */
4 package org.rcfaces.core.component.capability;
5
6 /**
7 * An int value specifying the type of multiple selection authorized:
8 * <ul>
9 * <li> 1:optional|?: none or one selection </li>
10 * <li> 2:zeromany|*: any number of selections or none </li>
11 * <li> 3:one|1: one and only one selection </li>
12 * <li> 4:onemany|+: one or more selection </li>
13 * </ul>
14 *
15 * cf. ICardinality for constant values
16 *
17 * @author Olivier Oeuillot (latest modification by $Author: jbmeslin $)
18 * @version $Revision: 1.18 $ $Date: 2011/06/16 09:29:40 $
19 */
20 public interface ISelectionCardinalityCapability extends ICardinality {
21
22 /**
23 * Default cardinality for selection feature.
24 */
25 int DEFAULT_CARDINALITY = ICardinality.OPTIONAL_CARDINALITY;
26
27 /**
28 * Returns an int value specifying the type of multiple selection
29 * authorized. cf. ICardinality for constant values
30 *
31 * @return 1: none or one selection|2: any number of selections or none|3:
32 * one and only one selection|4: one or more selection
33 */
34 int getSelectionCardinality();
35
36 /**
37 * Sets an int value specifying the type of multiple selection authorized.
38 * cf. ICardinality for constant values
39 *
40 * @param selectionCardinality
41 * 1: none or one selection|2: any number of selections or
42 * none|3: one and only one selection|4: one or more selection
43 */
44 void setSelectionCardinality(int selectionCardinality);
45 }