# HierarchyWizardModelAbstract (ARX GUI Documentation)

org.deidentifier.arx.gui.view.impl.wizard

## Class HierarchyWizardModelAbstract<T>

- java.lang.Object
- - org.deidentifier.arx.gui.view.impl.wizard.HierarchyWizardModelAbstract<T>

- Type Parameters:
    `T` -
  Direct Known Subclasses:
    HierarchyWizardModelGrouping, HierarchyWizardModelRedaction

      public abstract class HierarchyWizardModelAbstract<T>
      extends java.lang.Object

  An abstract base model for all builders.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected java.lang.String[]` | `data` Var.
    `protected java.lang.String` | `error` Var.
    `protected int[]` | `groupsizes` Var.
    `protected AttributeType.Hierarchy` | `hierarchy` Var.
    `protected HierarchyWizard.HierarchyWizardView` | `view` Var.
    `protected boolean` | `visible` Var.

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `HierarchyWizardModelAbstract(java.lang.String[] data)` Creates a new instance.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected abstract void` | `build()` Implement this to run the builder.
    `abstract HierarchyBuilder<T>` | `getBuilder(boolean serializable)` Returns the builder currently configured.
    `java.lang.String[]` | `getData()` Returns the data.
    `java.lang.String` | `getError()` Returns an error message, null if everything is ok.
    `int[]` | `getGroups()` Returns the sizes of the resulting groups.
    `AttributeType.Hierarchy` | `getHierarchy()` Returns the resulting hierarchy.
    `abstract void` | `parse(HierarchyBuilder<T> builder)` Parses a builder and updates the model accordingly.
    `void` | `setView(HierarchyWizard.HierarchyWizardView view)` Sets the according view.
    `protected void` | `setVisible(boolean visible)` Set visible.
    `void` | `update()` Updates the resulting hierarchy and the view.
    `abstract void` | `updateUI(HierarchyWizard.HierarchyWizardView sender)` Updates all UI components apart from the sender

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

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

- - ### Field Detail

    - #### data

          protected final java.lang.String[] data

      Var.

    - #### groupsizes

          protected int[] groupsizes

      Var.

    - #### hierarchy

          protected AttributeType.Hierarchy hierarchy

      Var.

    - #### error

          protected java.lang.String error

      Var.

    - #### view

          protected HierarchyWizard.HierarchyWizardView view

      Var.

    - #### visible

          protected boolean visible

      Var.

  - ### Constructor Detail

    - #### HierarchyWizardModelAbstract

          public HierarchyWizardModelAbstract(java.lang.String[] data)

      Creates a new instance.
      Parameters:
        `data` -

  - ### Method Detail

    - #### getBuilder

          public abstract HierarchyBuilder<T> getBuilder(boolean serializable)
                                                  throws java.lang.Exception

      Returns the builder currently configured.
      Parameters:
        `serializable` -
      Returns:
      Throws:
        `java.lang.Exception`

    - #### getData

          public java.lang.String[] getData()

      Returns the data.
      Returns:

    - #### getError

          public java.lang.String getError()

      Returns an error message, null if everything is ok.
      Returns:

    - #### getGroups

          public int[] getGroups()

      Returns the sizes of the resulting groups.
      Returns:

    - #### getHierarchy

          public AttributeType.Hierarchy getHierarchy()

      Returns the resulting hierarchy.
      Returns:

    - #### parse

          public abstract void parse(HierarchyBuilder<T> builder)

      Parses a builder and updates the model accordingly.
      Parameters:
        `builder` -

    - #### setView

          public void setView(HierarchyWizard.HierarchyWizardView view)

      Sets the according view.
      Parameters:
        `view` -

    - #### update

          public void update()

      Updates the resulting hierarchy and the view.

    - #### updateUI

          public abstract void updateUI(HierarchyWizard.HierarchyWizardView sender)

      Updates all UI components apart from the sender

    - #### build

          protected abstract void build()

      Implement this to run the builder.

    - #### setVisible

          protected void setVisible(boolean visible)

      Set visible.
      Parameters:
        `visible` -