Package org.apache.aries.application

Examples of org.apache.aries.application.VersionRange.matches()


     
      if ((appContentRange == null) && (useBundleRange == null)){
        _provisionSharedContent.add(dp);
      } else if (appContentRange.matches(info.getVersion())) {
        _deploymentContent.add(dp);
      else if (useBundleRange.matches(info.getVersion())) {
        _deployedUseBundleContent.add(dp);
      }
      else {
        throw new ResolverException("Bundle " + info.getSymbolicName() + " at version " + info.getVersion() + " is not in the range " + appContentRange + " or " + useBundleRange);
      }
View Full Code Here


     
      DeploymentContent dp = new DeploymentContentImpl(info.getSymbolicName(), info.getVersion());
     
      if (range == null) {
        _provisionSharedContent.add(dp);
      } else if (range.matches(info.getVersion())) {
        _deploymentContent.add(dp);
      } else {
        throw new ResolverException("Bundle " + info.getSymbolicName() + " at version " + info.getVersion() + " is not in the range " + range);
      }
    }
View Full Code Here

  @Test
  public void testMatches()
  {
    VersionRange vr = new VersionRangeImpl("[1.0.0, 2.0.0]");
   
    assertFalse(vr.matches(new Version(0,9,0)));
    assertFalse(vr.matches(new Version(2,1,0)));
    assertTrue(vr.matches(new Version(2,0,0)));
    assertTrue(vr.matches(new Version(1,0,0)));
    assertTrue(vr.matches(new Version(1,5,0)));
   
View Full Code Here

  public void testMatches()
  {
    VersionRange vr = new VersionRangeImpl("[1.0.0, 2.0.0]");
   
    assertFalse(vr.matches(new Version(0,9,0)));
    assertFalse(vr.matches(new Version(2,1,0)));
    assertTrue(vr.matches(new Version(2,0,0)));
    assertTrue(vr.matches(new Version(1,0,0)));
    assertTrue(vr.matches(new Version(1,5,0)));
   
    vr = new VersionRangeImpl("[1.0.0, 2.0.0)");
View Full Code Here

  {
    VersionRange vr = new VersionRangeImpl("[1.0.0, 2.0.0]");
   
    assertFalse(vr.matches(new Version(0,9,0)));
    assertFalse(vr.matches(new Version(2,1,0)));
    assertTrue(vr.matches(new Version(2,0,0)));
    assertTrue(vr.matches(new Version(1,0,0)));
    assertTrue(vr.matches(new Version(1,5,0)));
   
    vr = new VersionRangeImpl("[1.0.0, 2.0.0)");
   
View Full Code Here

    VersionRange vr = new VersionRangeImpl("[1.0.0, 2.0.0]");
   
    assertFalse(vr.matches(new Version(0,9,0)));
    assertFalse(vr.matches(new Version(2,1,0)));
    assertTrue(vr.matches(new Version(2,0,0)));
    assertTrue(vr.matches(new Version(1,0,0)));
    assertTrue(vr.matches(new Version(1,5,0)));
   
    vr = new VersionRangeImpl("[1.0.0, 2.0.0)");
   
    assertFalse(vr.matches(new Version(0,9,0)));
View Full Code Here

   
    assertFalse(vr.matches(new Version(0,9,0)));
    assertFalse(vr.matches(new Version(2,1,0)));
    assertTrue(vr.matches(new Version(2,0,0)));
    assertTrue(vr.matches(new Version(1,0,0)));
    assertTrue(vr.matches(new Version(1,5,0)));
   
    vr = new VersionRangeImpl("[1.0.0, 2.0.0)");
   
    assertFalse(vr.matches(new Version(0,9,0)));
    assertFalse(vr.matches(new Version(2,1,0)));
View Full Code Here

    assertTrue(vr.matches(new Version(1,0,0)));
    assertTrue(vr.matches(new Version(1,5,0)));
   
    vr = new VersionRangeImpl("[1.0.0, 2.0.0)");
   
    assertFalse(vr.matches(new Version(0,9,0)));
    assertFalse(vr.matches(new Version(2,1,0)));
    assertFalse(vr.matches(new Version(2,0,0)));
    assertTrue(vr.matches(new Version(1,0,0)));
    assertTrue(vr.matches(new Version(1,5,0)));
View Full Code Here

    assertTrue(vr.matches(new Version(1,5,0)));
   
    vr = new VersionRangeImpl("[1.0.0, 2.0.0)");
   
    assertFalse(vr.matches(new Version(0,9,0)));
    assertFalse(vr.matches(new Version(2,1,0)));
    assertFalse(vr.matches(new Version(2,0,0)));
    assertTrue(vr.matches(new Version(1,0,0)));
    assertTrue(vr.matches(new Version(1,5,0)));

    vr = new VersionRangeImpl("(1.0.0, 2.0.0)");
View Full Code Here

   
    vr = new VersionRangeImpl("[1.0.0, 2.0.0)");
   
    assertFalse(vr.matches(new Version(0,9,0)));
    assertFalse(vr.matches(new Version(2,1,0)));
    assertFalse(vr.matches(new Version(2,0,0)));
    assertTrue(vr.matches(new Version(1,0,0)));
    assertTrue(vr.matches(new Version(1,5,0)));

    vr = new VersionRangeImpl("(1.0.0, 2.0.0)");
   
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.