Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Move isolated type declarations to separate folder
- Loading branch information
Showing
32 changed files
with
146 additions
and
153 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
module CheckedAddress where | ||
module Types.CheckedAddress where | ||
|
||
import SharedTypes | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
module CustomerInfo where | ||
module Types.CustomerInfo where | ||
|
||
import String50 | ||
import Types.String50 | ||
import SharedTypes | ||
import PersonalName | ||
import Types.PersonalName | ||
|
||
data CustomerInfo = CustomerInfo { | ||
name :: PersonalName.PersonalName, | ||
name :: PersonalName, | ||
emailAddress :: EmailAddress | ||
} deriving (Eq, Show) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
module KilogramQuantity( | ||
module Types.KilogramQuantity( | ||
KilogramQuantity, create, value | ||
) where | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
module OrderAcknowledgment where | ||
module Types.OrderAcknowledgment where | ||
|
||
import SharedTypes | ||
|
||
|
8 changes: 4 additions & 4 deletions
8
src/OrderAcknowledgmentSent.hs → src/Types/OrderAcknowledgmentSent.hs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
module OrderAcknowledgmentSent where | ||
module Types.OrderAcknowledgmentSent where | ||
|
||
import SharedTypes | ||
import qualified OrderId | ||
import Types.OrderId | ||
|
||
data OrderAcknowledgmentSent = OrderAcknowledgmentSent { | ||
orderId :: OrderId.OrderId, | ||
orderId :: OrderId, | ||
emailAddress :: EmailAddress | ||
} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
module OrderId( | ||
module Types.OrderId( | ||
OrderId, create, value | ||
) where | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
module Types.OrderLine where | ||
|
||
import SharedTypes | ||
import Types.OrderLineId | ||
import Types.OrderQuantity | ||
import Types.ProductCode | ||
import Types.OrderId | ||
|
||
data OrderLine = OrderLine { | ||
orderLineId :: OrderLineId, | ||
orderId :: OrderId, | ||
productCode :: ProductCode, | ||
quantity :: OrderQuantity | ||
} deriving (Eq, Show) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
module OrderLineId( | ||
module Types.OrderLineId( | ||
OrderLineId, create, value | ||
) where | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
module Types.Payment where | ||
|
||
newtype CheckNumber = CheckNumber Int deriving (Show) | ||
newtype CardNumber = CardNumber String deriving (Show) | ||
newtype PaymentAmount = PaymentAmount Double | ||
|
||
data PaymentMethod = Cash | Check CheckNumber | Card CardNumber | ||
data Currency = EUR | USD | ||
|
||
data Payment = Payment { | ||
amount :: PaymentAmount, | ||
currency :: Currency, | ||
method :: PaymentMethod | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
module Price( | ||
module Types.Price( | ||
Price(Price), create, multiply | ||
) where | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
module String50( | ||
module Types.String50( | ||
String50, string50, value | ||
) where | ||
|
||
|
Oops, something went wrong.