@Test public void testUpdate() throws Exception { enhancedDependencies.update( new NormalEnhancedDependency( new Dependency( new GAV( "org.hamcrest", "hamcrest-core", "1.3" ) ), new HashSet<String>() ) ); NormalEnhancedDependency enhancedDependency = ( NormalEnhancedDependency ) enhancedDependencies.get( new GAV( "org.hamcrest", "hamcrest-core", "1.3" ) ); assertTrue( enhancedDependency.getTransitiveDependencies().isEmpty() ); }
public void update( final EnhancedDependency enhancedDependency ) { remove( enhancedDependency ); add( enhancedDependency ); }
EnhancedDependencies implements Iterable<EnhancedDependency> { public void update( final EnhancedDependency enhancedDependency ) { remove( enhancedDependency ); add( enhancedDependency ); } }
EnhancedDependencies implements Iterable<EnhancedDependency> { public void update( final EnhancedDependency enhancedDependency ) { remove( enhancedDependency ); add( enhancedDependency ); } EnhancedDependencies();  EnhancedDependencies( final List<EnhancedDependency> enhancedDependencies ); }
EnhancedDependencies implements Iterable<EnhancedDependency> { public void update( final EnhancedDependency enhancedDependency ) { remove( enhancedDependency ); add( enhancedDependency ); } EnhancedDependencies();  EnhancedDependencies( final List<EnhancedDependency> enhancedDependencies ); void add( final EnhancedDependency enhancedDependency ); boolean remove( final EnhancedDependency enhancedDependency ); boolean isEmpty(); boolean contains( final EnhancedDependency enhancedDependency ); void update( final EnhancedDependency enhancedDependency ); EnhancedDependency get( final GAV gav ); @Override Iterator<EnhancedDependency> iterator(); List<? extends EnhancedDependency> asList(); int size(); void addAll( final Collection<EnhancedDependency> transitiveDependencies ); void clear(); }
EnhancedDependencies implements Iterable<EnhancedDependency> { public void update( final EnhancedDependency enhancedDependency ) { remove( enhancedDependency ); add( enhancedDependency ); } EnhancedDependencies();  EnhancedDependencies( final List<EnhancedDependency> enhancedDependencies ); void add( final EnhancedDependency enhancedDependency ); boolean remove( final EnhancedDependency enhancedDependency ); boolean isEmpty(); boolean contains( final EnhancedDependency enhancedDependency ); void update( final EnhancedDependency enhancedDependency ); EnhancedDependency get( final GAV gav ); @Override Iterator<EnhancedDependency> iterator(); List<? extends EnhancedDependency> asList(); int size(); void addAll( final Collection<EnhancedDependency> transitiveDependencies ); void clear();  }