Questions tagged [table-data-gateway]

Design pattern in which an object acts as a gateway to a database table.

6 questions
137
votes
5 answers

What is the difference between the Data Mapper, Table Data Gateway (Gateway), Data Access Object (DAO) and Repository patterns?

I'm trying to brush up on my design pattern skills, and I'm curious what are the differences between these patterns? All of them seem like they are the same thing - encapsulate the database logic for a specific entity so the calling code has no…
Wayne Molina
  • 17,811
  • 24
  • 93
  • 156
1
vote
0 answers

'Generic' Data Gateway pattern - Python

I work with a variety of data sources (Salesforce, Google, CSVs, other REST APIs etc.) and types (tabular, key-value) and have a number of different Python wrappers that expose these feeds. These are difficult to maintain, and at present, don't…
Connor Goddard
  • 565
  • 4
  • 13
0
votes
1 answer

Add icon as a vuetify table data

This is my vuetify table This is the template of the code ----template-----------
0
votes
0 answers

Creation of db abstraction layer using php

I am trying to create simple database abstraction layer. I read a lot of articles about Active Record and Table Data Gateway and right now I am very confused. I think that I understand some theory (small) about them but not how exactly to implement…
0
votes
1 answer

Zend\Stdlib\Hydrator\ClassMethods extract() returning a null array

I previously asked a question about how to efficiently do an insert\update with a tablegateway and was informed of Zend\Stdlib\Hydrator\ClassMethods as in this code from the docs: public function saveAlbum(Album $album) { $data = array( …
red888
  • 18,164
  • 26
  • 123
  • 237
0
votes
2 answers

Doing inserts with zend 2's tableGateway

I using zf2's tableGateway and I'm unsure of the design it leads to. Here is the canonical example of how to use zf2's tableGateway to do an insert (this from the docs): public function saveAlbum(Album $album) { $data = array( …
red888
  • 18,164
  • 26
  • 123
  • 237