public class PermittedGroupMatcher<E extends PermittedGroup>
extends org.hamcrest.TypeSafeMatcher<E>
Constructor and Description |
---|
PermittedGroupMatcher(org.hamcrest.Matcher<String> nameMatcher,
org.hamcrest.Matcher<Long> directoryIdMatcher,
org.hamcrest.Matcher<String> directoryNameMatcher,
org.hamcrest.Matcher<Integer> permissionIdMatcher) |
Modifier and Type | Method and Description |
---|---|
void |
describeTo(org.hamcrest.Description description) |
static <T extends PermittedGroup> |
group()
A matcher that matches any directoryGroup.
|
static <T extends PermittedGroup> |
group(Class<T> type)
A matcher that matches any directoryGroup; synonymous with
group() but its argument is used to set the matcher type. |
protected boolean |
matchesSafely(E item) |
PermittedGroupMatcher<E> |
matching(PermittedGroup group)
Builds a new specialised matcher to match the attributes in the given group exactly; the returned matcher will only match if all
this matcher's non-group-attribute constraints are matched AND all of the matcher's group-attributes are matched.
|
describeMismatch, describeMismatchSafely, matches
public static <T extends PermittedGroup> PermittedGroupMatcher<T> group()
T
- type of directoryGroup, to avoid castingpublic static <T extends PermittedGroup> PermittedGroupMatcher<T> group(Class<T> type)
group()
but its argument is used to set the matcher type.T
- type of directoryGroup, to avoid castingtype
- type of directoryGroup, to avoid casting (this type is not checked at runtime).public PermittedGroupMatcher<E> matching(PermittedGroup group)
group
- group which must equivalent to the directory group on all matchersprotected boolean matchesSafely(E item)
matchesSafely
in class org.hamcrest.TypeSafeMatcher<E extends PermittedGroup>
public void describeTo(org.hamcrest.Description description)
Copyright © 2021 Atlassian. All rights reserved.