ch.systemsx.cisd.openbis.generic.shared.api.v1.dto
Class DataSetTypeFilter

java.lang.Object
  extended by ch.systemsx.cisd.openbis.generic.shared.api.v1.dto.DataSetTypeFilter

public class DataSetTypeFilter
extends java.lang.Object

A class that filters out data set types based on a whitelist or blacklist.

Only one list can be applied. If both the whitelist and blacklist are specified, then the whitelist is used. If neither are specified, then no filtering is done.


Constructor Summary
DataSetTypeFilter(java.lang.String whitelistPatternString, java.lang.String blacklistPatternString)
          Constructor
 
Method Summary
static java.lang.String convertPatternListToString(java.util.List<java.lang.String> dataSetTypePatterns)
          Takes a List of patterns and serializes them to a single string that this class can later reread.
 java.util.List<DataSetType> filterDataSetTypes(java.util.List<DataSetType> typesToFilter)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DataSetTypeFilter

public DataSetTypeFilter(java.lang.String whitelistPatternString,
                         java.lang.String blacklistPatternString)
Constructor

Parameters:
whitelistPatternString - A string serialized using convertPatternListToString(java.util.List).
blacklistPatternString - A string serialized using convertPatternListToString(java.util.List).
Method Detail

convertPatternListToString

public static java.lang.String convertPatternListToString(java.util.List<java.lang.String> dataSetTypePatterns)
Takes a List of patterns and serializes them to a single string that this class can later reread.


filterDataSetTypes

public java.util.List<DataSetType> filterDataSetTypes(java.util.List<DataSetType> typesToFilter)