public TableEntityPath Bind(IReadOnlyDictionary <string, object> bindingData)
        {
            string tableName    = _tableNameTemplate.Bind(bindingData);
            string partitionKey = _partitionKeyTemplate.Bind(bindingData);
            string rowKey       = _rowKeyTemplate.Bind(bindingData);

            TableClientHelpers.ValidateAzureTableName(tableName);
            TableClientHelpers.ValidateAzureTableKeyValue(partitionKey);
            TableClientHelpers.ValidateAzureTableKeyValue(rowKey);
            return(new TableEntityPath(tableName, partitionKey, rowKey));
        }
        public Task <IValueProvider> BindAsync(object value, ValueBindingContext context)
        {
            TableEntityContext entityContext = null;

            if (!_converter.TryConvert(value, out entityContext))
            {
                throw new InvalidOperationException("Unable to convert value to TableEntityContext.");
            }

            TableClientHelpers.ValidateAzureTableKeyValue(entityContext.PartitionKey);
            TableClientHelpers.ValidateAzureTableKeyValue(entityContext.RowKey);
            return(BindEntityAsync(entityContext, context));
        }
        public static IBindableTableEntityPath Create(string tableNamePattern, string partitionKeyPattern,
                                                      string rowKeyPattern)
        {
            BindingTemplate tableNameTemplate    = BindingTemplate.FromString(tableNamePattern);
            BindingTemplate partitionKeyTemplate = BindingTemplate.FromString(partitionKeyPattern);
            BindingTemplate rowKeyTemplate       = BindingTemplate.FromString(rowKeyPattern);

            if (tableNameTemplate.HasParameters ||
                partitionKeyTemplate.HasParameters ||
                rowKeyTemplate.HasParameters)
            {
                return(new ParameterizedTableEntityPath(tableNameTemplate, partitionKeyTemplate, rowKeyTemplate));
            }

            TableClientHelpers.ValidateAzureTableName(tableNamePattern);
            TableClientHelpers.ValidateAzureTableKeyValue(partitionKeyPattern);
            TableClientHelpers.ValidateAzureTableKeyValue(rowKeyPattern);
            TableEntityPath innerPath = new TableEntityPath(tableNamePattern, partitionKeyPattern, rowKeyPattern);

            return(new BoundTableEntityPath(innerPath));
        }