com.atlassian.crowd.embedded.api
Class Directories

java.lang.Object
  extended by com.atlassian.crowd.embedded.api.Directories

public final class Directories
extends Object

Utility class for Directory

Since:
v2.7

Field Summary
static com.google.common.base.Predicate<Directory> ACTIVE_FILTER
          A predicate that matches directories that are active
static com.google.common.base.Function<Directory,String> NAME_FUNCTION
          A function that projects the directory name
 
Method Summary
static com.google.common.base.Predicate<Directory> directoryWithIdPredicate(long directoryId)
          Matches for directories with the specified directoryId.
static Iterable<String> namesOf(Iterable<? extends Directory> directories)
          Transforms directories into their names.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NAME_FUNCTION

public static final com.google.common.base.Function<Directory,String> NAME_FUNCTION
A function that projects the directory name


ACTIVE_FILTER

public static final com.google.common.base.Predicate<Directory> ACTIVE_FILTER
A predicate that matches directories that are active

Method Detail

namesOf

public static Iterable<String> namesOf(Iterable<? extends Directory> directories)
Transforms directories into their names.

Parameters:
directories - some directories
Returns:
their names

directoryWithIdPredicate

public static com.google.common.base.Predicate<Directory> directoryWithIdPredicate(long directoryId)
Matches for directories with the specified directoryId.

Parameters:
directoryId - directory ID to match
Returns:
true if the directory has the specified directoryID


Copyright © 2015 Atlassian. All Rights Reserved.