Class TargetFeature


  • public class TargetFeature
    extends java.lang.Object
    Describes a single feature in a target definition.
    Since:
    3.8
    • Constructor Summary

      Constructors 
      Constructor Description
      TargetFeature​(java.io.File featureLocation)
      Constructs a target feature for a feature on the local filesystem.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      NameVersionDescriptor[] getDependentFeatures()
      Returns a list of name version descriptors that describe the set of features that this feature depends on as imports or included features.
      java.lang.String getId()
      Returns the id of this feature or null if no id is set.
      java.lang.String getLocation()
      Returns the string path to the directory containing the feature.xml or null if no install location is known.
      NameVersionDescriptor[] getPlugins()
      Returns a list of name version descriptor that describes the set of plug-ins that this feature includes.
      java.lang.String getVersion()
      Returns the version of this feature or null if no version is set.
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • TargetFeature

        public TargetFeature​(java.io.File featureLocation)
                      throws CoreException
        Constructs a target feature for a feature on the local filesystem. The file may point at the feature.xml or a folder containing the feature.xml. The feature.xml will be read to collect the information about the feature.
        Parameters:
        featureLocation - the location of the feature (feature.xml or directory containing it)
        Throws:
        CoreException - if there is a problem opening the feature.xml
    • Method Detail

      • getId

        public java.lang.String getId()
        Returns the id of this feature or null if no id is set.
        Returns:
        id or null
      • getVersion

        public java.lang.String getVersion()
        Returns the version of this feature or null if no version is set.
        Returns:
        version or null
      • getLocation

        public java.lang.String getLocation()
        Returns the string path to the directory containing the feature.xml or null if no install location is known.
        Returns:
        install location path or null
      • getPlugins

        public NameVersionDescriptor[] getPlugins()
        Returns a list of name version descriptor that describes the set of plug-ins that this feature includes.
        Returns:
        a list of name version descriptors, possibly empty
      • getDependentFeatures

        public NameVersionDescriptor[] getDependentFeatures()
        Returns a list of name version descriptors that describe the set of features that this feature depends on as imports or included features.
        Returns:
        a list of name version descriptors, possibly empty
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object