Class TargetEnvironment

java.lang.Object
org.eclipse.tycho.TargetEnvironment

public final class TargetEnvironment extends Object
  • Constructor Details

    • TargetEnvironment

      public TargetEnvironment()
    • TargetEnvironment

      public TargetEnvironment(String os, String ws, String arch)
  • Method Details

    • getOs

      public String getOs()
      Returns the operating system of the represented target environment.
    • getWs

      public String getWs()
      Returns the windowing system of the represented target environment.
    • getArch

      public String getArch()
      Returns the architecture of the represented target environment.
    • match

      public boolean match(String os, String ws, String arch)
    • match

      public boolean match(org.osgi.framework.Filter filter)
    • toConfigSpec

      public String toConfigSpec()
      Returns the target environment as string of the form ws.os.arch. This format is used by the p2 publishers and in that context called "configuration" or "config spec".
    • isWindows

      public boolean isWindows()
    • toFilterProperties

      public Map<String,String> toFilterProperties()
      Returns the target environment as map. The keys are "osgi.ws", "osgi.os", and "osgi.arch". This format is used by the p2 slicer to filter installable units by environments.
      Returns:
      a new instance of LinkedHashMap with the target environment set
    • match

      public boolean match(org.eclipse.equinox.p2.metadata.expression.IMatchExpression<org.eclipse.equinox.p2.metadata.IInstallableUnit> filter)
    • toFilterExpression

      public String toFilterExpression()
      Returns the target environment as LDAP filter expression. This format is used in p2 metadata.
      Returns:
      the LDAP that evaluates to true when installing for this target environment.
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • hashCode

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

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • getRunningEnvironment

      public static TargetEnvironment getRunningEnvironment()