Skip to content

Commit

Permalink
chapter 02: creating another mandatory method for the encoders: prepa…
Browse files Browse the repository at this point in the history
…reData
  • Loading branch information
devcorpio committed Mar 30, 2019
1 parent b06e05d commit bdb6adf
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 0 deletions.
5 changes: 5 additions & 0 deletions chapter-02-the-open-closed-principle/refactor/jsonEncoder.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,13 @@ function jsonEncoder() {
// something here...
}

function prepareData() {
// something here
}

return {
encode,
prepareData,
};
}

Expand Down
5 changes: 5 additions & 0 deletions chapter-02-the-open-closed-principle/refactor/xmlEncoder.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,13 @@ function xmlEncoder() {
// something here...
}

function prepareData() {
// something here
}

return {
encode,
prepareData,
};
}

Expand Down
5 changes: 5 additions & 0 deletions chapter-02-the-open-closed-principle/refactor/yamlEncoder.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,13 @@ function yamlEncoder() {
// something here...
}

function prepareData() {
// something here
}

return {
encode,
prepareData,
};
}

Expand Down

0 comments on commit bdb6adf

Please sign in to comment.