Package org.osgi.framework

Examples of org.osgi.framework.VersionRange


      path = matcher.group();
      matcher.usePattern(PATTERN_PARAMETER);
      while (matcher.find()) {
        Parameter parameter = ParameterFactory.create(matcher.group());
        if (parameter instanceof VersionAttribute)
          parameter = new VersionRangeAttribute(new VersionRange(String.valueOf(parameter.getValue())));
        parameters.put(parameter.getName(), parameter);
      }
      fillInDefaults(parameters);
    }
View Full Code Here


      path = matcher.group();
      matcher.usePattern(PATTERN_PARAMETER);
      while (matcher.find()) {
        Parameter parameter = ParameterFactory.create(matcher.group());
        if (parameter instanceof VersionAttribute)
          parameter = new VersionRangeAttribute(new VersionRange(String.valueOf(parameter.getValue())));
        parameters.put(parameter.getName(), parameter);
      }
      fillInDefaults(parameters);
    }
View Full Code Here

    deployedVersion = Version.parseVersion(value);
  }
 
  @Override
  public StringBuilder appendToFilter(StringBuilder builder) {
    VersionRange versionRange = new VersionRange(VersionRange.LEFT_CLOSED, getVersion(), getVersion(), VersionRange.RIGHT_CLOSED);
    return builder.append(versionRange.toFilterString(VersionRangeAttribute.NAME));
  }
View Full Code Here

      path = matcher.group();
      matcher.usePattern(PATTERN_PARAMETER);
      while (matcher.find()) {
        Parameter parameter = ParameterFactory.create(matcher.group());
        if (parameter instanceof VersionAttribute)
          parameter = new VersionRangeAttribute(new VersionRange(String.valueOf(parameter.getValue())));
        parameters.put(parameter.getName(), parameter);
      }
      fillInDefaults(parameters);
    }
View Full Code Here

   
    public VersionRange getVersionRange() {
      Attribute attribute = getAttribute(ATTRIBUTE_VERSION);
      if (attribute instanceof VersionRangeAttribute)
        return ((VersionRangeAttribute)attribute).getVersionRange();
      return new VersionRange(attribute.getValue().toString());
    }
View Full Code Here

  public VersionRangeAttribute() {
    this(Version.emptyVersion.toString());
  }
     
  public VersionRangeAttribute(String value) {
    this(new VersionRange(value));
  }
View Full Code Here

  public BundleVersionAttribute() {
    this(Version.emptyVersion.toString());
  }
     
  public BundleVersionAttribute(String value) {
    this(new VersionRange(value));
  }
View Full Code Here

      }
    fail("Path not found: " + path);
  }
 
  private void assertVersionAttribute(ImportPackageHeader.Clause clause, String expectedVersion) {
    assertVersionAttribute(clause, new VersionRange(expectedVersion));
  }
View Full Code Here

TOP

Related Classes of org.osgi.framework.VersionRange

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.