Class List Method List File List

# Module: Yast::LdapWizardsInclude

Defined in:
  ../../src/include/ldap/wizards.rb

## Instance Method Summary (collapse)

- - (Object) initialize_ldap_wizards(include_target)
- - (Object) LdapAutoSequence

  Whole configuration of ldap-client but without reading and writing.

- - (Object) LdapSequence

  Whole configuration of ldap-client.

- - (Object) MainSequence

  Main workflow of the ldap-client configuration.

## Instance Method Details

### - (`Object`) initialize_ldap_wizards(include_target)

    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    # File '../../src/include/ldap/wizards.rb', line 30

    def initialize_ldap_wizards(include_target)
      Yast.import "UI"

      textdomain "ldap-client"

      Yast.import "Sequencer"
      Yast.import "Wizard"
      Yast.import "Label"
      Yast.import "Stage"

      Yast.include include_target, "ldap/ui.rb"
    end

### - (`Object`) LdapAutoSequence

Whole configuration of ldap-client but without reading and writing. For use with autoinstallation.

Returns:

- sequence result

    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    # File '../../src/include/ldap/wizards.rb', line 88

    def LdapAutoSequence
      # dialog label
      caption = _("LDAP Client Configuration")
      # label (init dialog)
      contents = Label(_("Initializing..."))

      Wizard.CreateDialog
      Wizard.SetDesktopTitleAndIcon("ldap")
      Wizard.SetContentsButtons(
        caption,
        contents,
        "",
        Label.BackButton,
        Label.NextButton
      )

      ret = MainSequence()

      UI.CloseDialog
      Convert.to_symbol(ret)
    end

### - (`Object`) LdapSequence

Whole configuration of ldap-client

Returns:

- sequence result

    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    130
    131
    132
    133
    134
    135
    136
    137
    138
    # File '../../src/include/ldap/wizards.rb', line 112

    def LdapSequence
      aliases = {
        "read"  => [lambda { ReadDialog() }, true],
        "main"  => lambda { MainSequence() },
        "write" => [lambda { WriteDialog() }, true]
      }

      sequence = {
        "ws_start" => "read",
        "read"     => { :abort => :abort, :next => "main" },
        "main"     => { :abort => :abort, :next => "write" },
        "write"    => { :abort => :abort, :next => :next }
      }

      if Stage.cont
        Wizard.CreateDialog
      else
        Wizard.OpenNextBackDialog
        Wizard.HideAbortButton
      end
      Wizard.SetDesktopTitleAndIcon("ldap")

      ret = Sequencer.Run(aliases, sequence)

      UI.CloseDialog
      Convert.to_symbol(ret)
    end

### - (`Object`) MainSequence

Main workflow of the ldap-client configuration

Returns:

- sequence result

    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    # File '../../src/include/ldap/wizards.rb', line 45

    def MainSequence
      aliases = {
        "ldap"      => lambda { LdapDialog() },
        "advanced"  => lambda { AdvancedConfigurationDialog() },
        "configure" => lambda { ModuleConfigurationDialog() },
        "read_ldap" => [lambda { LDAPReadDialog() }, true]
      }

      sequence = {
        "ws_start"  => "ldap",
        "ldap"      => {
          :abort    => :abort,
          :cancel   => :abort,
          :advanced => "advanced",
          :next     => :next
        },
        "read_ldap" => {
          :abort  => :abort,
          :cancel => :abort,
          :next   => "configure",
          :skip   => "ldap"
        },
        "advanced"  => {
          :abort     => :abort,
          :cancel    => :abort,
          :next      => "ldap",
          :configure => "read_ldap"
        },
        "configure" => {
          :abort  => :abort,
          :cancel => :abort,
          :next   => "advanced"
        }
      }

      ret = Sequencer.Run(aliases, sequence)

      deep_copy(ret)
    end