Interface ISdk


  • public interface ISdk
    Interface defining a LibreOffice SDK.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      org.eclipse.core.runtime.IPath getBinPath()  
      java.lang.String getHome()
      Returns the SDK home directory.
      org.eclipse.core.runtime.IPath getIncludePath()  
      org.eclipse.core.runtime.IPath getLibPath()  
      java.lang.String getName()
      Returns the SDK version number.
      void initialize​(java.lang.String pHome, java.lang.String name)
      Set the new SDK Home after having checked for the existence of the idl and settings directory.
      java.lang.Process runTool​(IUnoidlProject pProject, java.lang.String pShellCommand, org.eclipse.core.runtime.IProgressMonitor pMonitor)
      Create a process for the given shell command.
      java.lang.Process runToolWithEnv​(org.eclipse.core.resources.IProject pProject, IOOo pOOo, java.lang.String pShellCommand, java.lang.String[] pEnv, org.eclipse.core.runtime.IProgressMonitor pMonitor)
      Create a process for the given shell command.
    • Method Detail

      • initialize

        void initialize​(java.lang.String pHome,
                        java.lang.String name)
                 throws InvalidConfigException
        Set the new SDK Home after having checked for the existence of the idl and settings directory. If name is empty, it will be fetched from the dk.mk file
        Parameters:
        pHome - path to the new sdk home
        name - name of the new sdk
        Throws:
        InvalidConfigException -

        This exception is thrown when the following errors are encountered with the InvalidConfigException.INVALID_SDK_HOMEerror code:

        • the sdk path does not point to a valid directory
        • the $(SDK_HOME)/idl directory doesnt exist
        • the $(SDK_HOME)/settings directory doesnt exist
        • the sdk name and buildid cannot be fetched
        • an unexpected exception has been raised
      • getHome

        java.lang.String getHome()
        Returns the SDK home directory. This string could be passed to the Path constructor to get the folder object.
        Returns:
        SDK home directory
      • getName

        java.lang.String getName()
        Returns the SDK version number.
        Returns:
        the SDK version number
      • getBinPath

        org.eclipse.core.runtime.IPath getBinPath()
        Returns:
        the path to the directory containing the binaries in the SDK.
      • getIncludePath

        org.eclipse.core.runtime.IPath getIncludePath()
        Returns:
        the path to the includes in the SDK.
      • getLibPath

        org.eclipse.core.runtime.IPath getLibPath()
        Returns:
        the path to the libraries in the SDK.
      • runTool

        java.lang.Process runTool​(IUnoidlProject pProject,
                                  java.lang.String pShellCommand,
                                  org.eclipse.core.runtime.IProgressMonitor pMonitor)
        Create a process for the given shell command. This process will be created with the project parameters such as it's SDK and location path
        Parameters:
        pProject - the UNO project on which to run the tool
        pShellCommand - the shell command to execute the tool
        pMonitor - a process monitor to watch the tool launching
        Returns:
        the process executing the tool
      • runToolWithEnv

        java.lang.Process runToolWithEnv​(org.eclipse.core.resources.IProject pProject,
                                         IOOo pOOo,
                                         java.lang.String pShellCommand,
                                         java.lang.String[] pEnv,
                                         org.eclipse.core.runtime.IProgressMonitor pMonitor)
        Create a process for the given shell command. This process will be created with the project parameters such as it's SDK and location path
        Parameters:
        pProject - the folder from which to run the command
        pOOo - the ooo instance to run the tool
        pShellCommand - the shell command to execute the tool
        pEnv - tool environment variable
        pMonitor - a process monitor to watch the tool launching
        Returns:
        the process executing the tool