Package io.didomi.sdk.models.extension
Class InternalPurposeKt
-
- All Implemented Interfaces:
public final class InternalPurposeKt
-
-
Method Summary
Modifier and Type Method Description final static PurposetoPurpose(InternalPurpose $self)Create Purpose object to return in public io.didomi.sdk.Didomi methods final static Set<String>getPurposeIds(Collection<InternalPurpose> $self)Get IDs from a list of purposes final static BooleancontainsById(Collection<InternalPurpose> $self, InternalPurpose purpose)Check if list contains a purpose with given id final static BooleanremoveById(Collection<InternalPurpose> $self, InternalPurpose purpose)Remove purpose with a specific id final static UnitsortByName(List<InternalPurpose> $self)Sort a purpose list by translated name final static Set<InternalPurpose>injectRequiredSpecialFeatures(Collection<InternalPurpose> $self, Map<String, InternalPurpose> availablePurposes, InternalVendor vendor)Inject required Special Features as if they were purposes. final static Map<String, InternalPurpose>injectSpecialFeatures(Map<String, InternalPurpose> $self, Collection<SpecialFeature> specialFeatures)Inject special features into dictionary of purposes. final static List<Integer>getIabIds(Iterable<InternalPurpose> $self)Get the list of IAB purpose ids from a list of purposes -
-
Method Detail
-
toPurpose
final static Purpose toPurpose(InternalPurpose $self)
Create Purpose object to return in public io.didomi.sdk.Didomi methods
-
getPurposeIds
final static Set<String> getPurposeIds(Collection<InternalPurpose> $self)
Get IDs from a list of purposes
-
containsById
final static Boolean containsById(Collection<InternalPurpose> $self, InternalPurpose purpose)
Check if list contains a purpose with given id
-
removeById
final static Boolean removeById(Collection<InternalPurpose> $self, InternalPurpose purpose)
Remove purpose with a specific id
-
sortByName
final static Unit sortByName(List<InternalPurpose> $self)
Sort a purpose list by translated name
-
injectRequiredSpecialFeatures
final static Set<InternalPurpose> injectRequiredSpecialFeatures(Collection<InternalPurpose> $self, Map<String, InternalPurpose> availablePurposes, InternalVendor vendor)
Inject required Special Features as if they were purposes. We mark special features as Consent - they are considered as purposes on our side (except when displayed) but everything else should work as if they were a purpose with legal absis consent.
- Parameters:
availablePurposes- available purposesvendor- vendor being mapped.
-
injectSpecialFeatures
final static Map<String, InternalPurpose> injectSpecialFeatures(Map<String, InternalPurpose> $self, Collection<SpecialFeature> specialFeatures)
Inject special features into dictionary of purposes.
- Parameters:
specialFeatures- to be injected
-
getIabIds
final static List<Integer> getIabIds(Iterable<InternalPurpose> $self)
Get the list of IAB purpose ids from a list of purposes
-
-
-
-