# coding: utf-8

"""
AmgMember.py

 The Clear BSD License

 Copyright (c) – 2016, NetApp, Inc. All rights reserved.

 Redistribution and use in source and binary forms, with or without modification, are permitted (subject to the limitations in the disclaimer below) provided that the following conditions are met:

 * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.

 * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

 * Neither the name of NetApp, Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

 NO EXPRESS OR IMPLIED LICENSES TO ANY PARTY'S PATENT RIGHTS ARE GRANTED BY THIS LICENSE. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
"""

from pprint import pformat
from six import iteritems


class AmgMember(object):
    """
    NOTE: This class is auto generated by the swagger code generator program.
    Do not edit the class manually.
    """
    def __init__(self):
        """
        AmgMember - a model defined in Swagger

        :param dict swaggerTypes: The key is attribute name
                                  and the value is attribute type.
        :param dict attributeMap: The key is attribute name
                                  and the value is json key in definition.
        """
        self.swagger_types = {
            'member_ref': 'str',  # (required parameter)
            'mirror_group': 'str',  # (required parameter)
            'local_volume': 'str',  # (required parameter)
            'remote_volume': 'str',  # (required parameter)
            'member_state': 'str',  # (required parameter)
            'last_recovery_point_time': 'int',  # (required parameter)
            'over_utilization_warn_threshold': 'bool',  # (required parameter)
            'mirrored_local_capacity': 'int',  # (required parameter)
            'repository_volume': 'str',  # (required parameter)
            'world_wide_name': 'str',  # (required parameter)
            'volume_handle': 'int',  # (required parameter)
            'repository_full': 'bool',  # (required parameter)
            'local_volume_name': 'str',  
            'remote_volume_name': 'str',  
            'remote_volume_info': 'RemoteVolume',  
            'remote_target_wwn': 'str',  
            'remote_target_name': 'str',  
            'remote_target_id': 'str',  
            'total_size_in_bytes': 'int',  
            'media_scan': 'VolumeMediaScanParams',  
            'id': 'str'
        }

        self.attribute_map = {
            'member_ref': 'memberRef',  # (required parameter)
            'mirror_group': 'mirrorGroup',  # (required parameter)
            'local_volume': 'localVolume',  # (required parameter)
            'remote_volume': 'remoteVolume',  # (required parameter)
            'member_state': 'memberState',  # (required parameter)
            'last_recovery_point_time': 'lastRecoveryPointTime',  # (required parameter)
            'over_utilization_warn_threshold': 'overUtilizationWarnThreshold',  # (required parameter)
            'mirrored_local_capacity': 'mirroredLocalCapacity',  # (required parameter)
            'repository_volume': 'repositoryVolume',  # (required parameter)
            'world_wide_name': 'worldWideName',  # (required parameter)
            'volume_handle': 'volumeHandle',  # (required parameter)
            'repository_full': 'repositoryFull',  # (required parameter)
            'local_volume_name': 'localVolumeName',  
            'remote_volume_name': 'remoteVolumeName',  
            'remote_volume_info': 'remoteVolumeInfo',  
            'remote_target_wwn': 'remoteTargetWwn',  
            'remote_target_name': 'remoteTargetName',  
            'remote_target_id': 'remoteTargetId',  
            'total_size_in_bytes': 'totalSizeInBytes',  
            'media_scan': 'mediaScan',  
            'id': 'id'
        }

        self._member_ref = None
        self._mirror_group = None
        self._local_volume = None
        self._remote_volume = None
        self._member_state = None
        self._last_recovery_point_time = None
        self._over_utilization_warn_threshold = None
        self._mirrored_local_capacity = None
        self._repository_volume = None
        self._world_wide_name = None
        self._volume_handle = None
        self._repository_full = None
        self._local_volume_name = None
        self._remote_volume_name = None
        self._remote_volume_info = None
        self._remote_target_wwn = None
        self._remote_target_name = None
        self._remote_target_id = None
        self._total_size_in_bytes = None
        self._media_scan = None
        self._id = None

    @property
    def member_ref(self):
        """
        Gets the member_ref of this AmgMember.
        The reference (key) for the group member.

        :return: The member_ref of this AmgMember.
        :rtype: str
        :required/optional: required
        """
        return self._member_ref

    @member_ref.setter
    def member_ref(self, member_ref):
        """
        Sets the member_ref of this AmgMember.
        The reference (key) for the group member.

        :param member_ref: The member_ref of this AmgMember.
        :type: str
        """
        self._member_ref = member_ref

    @property
    def mirror_group(self):
        """
        Gets the mirror_group of this AmgMember.
        The AMG with which this member is associated.

        :return: The mirror_group of this AmgMember.
        :rtype: str
        :required/optional: required
        """
        return self._mirror_group

    @mirror_group.setter
    def mirror_group(self, mirror_group):
        """
        Sets the mirror_group of this AmgMember.
        The AMG with which this member is associated.

        :param mirror_group: The mirror_group of this AmgMember.
        :type: str
        """
        self._mirror_group = mirror_group

    @property
    def local_volume(self):
        """
        Gets the local_volume of this AmgMember.
        The local volume for this mirror. This is the volume being mirrored if the AMG role is primary, otherwise this is the target of mirror synchronization.

        :return: The local_volume of this AmgMember.
        :rtype: str
        :required/optional: required
        """
        return self._local_volume

    @local_volume.setter
    def local_volume(self, local_volume):
        """
        Sets the local_volume of this AmgMember.
        The local volume for this mirror. This is the volume being mirrored if the AMG role is primary, otherwise this is the target of mirror synchronization.

        :param local_volume: The local_volume of this AmgMember.
        :type: str
        """
        self._local_volume = local_volume

    @property
    def remote_volume(self):
        """
        Gets the remote_volume of this AmgMember.
        The remote volume. This is the target of mirror synchronization on the remote array if the AMG role is primary, otherwise this is the volume on the remote array that is being mirrored.

        :return: The remote_volume of this AmgMember.
        :rtype: str
        :required/optional: required
        """
        return self._remote_volume

    @remote_volume.setter
    def remote_volume(self, remote_volume):
        """
        Sets the remote_volume of this AmgMember.
        The remote volume. This is the target of mirror synchronization on the remote array if the AMG role is primary, otherwise this is the volume on the remote array that is being mirrored.

        :param remote_volume: The remote_volume of this AmgMember.
        :type: str
        """
        self._remote_volume = remote_volume

    @property
    def member_state(self):
        """
        Gets the member_state of this AmgMember.
        The state of this mirror relationship (as known by this array).

        :return: The member_state of this AmgMember.
        :rtype: str
        :required/optional: required
        """
        return self._member_state

    @member_state.setter
    def member_state(self, member_state):
        """
        Sets the member_state of this AmgMember.
        The state of this mirror relationship (as known by this array).

        :param member_state: The member_state of this AmgMember.
        :type: str
        """
        allowed_values = ["unknown", "initialSync", "optimal", "failed", "incomplete", "orphan", "stopped", "__UNDEFINED"]
        if member_state not in allowed_values:
            raise ValueError(
                "Invalid value for `member_state`, must be one of {0}"
                .format(allowed_values)
            )
        self._member_state = member_state

    @property
    def last_recovery_point_time(self):
        """
        Gets the last_recovery_point_time of this AmgMember.
        The timestamp, represented in seconds since midnight GMT on January 1, 1970, of the last recovery point PiT on secondary. If no recovery point image exists, the value of this field will be ARVM_NO_RECOVERY_POINT_TIMESTAMP.

        :return: The last_recovery_point_time of this AmgMember.
        :rtype: int
        :required/optional: required
        """
        return self._last_recovery_point_time

    @last_recovery_point_time.setter
    def last_recovery_point_time(self, last_recovery_point_time):
        """
        Sets the last_recovery_point_time of this AmgMember.
        The timestamp, represented in seconds since midnight GMT on January 1, 1970, of the last recovery point PiT on secondary. If no recovery point image exists, the value of this field will be ARVM_NO_RECOVERY_POINT_TIMESTAMP.

        :param last_recovery_point_time: The last_recovery_point_time of this AmgMember.
        :type: int
        """
        self._last_recovery_point_time = last_recovery_point_time

    @property
    def over_utilization_warn_threshold(self):
        """
        Gets the over_utilization_warn_threshold of this AmgMember.
        If true, the repository capacity utilized is over the warning threshold.

        :return: The over_utilization_warn_threshold of this AmgMember.
        :rtype: bool
        :required/optional: required
        """
        return self._over_utilization_warn_threshold

    @over_utilization_warn_threshold.setter
    def over_utilization_warn_threshold(self, over_utilization_warn_threshold):
        """
        Sets the over_utilization_warn_threshold of this AmgMember.
        If true, the repository capacity utilized is over the warning threshold.

        :param over_utilization_warn_threshold: The over_utilization_warn_threshold of this AmgMember.
        :type: bool
        """
        self._over_utilization_warn_threshold = over_utilization_warn_threshold

    @property
    def mirrored_local_capacity(self):
        """
        Gets the mirrored_local_capacity of this AmgMember.
        The current local volume capacity that is being mirrored. This will be less than the actual local volume capacity if we have not yet reached a point where the next PiT can be taken and delta-logs resized (and until that point the expanded local capacity will not be opened up to host writes).

        :return: The mirrored_local_capacity of this AmgMember.
        :rtype: int
        :required/optional: required
        """
        return self._mirrored_local_capacity

    @mirrored_local_capacity.setter
    def mirrored_local_capacity(self, mirrored_local_capacity):
        """
        Sets the mirrored_local_capacity of this AmgMember.
        The current local volume capacity that is being mirrored. This will be less than the actual local volume capacity if we have not yet reached a point where the next PiT can be taken and delta-logs resized (and until that point the expanded local capacity will not be opened up to host writes).

        :param mirrored_local_capacity: The mirrored_local_capacity of this AmgMember.
        :type: int
        """
        self._mirrored_local_capacity = mirrored_local_capacity

    @property
    def repository_volume(self):
        """
        Gets the repository_volume of this AmgMember.
        The metadata volume (Copy-on-Write / DeltaLog Repository) for this mirror.

        :return: The repository_volume of this AmgMember.
        :rtype: str
        :required/optional: required
        """
        return self._repository_volume

    @repository_volume.setter
    def repository_volume(self, repository_volume):
        """
        Sets the repository_volume of this AmgMember.
        The metadata volume (Copy-on-Write / DeltaLog Repository) for this mirror.

        :param repository_volume: The repository_volume of this AmgMember.
        :type: str
        """
        self._repository_volume = repository_volume

    @property
    def world_wide_name(self):
        """
        Gets the world_wide_name of this AmgMember.
        The WWN of the async mirror proxy.

        :return: The world_wide_name of this AmgMember.
        :rtype: str
        :required/optional: required
        """
        return self._world_wide_name

    @world_wide_name.setter
    def world_wide_name(self, world_wide_name):
        """
        Sets the world_wide_name of this AmgMember.
        The WWN of the async mirror proxy.

        :param world_wide_name: The world_wide_name of this AmgMember.
        :type: str
        """
        self._world_wide_name = world_wide_name

    @property
    def volume_handle(self):
        """
        Gets the volume_handle of this AmgMember.
        The SSID of the async mirror proxy.

        :return: The volume_handle of this AmgMember.
        :rtype: int
        :required/optional: required
        """
        return self._volume_handle

    @volume_handle.setter
    def volume_handle(self, volume_handle):
        """
        Sets the volume_handle of this AmgMember.
        The SSID of the async mirror proxy.

        :param volume_handle: The volume_handle of this AmgMember.
        :type: int
        """
        self._volume_handle = volume_handle

    @property
    def repository_full(self):
        """
        Gets the repository_full of this AmgMember.
        If true, the repository is full (100% of available capacity utilized).

        :return: The repository_full of this AmgMember.
        :rtype: bool
        :required/optional: required
        """
        return self._repository_full

    @repository_full.setter
    def repository_full(self, repository_full):
        """
        Sets the repository_full of this AmgMember.
        If true, the repository is full (100% of available capacity utilized).

        :param repository_full: The repository_full of this AmgMember.
        :type: bool
        """
        self._repository_full = repository_full

    @property
    def local_volume_name(self):
        """
        Gets the local_volume_name of this AmgMember.
        The label of the source volume on the local StorageSystem.

        :return: The local_volume_name of this AmgMember.
        :rtype: str
        :required/optional: optional
        """
        return self._local_volume_name

    @local_volume_name.setter
    def local_volume_name(self, local_volume_name):
        """
        Sets the local_volume_name of this AmgMember.
        The label of the source volume on the local StorageSystem.

        :param local_volume_name: The local_volume_name of this AmgMember.
        :type: str
        """
        self._local_volume_name = local_volume_name

    @property
    def remote_volume_name(self):
        """
        Gets the remote_volume_name of this AmgMember.
        The label of the remote target volume.

        :return: The remote_volume_name of this AmgMember.
        :rtype: str
        :required/optional: optional
        """
        return self._remote_volume_name

    @remote_volume_name.setter
    def remote_volume_name(self, remote_volume_name):
        """
        Sets the remote_volume_name of this AmgMember.
        The label of the remote target volume.

        :param remote_volume_name: The remote_volume_name of this AmgMember.
        :type: str
        """
        self._remote_volume_name = remote_volume_name

    @property
    def remote_volume_info(self):
        """
        Gets the remote_volume_info of this AmgMember.
        Detailed information on the remote volume.

        :return: The remote_volume_info of this AmgMember.
        :rtype: RemoteVolume
        :required/optional: optional
        """
        return self._remote_volume_info

    @remote_volume_info.setter
    def remote_volume_info(self, remote_volume_info):
        """
        Sets the remote_volume_info of this AmgMember.
        Detailed information on the remote volume.

        :param remote_volume_info: The remote_volume_info of this AmgMember.
        :type: RemoteVolume
        """
        self._remote_volume_info = remote_volume_info

    @property
    def remote_target_wwn(self):
        """
        Gets the remote_target_wwn of this AmgMember.
        The WWN of the target array in the mirroring relationship. This field may not be immediately available after an AMG is created.

        :return: The remote_target_wwn of this AmgMember.
        :rtype: str
        :required/optional: optional
        """
        return self._remote_target_wwn

    @remote_target_wwn.setter
    def remote_target_wwn(self, remote_target_wwn):
        """
        Sets the remote_target_wwn of this AmgMember.
        The WWN of the target array in the mirroring relationship. This field may not be immediately available after an AMG is created.

        :param remote_target_wwn: The remote_target_wwn of this AmgMember.
        :type: str
        """
        self._remote_target_wwn = remote_target_wwn

    @property
    def remote_target_name(self):
        """
        Gets the remote_target_name of this AmgMember.
        The user label of the target array in the mirroring relationship. This field may not be immediately available after an AMG is created, and will not be available in embedded mode.

        :return: The remote_target_name of this AmgMember.
        :rtype: str
        :required/optional: optional
        """
        return self._remote_target_name

    @remote_target_name.setter
    def remote_target_name(self, remote_target_name):
        """
        Sets the remote_target_name of this AmgMember.
        The user label of the target array in the mirroring relationship. This field may not be immediately available after an AMG is created, and will not be available in embedded mode.

        :param remote_target_name: The remote_target_name of this AmgMember.
        :type: str
        """
        self._remote_target_name = remote_target_name

    @property
    def remote_target_id(self):
        """
        Gets the remote_target_id of this AmgMember.
        The id of the target array in the mirroring relationship. This field may not be immediately available after an AMG is created, and will not be available in embedded mode.

        :return: The remote_target_id of this AmgMember.
        :rtype: str
        :required/optional: optional
        """
        return self._remote_target_id

    @remote_target_id.setter
    def remote_target_id(self, remote_target_id):
        """
        Sets the remote_target_id of this AmgMember.
        The id of the target array in the mirroring relationship. This field may not be immediately available after an AMG is created, and will not be available in embedded mode.

        :param remote_target_id: The remote_target_id of this AmgMember.
        :type: str
        """
        self._remote_target_id = remote_target_id

    @property
    def total_size_in_bytes(self):
        """
        Gets the total_size_in_bytes of this AmgMember.
        The capacity of the underlying repository volume in bytes.

        :return: The total_size_in_bytes of this AmgMember.
        :rtype: int
        :required/optional: optional
        """
        return self._total_size_in_bytes

    @total_size_in_bytes.setter
    def total_size_in_bytes(self, total_size_in_bytes):
        """
        Sets the total_size_in_bytes of this AmgMember.
        The capacity of the underlying repository volume in bytes.

        :param total_size_in_bytes: The total_size_in_bytes of this AmgMember.
        :type: int
        """
        self._total_size_in_bytes = total_size_in_bytes

    @property
    def media_scan(self):
        """
        Gets the media_scan of this AmgMember.
        The volume-specific media scan settings currently in effect for the repository volume.

        :return: The media_scan of this AmgMember.
        :rtype: VolumeMediaScanParams
        :required/optional: optional
        """
        return self._media_scan

    @media_scan.setter
    def media_scan(self, media_scan):
        """
        Sets the media_scan of this AmgMember.
        The volume-specific media scan settings currently in effect for the repository volume.

        :param media_scan: The media_scan of this AmgMember.
        :type: VolumeMediaScanParams
        """
        self._media_scan = media_scan

    @property
    def id(self):
        """
        Gets the id of this AmgMember.


        :return: The id of this AmgMember.
        :rtype: str
        :required/optional: optional
        """
        return self._id

    @id.setter
    def id(self, id):
        """
        Sets the id of this AmgMember.


        :param id: The id of this AmgMember.
        :type: str
        """
        self._id = id

    def to_dict(self):
        """
        Returns the model properties as a dict
        """
        result = {}

        for attr, _ in iteritems(self.swagger_types):
            value = getattr(self, attr)
            if isinstance(value, list):
                result[attr] = list(map(
                    lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
                    value
                ))
            elif hasattr(value, "to_dict"):
                result[attr] = value.to_dict()
            elif isinstance(value, dict):
                result[attr] = dict(map(
                    lambda item: (item[0], item[1].to_dict())
                    if hasattr(item[1], "to_dict") else item,
                    value.items()
                ))
            else:
                result[attr] = value

        return result

    def to_str(self):
        """
        Returns the string representation of the model
        """
        return pformat(self.to_dict())

    def __repr__(self):
        """
        For `print` and `pprint`
        """
        if self is None:
           return None
        return self.to_str()

    def __eq__(self, other):
        """
        Returns true if both objects are equal
        """
        if self is None or other is None:
            return None
        return self.__dict__ == other.__dict__

    def __ne__(self, other):
        """
        Returns true if both objects are not equal
        """
        return not self == other

