Amazon.DynamoDBv2.DataModel.Utils.GetSingleDDBAttribute C# (CSharp) Method

GetSingleDDBAttribute() private static method

private static GetSingleDDBAttribute ( object attributes ) : DynamoDBAttribute
attributes object
return DynamoDBAttribute
        private static DynamoDBAttribute GetSingleDDBAttribute(object[] attributes)
        {
            if (attributes.Length == 0)
                return null;
            if (attributes.Length == 1)
                return (attributes[0] as DynamoDBAttribute);
            throw new InvalidOperationException("Cannot have multiple DynamoDBAttributes on a single member");
        }