org.deidentifier.arx.criteria

## Class EDDifferentialPrivacy

- java.lang.Object
- - org.deidentifier.arx.criteria.PrivacyCriterion
  - - org.deidentifier.arx.criteria.ImplicitPrivacyCriterion
    - - org.deidentifier.arx.criteria.EDDifferentialPrivacy

All Implemented Interfaces:
  java.io.Serializable

    public class EDDifferentialPrivacy
    extends ImplicitPrivacyCriterion

(e,d)-Differential Privacy implemented with SafePub as proposed in: Bild R, Kuhn KA, Prasser F. SafePub: A Truthful Data Anonymization Algorithm With Strong Privacy Guarantees. Proceedings on Privacy Enhancing Technologies. 2018(1):67-87. SafePub, in turn, is a practical implementation of (k,b)-SDGS which was originally proposed in: Ninghui Li, Wahbeh H. Qardaji, Dong Su: On sampling, anonymization, and differential privacy or, k-anonymization meets differential privacy. Proceedings of ASIACCS 2012. pp. 32-33

Author:
  Raffael Bild, Fabian Prasser, Florian Kohlmayer
See Also:
  Serialized Form

### Constructor Summary

Constructors
Constructor and Description
`EDDifferentialPrivacy(double epsilon, double delta)` Creates a new data-dependent instance
`EDDifferentialPrivacy(double epsilon, double delta, DataGeneralizationScheme generalization)` Creates a new instance which is data-independent iff generalization is not null
`EDDifferentialPrivacy(double epsilon, double delta, DataGeneralizationScheme generalization, boolean deterministic)` Creates a new instance which may be configured to produce deterministic output.

### Method Summary

All Methods Instance Methods Concrete Methods
`EDDifferentialPrivacy` `clone()` Clone
`double` `getBeta()` Returns the beta parameter of (k,b)-SDGS
`DataSubset` `getDataSubset()` If a privacy model uses a data subset, it must overwrite this method
`double` `getDelta()` Returns the delta parameter of (e,d)-DP
`double` `getEpsilon()` Returns the epsilon parameter of (e,d)-DP
`DataGeneralizationScheme` `getGeneralizationScheme()` Returns the defined generalization scheme
`int` `getK()` Returns the k parameter of (k,b)-SDGS
`int` `getMinimalClassSize()` If a privacy model provides a prosecutor risk threshold, it should override this method to enable optimizations
`int` `getRequirements()` Returns the criterion's requirements.
`void` `initialize(DataManager manager, ARXConfiguration config)` Override this to initialize the criterion.
`boolean` `isAnonymous(Transformation<?> node, HashGroupifyEntry entry)` Implement this, to enforce the criterion.
`boolean` `isDataDependent()` Returns whether this instance is data-dependent
`boolean` `isDeterministic()` Returns whether this instance is deterministic
`boolean` `isHeuristicSearchSupported()` Returns whether the criterion supports heuristic search strategies.
`boolean` `isHeuristicSearchWithTimeLimitSupported()` Returns whether the criterion supports heuristic search strategies with time limits.
`boolean` `isLocalRecodingSupported()` Returns whether the criterion supports local recoding.
`boolean` `isMinimalClassSizeAvailable()` If a privacy model provides a prosecutor risk threshold, it should override this method to enable optimizations
`boolean` `isOptimalSearchSupported()` Returns whether the criterion supports optimal search strategies.
`boolean` `isSubsetAvailable()` If a privacy model uses a data subset, it must overwrite this method
`ElementData` `render()` Renders the privacy model
`java.lang.String` `toString()` Returns a string representation.

### Methods inherited from class org.deidentifier.arx.criteria.PrivacyCriterion

`clone, getPopulationModel, getRiskThresholdJournalist, getRiskThresholdMarketer, getRiskThresholdProsecutor, getSubset, isMonotonicWithGeneralization, isMonotonicWithSuppression, isSampleBased`

### Methods inherited from class java.lang.Object

`equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Constructor Detail

#### EDDifferentialPrivacy

    public EDDifferentialPrivacy(double epsilon,
                                 double delta,
                                 DataGeneralizationScheme generalization)

Creates a new instance which is data-independent iff generalization is not null

Parameters:
  `epsilon` -
  `delta` -
  `generalization` -

#### EDDifferentialPrivacy

    public EDDifferentialPrivacy(double epsilon,
                                 double delta)

Creates a new data-dependent instance

Parameters:
  `epsilon` -
  `delta` -

#### EDDifferentialPrivacy

    public EDDifferentialPrivacy(double epsilon,
                                 double delta,
                                 DataGeneralizationScheme generalization,
                                 boolean deterministic)

Creates a new instance which may be configured to produce deterministic output. Note: *never* set deterministic to true in production. This parameterization is for testing purposes, only.

Parameters:
  `epsilon` -
  `delta` -
  `generalization` -
  `deterministic` -

### Method Detail

#### clone

    public EDDifferentialPrivacy clone()

Description copied from class: `PrivacyCriterion`
Clone

Specified by:
  `clone` in class `PrivacyCriterion`

#### getBeta

    public double getBeta()

Returns the beta parameter of (k,b)-SDGS

Returns:

#### getDataSubset

    public DataSubset getDataSubset()

Description copied from class: `PrivacyCriterion`
If a privacy model uses a data subset, it must overwrite this method

Overrides:
  `getDataSubset` in class `PrivacyCriterion`
Returns:

#### getDelta

    public double getDelta()

Returns the delta parameter of (e,d)-DP

Returns:

#### getEpsilon

    public double getEpsilon()

Returns the epsilon parameter of (e,d)-DP

Returns:

#### getGeneralizationScheme

    public DataGeneralizationScheme getGeneralizationScheme()

Returns the defined generalization scheme

Returns:

#### getK

    public int getK()

Returns the k parameter of (k,b)-SDGS

Returns:

#### getMinimalClassSize

    public int getMinimalClassSize()

Description copied from class: `PrivacyCriterion`
If a privacy model provides a prosecutor risk threshold, it should override this method to enable optimizations

Overrides:
  `getMinimalClassSize` in class `PrivacyCriterion`
Returns:

#### getRequirements

    public int getRequirements()

Description copied from class: `PrivacyCriterion`
Returns the criterion's requirements.

Specified by:
  `getRequirements` in class `PrivacyCriterion`
Returns:

#### initialize

    public void initialize(DataManager manager,
                           ARXConfiguration config)

Description copied from class: `PrivacyCriterion`
Override this to initialize the criterion.

Overrides:
  `initialize` in class `PrivacyCriterion`
  `config` - TODO

#### isAnonymous

    public boolean isAnonymous(Transformation<?> node,
                               HashGroupifyEntry entry)

Description copied from class: `PrivacyCriterion`
Implement this, to enforce the criterion.

Specified by:
  `isAnonymous` in class `PrivacyCriterion`
Parameters:
  `node` - TODO
Returns:

#### isDataDependent

    public boolean isDataDependent()

Returns whether this instance is data-dependent

Returns:

#### isDeterministic

    public boolean isDeterministic()

Returns whether this instance is deterministic

Returns:

#### isHeuristicSearchSupported

    public boolean isHeuristicSearchSupported()

Description copied from class: `PrivacyCriterion`
Returns whether the criterion supports heuristic search strategies.

Overrides:
  `isHeuristicSearchSupported` in class `PrivacyCriterion`
Returns:

#### isHeuristicSearchWithTimeLimitSupported

    public boolean isHeuristicSearchWithTimeLimitSupported()

Description copied from class: `PrivacyCriterion`
Returns whether the criterion supports heuristic search strategies with time limits.

Overrides:
  `isHeuristicSearchWithTimeLimitSupported` in class `PrivacyCriterion`
Returns:

#### isOptimalSearchSupported

    public boolean isOptimalSearchSupported()

Description copied from class: `PrivacyCriterion`
Returns whether the criterion supports optimal search strategies.

Overrides:
  `isOptimalSearchSupported` in class `PrivacyCriterion`
Returns:

#### isLocalRecodingSupported

    public boolean isLocalRecodingSupported()

Description copied from class: `PrivacyCriterion`
Returns whether the criterion supports local recoding.

Specified by:
  `isLocalRecodingSupported` in class `PrivacyCriterion`
Returns:

#### isMinimalClassSizeAvailable

    public boolean isMinimalClassSizeAvailable()

Description copied from class: `PrivacyCriterion`
If a privacy model provides a prosecutor risk threshold, it should override this method to enable optimizations

Overrides:
  `isMinimalClassSizeAvailable` in class `PrivacyCriterion`
Returns:

#### isSubsetAvailable

    public boolean isSubsetAvailable()

Description copied from class: `PrivacyCriterion`
If a privacy model uses a data subset, it must overwrite this method

Overrides:
  `isSubsetAvailable` in class `PrivacyCriterion`
Returns:

#### render

    public ElementData render()

Description copied from class: `PrivacyCriterion`
Renders the privacy model

Specified by:
  `render` in class `PrivacyCriterion`
Returns:

#### toString

    public java.lang.String toString()

Description copied from class: `PrivacyCriterion`
Returns a string representation.

Specified by:
  `toString` in class `PrivacyCriterion`