Added DataMapper UML

This commit is contained in:
John Webb
2014-07-29 09:51:18 -05:00
parent 287e242e83
commit 86a2171e89
4 changed files with 31 additions and 0 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.8 KiB

View File

@@ -0,0 +1 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="96pt" style="width:197px;height:96px;background:#000000;" version="1.1" viewBox="0 0 197 96" width="197pt"><defs/><g><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="164" x="0" y="13.5352">... (skipping 20 lines) ...</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="176" x="20" y="30.0234">+mapObject(array $row)</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="5" x="0" y="46.5117">}</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="0" x="5" y="63"/><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="32" x="0" y="79.4883">User</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="0" x="5" y="95.9766"/><text fill="#FF0000" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="94" x="5" y="95.9766">Syntax Error?</text></g></svg>

After

Width:  |  Height:  |  Size: 1.4 KiB

View File

@@ -0,0 +1,26 @@
@startuml
class User {
protected $userId
protected $username
protected $email
+__construct($id = null, $username = null, $email = null)
+getUserId()
+setUserID($userId)
+getUsername()
+setUsername($username)
+getEmail()
+setEmail($email)
}
class UserMapper {
protected $adapter
+__construct(DBAL $dbLayer)
+save(User $user)
+findById($id)
+findAll()
+mapObject(array $row)
}
User
UserMapper
@enduml