Package org.deidentifier.arx.aggregates
Klasse HierarchyBuilderPriorityBased<T>
java.lang.Object
org.deidentifier.arx.aggregates.HierarchyBuilder<T>
org.deidentifier.arx.aggregates.HierarchyBuilderPriorityBased<T>
- Typparameter:
T-
- Alle implementierten Schnittstellen:
Serializable
This class enables building hierarchies mostly for categorical variables
by iteratively removing the value with lowest priority
- Siehe auch:
-
Verschachtelte Klassen - Übersicht
Verschachtelte KlassenModifizierer und TypKlasseBeschreibungstatic enumFor prioritiesVon Klasse geerbte verschachtelte Klassen/Schnittstellen org.deidentifier.arx.aggregates.HierarchyBuilder
HierarchyBuilder.Type -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungbuild()Creates a new hierarchy, based on the predefined specification.Creates a new hierarchy, based on the predefined specification.static <T> HierarchyBuilderPriorityBased<T> Loads a builder specification from the given file.static <T> HierarchyBuilderPriorityBased<T> Loads a builder specification from the given file.static <T> HierarchyBuilderPriorityBased<T> Create a new instance, prioritized by the order provided in the given array (highest to lowest) with a maximum of 10 levels.static <T> HierarchyBuilderPriorityBased<T> create(Map<String, Integer> priorities, HierarchyBuilderPriorityBased.Priority priority) Create a new instance, prioritized by the order provided in the given array with the given order with a maximum of 10 levels.static <T> HierarchyBuilderPriorityBased<T> create(Map<String, Integer> priorities, HierarchyBuilderPriorityBased.Priority priority, int maxLevels) Create a new instance, prioritized by the order provided in the given array (highest to lowest)static <T> HierarchyBuilderPriorityBased<T> Create a new instance, prioritized by the order implied by the data type in order highest to lowest and a maximum of 10 levels.static <T> HierarchyBuilderPriorityBased<T> create(DataType<T> type, HierarchyBuilderPriorityBased.Priority priority) Create a new instance, prioritized by the order implied by the data type and a maximum of 10 levels.static <T> HierarchyBuilderPriorityBased<T> create(DataType<T> type, HierarchyBuilderPriorityBased.Priority priority, int maxLevels) Create a new instance, prioritized by the order implied by the data type.intGets the maximal number of levelsbooleanReturns whether domain-properties are available for this builder.int[]Prepares the builder.voidsetMaxLevels(int maxLevels) Sets the maximal number of levelsVon Klasse geerbte Methoden org.deidentifier.arx.aggregates.HierarchyBuilder
getType, save, save
-
Methodendetails
-
create
Create a new instance, prioritized by the order implied by the data type in order highest to lowest and a maximum of 10 levels.- Typparameter:
T-- Parameter:
dataType-- Gibt zurück:
-
create
public static <T> HierarchyBuilderPriorityBased<T> create(DataType<T> type, HierarchyBuilderPriorityBased.Priority priority) Create a new instance, prioritized by the order implied by the data type and a maximum of 10 levels.- Typparameter:
T-- Parameter:
priority-dataType-- Gibt zurück:
-
create
public static <T> HierarchyBuilderPriorityBased<T> create(DataType<T> type, HierarchyBuilderPriorityBased.Priority priority, int maxLevels) Create a new instance, prioritized by the order implied by the data type.- Typparameter:
T-- Parameter:
maxLevels-dataType-- Gibt zurück:
-
create
Loads a builder specification from the given file.- Typparameter:
T-- Parameter:
file-- Gibt zurück:
- Löst aus:
IOException
-
create
Create a new instance, prioritized by the order provided in the given array (highest to lowest) with a maximum of 10 levels.- Typparameter:
T-- Parameter:
priorities-- Gibt zurück:
-
create
public static <T> HierarchyBuilderPriorityBased<T> create(Map<String, Integer> priorities, HierarchyBuilderPriorityBased.Priority priority) Create a new instance, prioritized by the order provided in the given array with the given order with a maximum of 10 levels.- Typparameter:
T-- Parameter:
priorities-priority-- Gibt zurück:
-
create
public static <T> HierarchyBuilderPriorityBased<T> create(Map<String, Integer> priorities, HierarchyBuilderPriorityBased.Priority priority, int maxLevels) Create a new instance, prioritized by the order provided in the given array (highest to lowest)- Typparameter:
T-- Parameter:
priorities-priority-maxLevels-- Gibt zurück:
-
create
Loads a builder specification from the given file.- Typparameter:
T-- Parameter:
file-- Gibt zurück:
- Löst aus:
IOException
-
build
Creates a new hierarchy, based on the predefined specification.- Angegeben von:
buildin KlasseHierarchyBuilder<T>- Gibt zurück:
-
build
Creates a new hierarchy, based on the predefined specification.- Angegeben von:
buildin KlasseHierarchyBuilder<T>- Parameter:
data- - Prioritized from highest to lowest- Gibt zurück:
-
getDataType
- Gibt zurück:
- the type
-
getMaxLevels
public int getMaxLevels()Gets the maximal number of levels- Gibt zurück:
- the maxLevels
-
getPriorities
- Gibt zurück:
- the priorities
-
getPriority
- Gibt zurück:
- the priority
-
isDomainPropertiesAvailable
public boolean isDomainPropertiesAvailable()Returns whether domain-properties are available for this builder. Currently, this information is only used for evaluating information loss with the generalized loss metric for attributes with functional redaction-based hierarchies.- Gibt zurück:
-
prepare
Prepares the builder. Returns a list of the number of equivalence classes per level- Angegeben von:
preparein KlasseHierarchyBuilder<T>- Parameter:
data- In prioritized order, with highest priority to lowest priority- Gibt zurück:
-
setMaxLevels
public void setMaxLevels(int maxLevels) Sets the maximal number of levels- Parameter:
maxLevels- the maxLevels to set
-