Guest User

Untitled

a guest
Jan 23rd, 2018
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. private string _environment = "dev";
  2. private IEnumerable<Television> Load()
  3. {
  4. var db = new PocoDynamo(_client);
  5. var q = db.FromQuery<Television>(q => q.Id == 1);
  6. Decorate(q, _environment);
  7. return q.Exec();
  8. }
  9. private void Decorate<TPoco>(QueryExpression<TPoco> query, string decorator)
  10. {
  11. query.TableName = $"{decorator}-{query.TableName}";
  12. }
Add Comment
Please, Sign In to add comment