-
-
Notifications
You must be signed in to change notification settings - Fork 81
/
Copy pathexample-input.cml
73 lines (61 loc) · 1.75 KB
/
example-input.cml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
/* This is an example input file for the 'Split Bounded Context by Features' refactoring and shows a small part of the insurance example. */
ContextMap {
contains PolicyManagementContext
}
/* With a right-click on the 'PolicyManagementContext' bounded context you can execute the 'Split Bounded Context by Features' refactoring.
* It will split the existing bounded context and group the two aggregates of the 'CreateOffer4Customer' use case together. The 'Contract'
* aggregate used by the 'UpdateContract' use case will be separated.
*/
BoundedContext PolicyManagementContext implements PolicyManagementDomain {
type = FEATURE
domainVisionStatement = "This bounded context manages the contracts and policies of the customers."
responsibilities = "Offers, Contracts, Policies"
implementationTechnology = "Java, Spring App"
Aggregate Offers {
useCases = CreateOffer4Customer
Entity Offer {
aggregateRoot
int offerId
Customer client
- List<Product> products
BigDecimal price
}
}
Aggregate Products {
useCases = CreateOffer4Customer
Entity Product {
aggregateRoot
- ProductId identifier
String productName
}
ValueObject ProductId {
int productId key
}
}
Aggregate Contract {
useCases = UpdateContract
Entity Contract {
aggregateRoot
- ContractId identifier
Customer client
- List<Product> products
}
ValueObject ContractId {
int contractId key
}
Entity Policy {
int policyNr
- Contract contract
BigDecimal price
}
}
}
/* Domain & Subdomain Definitions */
Domain InsuranceDomain {
Subdomain PolicyManagementDomain {
type = CORE_DOMAIN
domainVisionStatement = "Subdomain managing contracts and policies."
}
}
UseCase UpdateContract
UseCase CreateOffer4Customer