@Test public void addRequirement() { Requirement r = new Requirement() { @Override public boolean isFulfilled() { return true; } @Override public Property getProperty() { return null; } }; Property p = new Property(null, null, null, null, null, Collections.<Annotation> emptySet()); p.addRequirement(r); Assert.assertEquals(1, p.getRequirements().size()); Assert.assertTrue(p.getRequirements().contains(r)); }
public void addRequirement(Requirement requirement) { requirements.add(requirement); }
Property { public void addRequirement(Requirement requirement) { requirements.add(requirement); } }
Property { public void addRequirement(Requirement requirement) { requirements.add(requirement); } Property(Module module, String name, Class<?> type, Method getter, Method setter,
			Iterable<Annotation> annotations); }
Property { public void addRequirement(Requirement requirement) { requirements.add(requirement); } Property(Module module, String name, Class<?> type, Method getter, Method setter,
			Iterable<Annotation> annotations); String getInfo(); void setInfo(String info); int getOrder(); void setOrder(int order); String getName(); Class<?> getType(); Method getGetter(); Method getSetter(); void addRequirement(Requirement requirement); boolean isActive(); Collection<Requirement> getRequirements(); Object getValue(); void setValue(Object value); void setValue(String value); boolean isNumber(); Collection<Annotation> getAnnotations(); @SuppressWarnings("unchecked") A getAnnotation(Class<? extends A> clazz); }
Property { public void addRequirement(Requirement requirement) { requirements.add(requirement); } Property(Module module, String name, Class<?> type, Method getter, Method setter,
			Iterable<Annotation> annotations); String getInfo(); void setInfo(String info); int getOrder(); void setOrder(int order); String getName(); Class<?> getType(); Method getGetter(); Method getSetter(); void addRequirement(Requirement requirement); boolean isActive(); Collection<Requirement> getRequirements(); Object getValue(); void setValue(Object value); void setValue(String value); boolean isNumber(); Collection<Annotation> getAnnotations(); @SuppressWarnings("unchecked") A getAnnotation(Class<? extends A> clazz);  }