com.h3c.sdn.team

## Interface TeamConfigurationService

-     public interface TeamConfigurationService

  Service to configure a team.

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `List<TeamActionStatus<Boolean>>` | `create(TeamConfig<SystemConfigReq> teamConfig, boolean externalRequest)` Creates a team.
    `List<TeamActionStatus<Boolean>>` | `destroy(boolean externalRequest)` Destroys/deletes a team.
    `TeamConfig<SystemConfigReq>` | `get()` Gets cached team configuration
    `TeamConfig<SystemConfigRsp>` | `getStatus(boolean externalRequest)` Gets team status from all reachable nodes
    `void` | `triggerElection()` Trigger leader election.

- - ### Method Detail

    - #### create

          List<TeamActionStatus<Boolean>> create(TeamConfig<SystemConfigReq> teamConfig,
                                               boolean externalRequest)
                                                 throws DuplicateDataException,
                                                        IllegalArgumentException,
                                                        CreateException

      Creates a team.
      Parameters:
        `teamConfig` - team configuration
        `externalRequest` - `true` if the request was initiated by the user and thus it has to be propagated to all the members in the team (external request); `false` if the request comes from another member which is propagating the action (internal request).
      Returns:
        `TeamActionStatus` list
      Throws:
        `DuplicateDataException` - if a team exists with the same configuration
        `IllegalArgumentException` - if the team configuration is invalid
        `CreateException` - general exception to denote creation failures

    - #### destroy

          List<TeamActionStatus<Boolean>> destroy(boolean externalRequest)
                                                  throws NotFoundException

      Destroys/deletes a team.
      Parameters:
        `externalRequest` - `true` if the request was initiated by the user and thus it has to be propagated to all the members in the team (external request); `false` if the request comes from another member which is propagating the action (internal request).
      Returns:
        `TeamActionStatus` list
      Throws:
        `NotFoundException` - if the team does not exist

    - #### get

          TeamConfig<SystemConfigReq> get()
                                          throws NotFoundException

      Gets cached team configuration
      Returns:
        cached team configuration
      Throws:
        `NotFoundException` - if get fails

    - #### getStatus

          TeamConfig<SystemConfigRsp> getStatus(boolean externalRequest)
                                                throws NotFoundException

      Gets team status from all reachable nodes
      Parameters:
        `externalRequest` - `true` if the request was initiated by the user and thus it has to be propagated to all the members in the team (external request); `false` if the request comes from another member which is propagating the action (internal request).
      Returns:
        team configuration
      Throws:
        `NotFoundException` - if get fails

    - #### triggerElection

          void triggerElection()
                               throws NotFoundException

      Trigger leader election.
      Throws:
        `NotFoundException` - if the team does not exist

Copyright © 2014. All Rights Reserved.