Package org.eclipse.ui.internal.cheatsheets.data

Examples of org.eclipse.ui.internal.cheatsheets.data.ParserInput


    String contentXml = element.getContentXml();
    URL contentURL = null;
    restorePath = element.getRestorePath();
   
    if (contentXml != null) {
      parserInput = new ParserInput(contentXml, element.getHref());
      return;   
    }

    // The input was not an XML string, find the content URL
    Bundle bundle = null;
    if(element != null && element.getConfigurationElement() != null)
      try{
        String pluginId = element.getConfigurationElement().getContributor().getName();
        bundle = Platform.getBundle(pluginId);
      } catch (Exception e) {
        // do nothing
      }
    if (bundle != null) {
      contentURL = FileLocator.find(bundle, new Path(element.getContentFile()), null);
    }

    if (contentURL == null) {
      try {
        contentURL = new URL(element.getHref());
      } catch (MalformedURLException mue) {
      }
    }
    parserInput = new ParserInput(contentURL, bundle != null ? bundle.getSymbolicName() : null);
  }
View Full Code Here

TOP

Related Classes of org.eclipse.ui.internal.cheatsheets.data.ParserInput

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.