Exemple #1
0
  public CProjectDescription(
      IProject project,
      ICSettingsStorage storage,
      ICStorageElement element,
      boolean loading,
      boolean isCreating)
      throws CoreException {
    fProject = project;
    fStorage = storage;
    fRootStorageElement = element;
    fIsReadOnly = loading;
    fIsLoading = loading;
    fActiveCfgInfo = new CfgIdPair(ACTIVE_CFG_PROPERTY);
    fSettingCfgInfo = new CfgIdPair(SETTING_CFG_PROPERTY);
    fIsCreating = isCreating;
    ICStorageElement el = null;
    CProjectDescriptionManager mngr = CProjectDescriptionManager.getInstance();
    if (loading) {
      Map<String, ICStorageElement> cfgStorMap = mngr.createCfgStorages(this);

      for (ICStorageElement sel : cfgStorMap.values()) {
        CConfigurationDescriptionCache cache = new CConfigurationDescriptionCache(sel, this);
        configurationCreated(cache);
      }

      el = getStorage(CProjectDescriptionManager.MODULE_ID, false);
    }

    fPrefs =
        new CProjectDescriptionPreferences(
            el,
            (CProjectDescriptionPreferences) mngr.getProjectDescriptionWorkspacePreferences(false),
            false);

    fPropertiesMap = Collections.synchronizedMap(new HashMap<QualifiedName, Object>());
  }