Task #2142
Task #690: Reorganize TXM source code to better match the RCP development plug-ins system.
Task #2141: Reorganize R stats engine into plug-in projects
R stats engine, default preferences
| Statut: | Closed | Début: | 10/04/2017 | |
|---|---|---|---|---|
| Priorité: | Normal | Echéance: | ||
| Assigné à: | - | % réalisé: | 100% |
|
| Catégorie: | Development | Temps passé: | - | |
| Version cible: | TXM 0.8.0a (split/restructuration) |
Description
Done.
Location: /org.txm.r/src/org/txm/r/core/preferences/RPreferences.java
To avoid the cyclic plug-ins dependencies a new class has been created containing the TBX R related code: /org.txm.r/src/org/txm/r/core/RStatsEngine.java
Names:
public static final String PREFERENCES_PREFIX = "r_"; //$NON-NLS-1$
/** The Constant R_REMOTE. */
public static final String IS_MANDATORY = PREFERENCES_PREFIX + "is_mandatory"; //$NON-NLS-1$
/** The Constant R_PATH_TO_EXECUTABLE. */
public static final String PATH_TO_EXECUTABLE = PREFERENCES_PREFIX + "path_to_executable"; //$NON-NLS-1$
/** The Constant R_REMOTE. */
public static final String REMOTE = PREFERENCES_PREFIX + "remote"; //$NON-NLS-1$
public static final String DEBUG = PREFERENCES_PREFIX + "debug"; //$NON-NLS-1$
/** The Constant R_SERVER_ADDRESS. */
public static final String SERVER_ADDRESS = PREFERENCES_PREFIX + "server_adress"; //$NON-NLS-1$
/** The Constant R_PORT. */
public static final String PORT = PREFERENCES_PREFIX + "port"; //$NON-NLS-1$
/** The Constant R_USER. */
public static final String USER = PREFERENCES_PREFIX + "user"; //$NON-NLS-1$
/** The Constant R_PASSWORD. */
public static final String PASSWORD = PREFERENCES_PREFIX + "password"; //$NON-NLS-1$
/** The Constant R_PACKAGES_PATH. */
public static final String PACKAGES_PATH = PREFERENCES_PREFIX + "packages_path"; //$NON-NLS-1$
public static final String RARGS = PREFERENCES_PREFIX + "rargs"; //$NON-NLS-1$
public static final String RSERVEARGS = PREFERENCES_PREFIX + "rserveargs"; //$NON-NLS-1$
/** The Constant R_DISABLE. */
public static final String DISABLE = PREFERENCES_PREFIX + "disable"; //$NON-NLS-1$
/** The Constant R_FILE_TRANSFERT. */
public static final String FILE_TRANSFERT = PREFERENCES_PREFIX + "file_transfert"; //$NON-NLS-1$
public static final String SVG_DEVICE = PREFERENCES_PREFIX + "svg_device"; //$NON-NLS-1$
Values:
preferences.putBoolean(IS_MANDATORY, false);
preferences.put(PATH_TO_EXECUTABLE, "");
preferences.put(SERVER_ADDRESS, "127.0.0.1");
preferences.putBoolean(REMOTE, false);
preferences.putBoolean(DISABLE, false);
preferences.putBoolean(DEBUG, false);
preferences.put(PORT, "6311");
preferences.put(USER, "");
preferences.put(PASSWORD, "");
preferences.put(RARGS, "");
preferences.put(RSERVEARGS, "");
preferences.putBoolean(FILE_TRANSFERT, false);
preferences.put(SVG_DEVICE, "svg");
Historique
#1 Mis à jour par Sebastien Jacquot il y a plus de 8 ans
- Description mis à jour (diff)
#2 Mis à jour par Sebastien Jacquot il y a plus de 8 ans
- Description mis à jour (diff)
#3 Mis à jour par Sebastien Jacquot il y a plus de 8 ans
Default PATH_TO_EXECUTABLE should be set/edit here to target R since we now embed it?
Need to adjust this after the SVN branches syncho.
#4 Mis à jour par Sebastien Jacquot il y a plus de 8 ans
- Statut changé de New à In Progress
- % réalisé changé de 0 à 50
#5 Mis à jour par Sebastien Jacquot il y a plus de 7 ans
New location: org.txm.statsengine.r.core
+ see the fixme above:
@Override
public void initializeDefaultPreferences() {
Preferences preferences = DefaultScope.INSTANCE.getNode(PREFERENCES_NODE);
//FIXME: need to define here the PATH_TO_EXECUTABLE preference according to current OS and the current TXM install directory
// If the paths are different according to the current OS, a good way could be to have the same projects as for CQP
// Project: org.txm.r
// Fragment: org.txm.r.win64
// Fragment: org.txm.r.linux
// and the fragment should initialize this preference
preferences.put(PATH_TO_EXECUTABLE, "undefined");
preferences.putBoolean(IS_MANDATORY, false);
preferences.put(SERVER_ADDRESS, "127.0.0.1");
preferences.putBoolean(REMOTE, false);
preferences.putBoolean(DISABLE, false);
preferences.putBoolean(DEBUG, false);
preferences.put(PORT, "6311");
preferences.put(USER, "");
preferences.put(PASSWORD, "");
preferences.put(RARGS, "");
preferences.put(RSERVEARGS, "");
preferences.putBoolean(FILE_TRANSFERT, false);
preferences.put(SVG_DEVICE, "svg");
}
#6 Mis à jour par Sebastien Jacquot il y a environ 7 ans
- Statut changé de In Progress à Closed
- % réalisé changé de 50 à 100
Done by MD