def METHOD_NAME(self, account_id, resource_type=None):
    expr = conditions.Key('AccountId').eq(account_id)
    if resource_type == "security-group":
        expr = expr & conditions.Key('ResourceId').between('sg-', 'vpc-')
    elif resource_type == "vpc":
        expr = expr & conditions.Key('ResourceId').begins_with('vpc-')
    results = self.table.scan(FilterExpression=expr)
    return results['Items']