Interface IProjectHandler


public interface IProjectHandler
This interface provides a set of methods to perform language specific tasks on uno-idl projects.
  • Method Details

    • configureProject

      void configureProject(UnoFactoryData data, org.eclipse.core.runtime.IProgressMonitor monitor) throws Exception
      Adds the language specific things of the UNO project. The project handle has to be contained in the provided data.
      Parameters:
      data - the data describing the project to configure
      monitor - the monitor reporting the progress
      Throws:
      Exception - if anything wrong happens.
    • addProjectNature

      void addProjectNature(org.eclipse.core.resources.IProject pProject)
      Add a language specific language nature. This one has to configure the language-specific properties of the project and set the builders.
      Parameters:
      pProject - the project on which to add the nature. Must not be null, otherwise the nature won't be added
    • addOOoDependencies

      void addOOoDependencies(IOOo ooo, org.eclipse.core.resources.IProject pProject)
      Adds the language specific OpenOffice.org dependencies to the project.
      Parameters:
      ooo - the OpenOffice.org instance
      pProject - the project on which to add the dependencies
    • removeOOoDependencies

      void removeOOoDependencies(IOOo ooo, org.eclipse.core.resources.IProject pProject)
      Removes the language specific OpenOffice.org dependencies from the project.
      Parameters:
      ooo - the OpenOffice.org instance
      pProject - the project from which to remove the dependencies
    • getSkeletonMakerLanguage

      String getSkeletonMakerLanguage(UnoFactoryData data) throws Exception
      Extracts the language option name to give to the uno-skeletonmaker: --java5 for Java 1.5 for example. To know the correct language name, please refer to the uno-skeletonmaker help.
      Parameters:
      data - the UNO factory data from where to extract the value
      Returns:
      the option or null if the uno-skeletonmaker utility doesn't support the language.
      Throws:
      Exception - is thrown if anything wrong happens
    • getImplementationName

      String getImplementationName(IUnoidlProject pPrj, String pService) throws Exception
      Extracts the Implementation name of the class that will be generated by the uno-skeletonmaker. It should never return a null value.
      Parameters:
      pPrj - the project to work on
      pService - the service for which to get the implementation
      Returns:
      the implementation name
      Throws:
      Exception - if anything wrong happens.
    • getImplementationFile

      org.eclipse.core.runtime.IPath getImplementationFile(String implementationName)
      Computes the implementation file path from the implementation name.
      Parameters:
      implementationName - the implementation name returned by the project handler.
      Returns:
      a source directory relative path pointing to the file that will be generated by uno-skeletonmaker.
    • getLibraryPath

      String getLibraryPath(IUnoidlProject pPrj)
      Parameters:
      pPrj - the UNO project from which to get the library path
      Returns:
      the library path, ready to be provided to the File class constructor.
    • getBinFolders

      org.eclipse.core.resources.IFolder[] getBinFolders(IUnoidlProject pUnoidlProject)
      Parameters:
      pUnoidlProject - the UNO project from which to get the binary folders
      Returns:
      the binary folders