public class DirectoryEntities extends Object
DirectoryEntity
.Modifier and Type | Field and Description |
---|---|
static com.google.common.base.Function<DirectoryEntity,String> |
LOWER_NAME_FUNCTION
A function that projects the lower case name
|
static com.google.common.base.Function<DirectoryEntity,String> |
NAME_FUNCTION
A function that projects the name
|
Constructor and Description |
---|
DirectoryEntities() |
Modifier and Type | Method and Description |
---|---|
static <T> List<T> |
filterOutDuplicates(Collection<T> remoteEntities,
com.google.common.base.Function<T,String> nameProvider) |
static <T extends DirectoryEntity> |
filterOutDuplicates(List<T> remoteEntities)
Remove the duplicate entities from the passed list.
|
static Iterable<String> |
namesOf(Iterable<? extends DirectoryEntity> entities)
Transforms entities into their names.
|
public static final com.google.common.base.Function<DirectoryEntity,String> NAME_FUNCTION
public static final com.google.common.base.Function<DirectoryEntity,String> LOWER_NAME_FUNCTION
public static Iterable<String> namesOf(Iterable<? extends DirectoryEntity> entities)
entities
- some entitiespublic static <T extends DirectoryEntity> List<T> filterOutDuplicates(List<T> remoteEntities)
T
- the type of entity to filter.remoteEntities
- the entities to filter.public static <T> List<T> filterOutDuplicates(Collection<T> remoteEntities, com.google.common.base.Function<T,String> nameProvider)
Copyright © 2020 Atlassian. All rights reserved.