Package de.innovationgate.eclipse.utils.ui.model

Examples of de.innovationgate.eclipse.utils.ui.model.WGADesignConfigurationModelWrapper


          }
        }
                     
        // modify plugin config and open plugin design editor
        IFile syncInfo = new WGADesignStructureHelper(designProject.getDesignFolder()).getSyncInfo();
        WGADesignConfigurationModel model = new WGADesignConfigurationModelWrapper(syncInfo);
       

                model.setVersionCompliance(Activator.DEFAULT_VERSION_COMPLIANCE);
              
        model.createPluginConfig();
        model.setPluginUniqueName(_page.getPluginUniqueName());
        model.saveChanges();
       
        try {
          // select syncinfo in navigation views
          WorkbenchUtils.setNavigationViewSelection(new SingleStructuredSelection(syncInfo));
        } catch (Exception e) {         
View Full Code Here


                }  
                IFolder[] pluginFolders = currentRuntime.getPluginsAsFolder(true);  
                for(IFolder currentFolder : pluginFolders){                 
                    WGADesignStructureHelper helper = new WGADesignStructureHelper(currentFolder);
                    if(helper.isWGADesignResourceOfCurrentDesign(tmlfile)){             
                        WGADesignConfigurationModelWrapper wrapper = new WGADesignConfigurationModelWrapper(helper.getSyncInfo());         
                        return "plugin-"+wrapper.getDesignKey();
                    }
                }  
               
               
               
View Full Code Here

   */ 
  public static boolean isDesignPluginFolder(IContainer container) {
    if (isDesignFolder(container)){
      WGADesignStructureHelper helper = new WGADesignStructureHelper(container);
      try {
        WGADesignConfigurationModelWrapper model = new WGADesignConfigurationModelWrapper(helper.getSyncInfo());
        return model.hasPluginConfig();
      } catch (IOException e) {
        Activator.getDefault().logError("Cannot parse WGADesignConfigurationModel of file " + container.getLocation(), e);
        return false;       
      }     
    }else
View Full Code Here

    return false;
  }

  public WGADesignConfigurationModel createModel() throws IOException {
    return new WGADesignConfigurationModelWrapper(_syncInfo);
  }
View Full Code Here

    IFile wgaConfFile = WGADesignStructureHelper.determineSyncInfo(resource);   
    VersionCompliance wgaVersionCompliance = null;
    if (wgaConfFile != null) {
      WGADesignConfigurationModel currentWGAConf;
      try {
        currentWGAConf = new WGADesignConfigurationModelWrapper(wgaConfFile);
        wgaVersionCompliance = currentWGAConf.getVersionCompliance();
      } catch (IOException e) {
      }
    }
    if (wgaVersionCompliance == null && fallbackToDefault) {
View Full Code Here

  public boolean hasPluginConfig() {
    IFile syncInfo = getSyncInfo();
    if (syncInfo.exists()) {     
      try {
        WGADesignConfigurationModelWrapper wrapper = new WGADesignConfigurationModelWrapper(syncInfo);
        return wrapper.hasPluginConfig();
      } catch (IOException e) {
      }     
    }
    return false;
  }
View Full Code Here

   
   
    if(_mediaKeyFolder != null && !_mediaKeyFolder.getName().equals("")){ 
      _syncInfo = WGADesignStructureHelper.determineSyncInfo(_mediaKeyFolder)
      try {
        WGADesignConfigurationModelWrapper designConfig = new WGADesignConfigurationModelWrapper(_syncInfo);
        return "Open designeditor to register mediakey '"+_mediaKeyFolder.getName()+"' in design '"+designConfig.getDesignKey()+"'.";
      } catch (IOException e) {
        Plugin.getDefault().logError("Can not find syncinfo for resource " + _mediaKeyFolder, e);
      }
      return null;     
    } else {
View Full Code Here

                      MessageDialog.openWarning(getSite().getShell(), "Incompatible design version", "This design uses an incompatible compliance level. Please upgrade to the latest WDS version to work on this design with full feature support.");       
                  }
              }             
          }
       
      _model =new WGADesignConfigurationModelWrapper(syncInfoFile);
      _model.addListener(this);
      _persistedVersionComliance = _model.getVersionCompliance();
      _persistedDesignEncoding = _model.getDesignEncoding();
      setPartName("Design (" + syncInfoFile.getParent().getName() + ")");
      try {
View Full Code Here

    if (_compliance.toWGAVersion().isAtLeast(5, 0)){
      IContainer container = (IContainer) resource;
      if(!container.getName().startsWith(".")){
        if (WGADesignStructureHelper.isMediaKeyContainer(container)) {
          IFile syncInfo = WGADesignStructureHelper.determineSyncInfo(container);       
          WGADesignConfigurationModelWrapper conf;
          try {
            conf = new WGADesignConfigurationModelWrapper(syncInfo);
            List<String> mediaKeyStrings = new ArrayList<String>();
            mediaKeyStrings.addAll(WGADesignStructureHelper.DEFAULT_MEDIA_KEYS);
            for (MediaKey current : conf.getMediaKeys()) {
              mediaKeyStrings.add(current.getKey());
            }
            if (!mediaKeyStrings.contains(container.getName())) {
              Map<String, Object> map = new HashMap<String, Object>();
              MarkerUtilities.setMessage(map, "Missing mediakey '" + container.getName() + "' in design configuration.");
View Full Code Here

TOP

Related Classes of de.innovationgate.eclipse.utils.ui.model.WGADesignConfigurationModelWrapper

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.