Overview | Package | Class | Use | Tree | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.togethersoft.openapi.ide.project
Interface IdeProject

public interface IdeProject

Interface `IdeProject` defines a Together project.

To open or close a found project, `open` and `close` methods are used. Note, that opening a found project only loads it into IDE. It is also possible to obtain information about a non-opened found `IdeProject`, same as for the opened projects. (See IdeProjectManager.getProject method).

The project consists of `IdeProjectNode`s, each representing a file or a directory.

Author:
  TogetherSoft
See Also: IdeProjectManager, IdeProjectNode

Method Summary
`void` | `addImportPath(String path)` Adds specified `path` to the project as a set of root `IdeProjectNode` instances.
`void` | `close(boolean save)` Closes this project.
`IdeProjectNode` | `findNode(String url)` Given the node's URL, finds the `IdeProjectNode`( which can be a file or a directory).
`String` | `getDefaultLanguage()` Returns the string with the name of this project's default language.
`String` | `getFileName()` Returns a string with the full path to the file representing this project.
`String` | `getName()` Returns a short name of a project.
`boolean` | `isOpen()` Checks whether this project is opened.
`void` | `open()` Loads this project into IDE.
`IdeProjectNodeEnumeration` | `roots()` Returns an enumeration of all root `IdeProjectNode`s for this project.

Method Detail

### addImportPath

    public void addImportPath(String path)

  Adds specified `path` to the project as a set of root `IdeProjectNode` instances. can consist of several paths separated with a File.separator.
  Parameters:
    path - `String` to be added

### close

    public void close(boolean save)
                throws com.togethersoft.openapi.util.VetoException,
                       java.io.IOException

  Closes this project. If `save` parameter is `true` then it saves the changed data, otherwise does not save.
  Parameters:
    save - `boolean` value indicating whether the changed data should be saved
  Throws:
    VetoException - if an error occurred.
    IOException

### findNode

    public IdeProjectNode findNode(String url)

  Given the node's URL, finds the `IdeProjectNode`( which can be a file or a directory).
  Parameters:
    url - `String` with `IdeProjectNode`'s URL. For example, for a directory "c:\together\myprojects" this will be `"c:\together\myprojects"`.
  Returns: `IdeProjectNode`

### getDefaultLanguage

    public String getDefaultLanguage()

  Returns the string with the name of this project's default language. The predefined values are in `SciLanguage` interface.
  Returns: `String` that denotes the language of the current project
  See Also:
    SciLanguage

### getFileName

    public String getFileName()

  Returns a string with the full path to the file representing this project. For example, if a project named "myTestProj" is located in the "c:\myProjects" directory, this method will return `"c:\myProjects\myTestProj.tpr"`
  Returns: `String` fully qualified project name

### getName

    public String getName()

  Returns a short name of a project. For example, for a project is "c:\myProjects\myTestProj.tpr" this method will return "myTestProj.tpr".
  Returns: `String` short name of this project

### isOpen

    public boolean isOpen()

  Checks whether this project is opened.
  Returns: `true` if this project is opened, `false` otherwise

### open

    public void open()
               throws com.togethersoft.openapi.util.VetoException,
                      java.io.IOException

  Loads this project into IDE. If an error occurred throws the `VetoException`.
  Throws:
    VetoException - if an error occurred
    IOException

### roots

    public IdeProjectNodeEnumeration roots()

  Returns an enumeration of all root `IdeProjectNode`s for this project.
  Returns: an enumeration of all root `IdeProjectNode`s for this project
  See Also:
    IdeProjectNode

Overview | Package | Class | Use | Tree | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD