# ModelProfitabilityCriterion (ARX GUI Documentation)

org.deidentifier.arx.gui.model

## Class ModelProfitabilityCriterion

- java.lang.Object
- - org.deidentifier.arx.gui.model.ModelCriterion
  - - org.deidentifier.arx.gui.model.ModelImplicitCriterion
    - - org.deidentifier.arx.gui.model.ModelProfitabilityCriterion

- All Implemented Interfaces:
    java.io.Serializable

      public class ModelProfitabilityCriterion
      extends ModelImplicitCriterion

  This class provides a model for the game-theoretic privacy model
  See Also:
    Serialized Form

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `ModelProfitabilityCriterion.AttackerModel` The attacker model used by the privacy model

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ModelProfitabilityCriterion()` Creates a new instance
    `ModelProfitabilityCriterion(ModelProfitabilityCriterion.AttackerModel attackerModel, boolean allowAttacks)` Creates a new instance

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `ModelCriterion` | `clone()` Clone
    `ModelProfitabilityCriterion.AttackerModel` | `getAttackerModel()`
    `PrivacyCriterion` | `getCriterion(Model model)` Implement this to return the criterion.
    `java.lang.String` | `getLabel()` Implement this to return a string representation.
    `boolean` | `isAllowAttacks()`
    `void` | `parse(ModelCriterion criterion, boolean _default)` Parse
    `void` | `setAllowAttacks(boolean allowAttacks)` Defines whether we allow attacks to happen
    `void` | `setAttackerModel(ModelProfitabilityCriterion.AttackerModel attackerModel)` Defines the attacker model
    `java.lang.String` | `toString()` Implement this to return a string representation.

    - ### Methods inherited from class org.deidentifier.arx.gui.model.ModelCriterion

      `isEnabled, setEnabled`

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

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

- - ### Constructor Detail

    - #### ModelProfitabilityCriterion

          public ModelProfitabilityCriterion()

      Creates a new instance

    - #### ModelProfitabilityCriterion

          public ModelProfitabilityCriterion(ModelProfitabilityCriterion.AttackerModel attackerModel,
                                     boolean allowAttacks)

      Creates a new instance
      Parameters:
        `attackerModel` -
        `allowAttacks` -

  - ### Method Detail

    - #### clone

          public ModelCriterion clone()

      Description copied from class: `ModelCriterion`
      Clone
      Specified by:
        `clone` in class `ModelCriterion`

    - #### getAttackerModel

          public ModelProfitabilityCriterion.AttackerModel getAttackerModel()

      Returns:
        the attackerModel

    - #### getCriterion

          public PrivacyCriterion getCriterion(Model model)

      Description copied from class: `ModelCriterion`
      Implement this to return the criterion.
      Specified by:
        `getCriterion` in class `ModelCriterion`
      Returns:

    - #### getLabel

          public java.lang.String getLabel()

      Description copied from class: `ModelCriterion`
      Implement this to return a string representation.
      Specified by:
        `getLabel` in class `ModelCriterion`
      Returns:

    - #### isAllowAttacks

          public boolean isAllowAttacks()

      Returns:

    - #### parse

          public void parse(ModelCriterion criterion,
                   boolean _default)

      Description copied from class: `ModelCriterion`
      Parse
      Specified by:
        `parse` in class `ModelCriterion`
        `_default` - Defines whether the model represents a typical parameter configuration for the criterion

    - #### setAllowAttacks

          public void setAllowAttacks(boolean allowAttacks)

      Defines whether we allow attacks to happen
      Parameters:
        `allowAttacks` -

    - #### setAttackerModel

          public void setAttackerModel(ModelProfitabilityCriterion.AttackerModel attackerModel)

      Defines the attacker model
      Parameters:
        `attackerModel` -

    - #### toString

          public java.lang.String toString()

      Description copied from class: `ModelCriterion`
      Implement this to return a string representation.
      Specified by:
        `toString` in class `ModelCriterion`