01: package org.objectweb.salome_tmf.api.sql;
02:
03: import java.rmi.Remote;
04:
05: import org.objectweb.salome_tmf.api.data.DataSetWrapper;
06: import org.objectweb.salome_tmf.api.data.ValuedParameterWrapper;
07:
08: public interface ISQLDataset extends Remote {
09: /**
10: * Insert a dataset (table JEU_DONNEES) for the campaign identified by idCamp
11: * @param idCamp : id of the campaign wich will caontain the dataset
12: * @param name of the dataset
13: * @param description of the dataset
14: * @return id of the dataset created in table JEU_DONNEES
15: * need permission canExecutCamp or canCreateCamp
16: * @throws Exception
17: */
18: public int insert(int idCamp, String name, String description)
19: throws Exception;
20:
21: /**
22: * Map a value for the parameter idParam in the table VALEUR_PARAM
23: * @param idDataset : id of the dataset in the table JEU_DONNEES
24: * @param idParam : id of the parameter in the table PARAM_TEST
25: * @param value
26: * @throws Exception
27: * need permission canExecutCamp
28: */
29: public void addParamValue(int idDataset, int idParam, String value)
30: throws Exception;
31:
32: /**
33: * Update the name and the description of the dataset idDataset
34: * @param idDataset : id of the dataset in table JEU_DONNEES
35: * @param name
36: * @param description
37: * need permission canExecutCamp
38: * @throws Exception
39: */
40: public void update(int idDataset, String name, String description)
41: throws Exception;
42:
43: /**
44: * Update a value maped to the parameter idParam for the dataset idDataset
45: * @param idDataset : id of the dataset in table JEU_DONNEES
46: * @param idParam
47: * @param value
48: * @param description
49: * @throws Exception
50: * need permission canExecutCamp or canUpdateCamp
51: */
52: public void updateParamValue(int idDataset, int idParam,
53: String value, String description) throws Exception;
54:
55: /**
56: * Delete the dataset and all mapped values in the database
57: * if the dataset is used by executions, the executions are deleted
58: * @param idDataset : id of the dataset in table JEU_DONNEES
59: * @throws Exception
60: * @see ISQLExecution.delete(int)
61: * need permission canExecutCamp
62: */
63: public void delete(int idDataset) throws Exception;
64:
65: /**
66: * Get the Id of the dataset identified by name for the campaign idCamp
67: * @param idCamp
68: * @param name
69: * @return id of the dataset created in table JEU_DONNEES
70: * @throws Exception
71: */
72: public int getID(int idCamp, String name) throws Exception;
73:
74: /**
75: * Get A DataSetWrapper representing the dataset idDataSet in database
76: * @param idDataSet
77: * @return
78: * @throws Exception
79: */
80: public DataSetWrapper getWrapper(int idDataSet) throws Exception;
81:
82: /**
83: * Get an Array of ValuedParameterWrapper for the he dataset idDataSet
84: * @param idEnv
85: * @return
86: * @throws Exception
87: */
88: public ValuedParameterWrapper[] getDefinedParameters(int idDataSet)
89: throws Exception;
90: }
|