

from . import AWSObject, Tags


VALID_CONNECTION_PROVIDERTYPE = ('Bitbucket')


def validate_connection_providertype(connection_providertype):
    """Validate ProviderType for Connection"""

    if connection_providertype not in VALID_CONNECTION_PROVIDERTYPE:
        raise ValueError("Connection ProviderType must be one of: %s" %
                         ", ".join(VALID_CONNECTION_PROVIDERTYPE))
    return connection_providertype


class Connection(AWSObject):
    resource_type = "AWS::CodeStarConnections::Connection"

    props = {
        'ConnectionName': (basestring, True),
        'ProviderType': (validate_connection_providertype, True),
        'Tags': (Tags, False),
    }



from . import AWSObject, Tags


VALID_CONNECTION_PROVIDERTYPE = ('Bitbucket')


def validate_connection_providertype(connection_providertype):
    """Validate ProviderType for Connection"""

    if connection_providertype not in VALID_CONNECTION_PROVIDERTYPE:
        raise ValueError("Connection ProviderType must be one of: %s" %
                         ", ".join(VALID_CONNECTION_PROVIDERTYPE))
    return connection_providertype


class Connection(AWSObject):
    resource_type = "AWS::CodeStarConnections::Connection"

    props = {
        'ConnectionName': (basestring, True),
        'HostArn': (basestring, False),
        'ProviderType': (validate_connection_providertype, True),
        'Tags': (Tags, False),
    }

Update CodeStarConnections::Connection per 2020-07-23 update
Update CodeStarConnections::Connection per 2020-07-23 update

  
  
  from . import AWSObject, Tags
  
  
  VALID_CONNECTION_PROVIDERTYPE = ('Bitbucket')
  
  
  def validate_connection_providertype(connection_providertype):
      """Validate ProviderType for Connection"""
  
      if connection_providertype not in VALID_CONNECTION_PROVIDERTYPE:
          raise ValueError("Connection ProviderType must be one of: %s" %
                           ", ".join(VALID_CONNECTION_PROVIDERTYPE))
      return connection_providertype
  
  
  class Connection(AWSObject):
      resource_type = "AWS::CodeStarConnections::Connection"
  
      props = {
          'ConnectionName': (basestring, True),
+         'HostArn': (basestring, False),
          'ProviderType': (validate_connection_providertype, True),
          'Tags': (Tags, False),
      }
  
Update CodeStarConnections::Connection per 2020-07-23 update
## Code Before:


from . import AWSObject, Tags


VALID_CONNECTION_PROVIDERTYPE = ('Bitbucket')


def validate_connection_providertype(connection_providertype):
    """Validate ProviderType for Connection"""

    if connection_providertype not in VALID_CONNECTION_PROVIDERTYPE:
        raise ValueError("Connection ProviderType must be one of: %s" %
                         ", ".join(VALID_CONNECTION_PROVIDERTYPE))
    return connection_providertype


class Connection(AWSObject):
    resource_type = "AWS::CodeStarConnections::Connection"

    props = {
        'ConnectionName': (basestring, True),
        'ProviderType': (validate_connection_providertype, True),
        'Tags': (Tags, False),
    }

## Instruction:
Update CodeStarConnections::Connection per 2020-07-23 update
## Code After:


from . import AWSObject, Tags


VALID_CONNECTION_PROVIDERTYPE = ('Bitbucket')


def validate_connection_providertype(connection_providertype):
    """Validate ProviderType for Connection"""

    if connection_providertype not in VALID_CONNECTION_PROVIDERTYPE:
        raise ValueError("Connection ProviderType must be one of: %s" %
                         ", ".join(VALID_CONNECTION_PROVIDERTYPE))
    return connection_providertype


class Connection(AWSObject):
    resource_type = "AWS::CodeStarConnections::Connection"

    props = {
        'ConnectionName': (basestring, True),
        'HostArn': (basestring, False),
        'ProviderType': (validate_connection_providertype, True),
        'Tags': (Tags, False),
    }
