Class AbstractDtProjectContext

  • All Implemented Interfaces:
    ILifecycleContext
    Direct Known Subclasses:
    ProjectContext

    public abstract class AbstractDtProjectContext
    extends Object
    implements ILifecycleContext
    Abstract implementation of the EDT project context for the service lifecycle management subsystem. Ensures that the context data are always accessible, even if the project is already closed.
    • Constructor Detail

      • AbstractDtProjectContext

        public AbstractDtProjectContext​(IDtProject project)
        Constructs an instance of the AbstractDtProjectContext descendant class.
        Parameters:
        project - The project to create the context for. Cannot be null.
    • Method Detail

      • addNatures

        public void addNatures​(Collection<String> natures)
        Adds natures directly from the context.
        Parameters:
        natures - The natures to add.
      • getProject

        public IDtProject getProject()
        Gets the project from the context.
        Returns:
        The context project for the service lifecycle change operation. Cannot be null.
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • hasNature

        public boolean hasNature​(String nature)
        Checks if the corresponding project has a given nature.
        Returns:
        True if the project has a given nature; false otherwise.
      • getNatures

        public Set<String> getNatures()
        Gets the current set of natures for the context.
        Returns:
        The set of existing natures.