├── main-kata ├── src │ ├── test │ │ ├── resources │ │ │ ├── testdata │ │ │ │ ├── data_ObjectFromScratch.txt │ │ │ │ ├── data_Customer.txt │ │ │ │ ├── data_Tasks.txt │ │ │ │ ├── data_Person.txt │ │ │ │ ├── data_CustomersAndAccounts.txt │ │ │ │ ├── data_Employee.txt │ │ │ │ ├── data_AllTypes.txt │ │ │ │ └── data_CustomersAccountsBalances.txt │ │ │ ├── log4j.properties │ │ │ └── testconfig │ │ │ │ └── TestMithraRuntimeConfig.xml │ │ └── java │ │ │ └── kata │ │ │ └── test │ │ │ └── AbstractMithraTest.java │ └── main │ │ ├── java │ │ └── kata │ │ │ ├── domain │ │ │ ├── AllTypesDatabaseObject.java │ │ │ ├── EmployeeDatabaseObject.java │ │ │ ├── TaskDatabaseObject.java │ │ │ ├── PersonDatabaseObject.java │ │ │ ├── CustomerDatabaseObject.java │ │ │ ├── AccountBalanceDatabaseObject.java │ │ │ ├── CustomerAccountDatabaseObject.java │ │ │ ├── ObjectSequenceDatabaseObject.java │ │ │ ├── AllTypes.java │ │ │ ├── CustomerAccount.java │ │ │ ├── AllTypesList.java │ │ │ ├── TaskList.java │ │ │ ├── PersonList.java │ │ │ ├── CustomerList.java │ │ │ ├── AccountBalanceList.java │ │ │ ├── ObjectSequenceList.java │ │ │ ├── CustomerAccountList.java │ │ │ ├── EmployeeList.java │ │ │ ├── ObjectSequence.java │ │ │ ├── Task.java │ │ │ ├── Customer.java │ │ │ ├── AccountBalance.java │ │ │ ├── Employee.java │ │ │ └── Person.java │ │ │ └── util │ │ │ ├── ObjectSequenceObjectFactory.java │ │ │ └── TimestampProvider.java │ │ └── reladomoxml │ │ ├── MithraTestAppClassList.xml │ │ ├── ObjectSequence.xml │ │ ├── CustomerAccount.xml │ │ ├── AccountBalance.xml │ │ ├── Person.xml │ │ ├── Employee.xml │ │ ├── Customer.xml │ │ └── Task.xml ├── presentation │ ├── reladomoKata │ │ ├── MTLoader.png │ │ ├── AuditOnly1.png │ │ ├── AuditOnly2.png │ │ ├── AuditOnly3.png │ │ ├── PersonUML.png │ │ ├── PersonXml.png │ │ ├── BiTemporal1.png │ │ ├── BiTemporal2.png │ │ ├── BiTemporal3.png │ │ ├── Relationships1.png │ │ ├── Relationships2.png │ │ ├── BiTemporalGraph1.png │ │ ├── BiTemporalGraph2.png │ │ ├── BiTemporalGraph3.png │ │ ├── BiTemporalGraph4.png │ │ ├── BiTemporalGraph5.png │ │ ├── BiTemporalGraph6.png │ │ ├── BiTemporalGraph7.png │ │ ├── MithraBuildTargets.png │ │ ├── RelationshipsDDLs.png │ │ ├── MithraDDLGeneration.png │ │ ├── MithraClassGeneration.png │ │ ├── MithraGenerationDiagram.png │ │ ├── MithraXMLAutoComplete.png │ │ └── MithraXMLDocumentation.png │ └── customization │ │ ├── html.xsl │ │ └── fo.xsl └── main-kata.iml ├── reladomo-tour ├── .gitignore ├── tour-doc │ ├── src │ │ ├── docbook │ │ │ ├── auditonly-intro │ │ │ │ ├── auditonly-1.png │ │ │ │ ├── auditonly-2.png │ │ │ │ ├── auditonly-31.png │ │ │ │ ├── auditonly-32.png │ │ │ │ ├── auditonly-41.png │ │ │ │ └── auditonly-42.png │ │ │ ├── bitemporal-intro │ │ │ │ ├── bitemporal-1.png │ │ │ │ ├── bitemporal-2.png │ │ │ │ ├── bitemporal-31.png │ │ │ │ ├── bitemporal-32.png │ │ │ │ ├── bitemporal-41.png │ │ │ │ └── bitemporal-42.png │ │ │ ├── domain-modeling │ │ │ │ ├── simplebank-domain.png │ │ │ │ ├── simplebank-generated-ddl.png │ │ │ │ └── SimpleBank-generated-nongenerated.png │ │ │ └── guide.xml │ │ └── customization │ │ │ └── html.xsl │ └── tour-doc.iml ├── tour-examples │ ├── simple-bank │ │ └── src │ │ │ ├── test │ │ │ └── resources │ │ │ │ ├── testconfig │ │ │ │ ├── SimpleBankTestData.txt │ │ │ │ └── SimpleBankTestRuntimeConfiguration.xml │ │ │ │ └── logback.xml │ │ │ └── main │ │ │ ├── java │ │ │ └── simplebank │ │ │ │ ├── domain │ │ │ │ ├── CustomerDatabaseObject.java │ │ │ │ ├── CustomerAccountDatabaseObject.java │ │ │ │ ├── CustomerAccount.java │ │ │ │ ├── CustomerList.java │ │ │ │ ├── Customer.java │ │ │ │ └── CustomerAccountList.java │ │ │ │ ├── serialization │ │ │ │ └── SimpleBankJacksonObjectMapperProvider.java │ │ │ │ ├── app │ │ │ │ └── SimpleBankApp.java │ │ │ │ └── web │ │ │ │ └── SimpleBankServer.java │ │ │ ├── reladomoxml │ │ │ ├── SimpleBankClassList.xml │ │ │ ├── SimpleBankRuntimeConfiguration.xml │ │ │ ├── CustomerAccount.xml │ │ │ └── Customer.xml │ │ │ └── resources │ │ │ └── logback.xml │ ├── tour-examples.iml │ ├── auditonly-bank │ │ └── src │ │ │ ├── test │ │ │ └── resources │ │ │ │ ├── testconfig │ │ │ │ ├── AuditOnlyChainingInActionTestData.txt │ │ │ │ └── AuditOnlyBankTestRuntimeConfiguration.xml │ │ │ │ └── logback.xml │ │ │ └── main │ │ │ ├── java │ │ │ └── auditonlybank │ │ │ │ ├── domain │ │ │ │ ├── CustomerDatabaseObject.java │ │ │ │ ├── CustomerAccountDatabaseObject.java │ │ │ │ ├── Customer.java │ │ │ │ ├── CustomerList.java │ │ │ │ ├── CustomerAccount.java │ │ │ │ └── CustomerAccountList.java │ │ │ │ └── util │ │ │ │ └── DateUtils.java │ │ │ ├── reladomoxml │ │ │ ├── AuditOnlyBankClassList.xml │ │ │ ├── AuditOnlyBankRuntimeConfiguration.xml │ │ │ ├── CustomerAccount.xml │ │ │ └── Customer.xml │ │ │ └── resources │ │ │ └── logback.xml │ ├── bitemporal-bank │ │ └── src │ │ │ ├── main │ │ │ ├── java │ │ │ │ └── bitemporalbank │ │ │ │ │ ├── domain │ │ │ │ │ ├── CustomerDatabaseObject.java │ │ │ │ │ ├── CustomerAccountDatabaseObject.java │ │ │ │ │ ├── Customer.java │ │ │ │ │ ├── CustomerList.java │ │ │ │ │ ├── CustomerAccount.java │ │ │ │ │ └── CustomerAccountList.java │ │ │ │ │ ├── serialization │ │ │ │ │ └── BitemporalBankJacksonObjectMapperProvider.java │ │ │ │ │ ├── util │ │ │ │ │ └── DateUtils.java │ │ │ │ │ ├── app │ │ │ │ │ └── BitemporalBankApp.java │ │ │ │ │ └── web │ │ │ │ │ └── BitemporalBankServer.java │ │ │ ├── reladomoxml │ │ │ │ ├── BitemporalBankClassList.xml │ │ │ │ ├── BitemporalBankRuntimeConfiguration.xml │ │ │ │ ├── CustomerAccount.xml │ │ │ │ └── Customer.xml │ │ │ └── resources │ │ │ │ └── logback.xml │ │ │ └── test │ │ │ └── resources │ │ │ ├── testconfig │ │ │ ├── BitemporalBankTestData.txt │ │ │ └── BitemporalBankTestRuntimeConfiguration.xml │ │ │ └── logback.xml │ └── pom.xml └── reladomo-tour.iml ├── mini-kata ├── presentation │ ├── miniKata │ │ ├── PersonUML.png │ │ ├── PersonXML.png │ │ ├── mtloader.png │ │ ├── mtloader2.png │ │ ├── ReladomoGen.png │ │ ├── audittable1.png │ │ ├── audittable2.png │ │ ├── GeneratedClasses.png │ │ └── CompanyRelationship.png │ └── customization │ │ ├── html.xsl │ │ └── fo.xsl ├── src │ ├── main │ │ ├── java │ │ │ └── kata │ │ │ │ ├── domain │ │ │ │ ├── PetDatabaseObject.java │ │ │ │ ├── PersonDatabaseObject.java │ │ │ │ ├── PetTypeDatabaseObject.java │ │ │ │ ├── ObjectSequenceDatabaseObject.java │ │ │ │ ├── PetTypeList.java │ │ │ │ ├── PetType.java │ │ │ │ ├── ObjectSequenceList.java │ │ │ │ ├── PersonList.java │ │ │ │ ├── PetList.java │ │ │ │ ├── ObjectSequence.java │ │ │ │ ├── Pet.java │ │ │ │ └── Person.java │ │ │ │ └── util │ │ │ │ └── ObjectSequenceObjectFactory.java │ │ └── reladomoxml │ │ │ ├── MithraTestAppClassList.xml │ │ │ ├── PetType.xml │ │ │ ├── ObjectSequence.xml │ │ │ ├── Pet.xml │ │ │ └── Person.xml │ └── test │ │ ├── resources │ │ ├── logback.xml │ │ ├── testconfig │ │ │ └── TestMithraRuntimeConfig.xml │ │ └── testdata │ │ │ └── data_AllTypes.txt │ │ └── java │ │ └── kata │ │ └── test │ │ └── AbstractMithraTest.java └── mini-kata.iml ├── .gitignore ├── .idea ├── vcs.xml ├── checkstyle-idea.xml ├── modules.xml ├── encodings.xml ├── reladomo-kata.iml ├── copyright │ ├── Apache.xml │ └── profiles_settings.xml ├── runConfigurations │ ├── All_in_Main_Kata.xml │ └── All_in_Mini_Kata.xml └── compiler.xml ├── .travis.yml ├── dco └── yu_matsubayashi.dco └── NOTICE.txt /main-kata/src/test/resources/testdata/data_ObjectFromScratch.txt: -------------------------------------------------------------------------------- 1 | // Your test data goes here! 2 | -------------------------------------------------------------------------------- /reladomo-tour/.gitignore: -------------------------------------------------------------------------------- 1 | **/target/** 2 | .idea 3 | **/.DS_Store 4 | tour-doc/src/docbook/images 5 | -------------------------------------------------------------------------------- /mini-kata/presentation/miniKata/PersonUML.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/mini-kata/presentation/miniKata/PersonUML.png -------------------------------------------------------------------------------- /mini-kata/presentation/miniKata/PersonXML.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/mini-kata/presentation/miniKata/PersonXML.png -------------------------------------------------------------------------------- /mini-kata/presentation/miniKata/mtloader.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/mini-kata/presentation/miniKata/mtloader.png -------------------------------------------------------------------------------- /mini-kata/presentation/miniKata/mtloader2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/mini-kata/presentation/miniKata/mtloader2.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/MTLoader.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/MTLoader.png -------------------------------------------------------------------------------- /mini-kata/presentation/miniKata/ReladomoGen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/mini-kata/presentation/miniKata/ReladomoGen.png -------------------------------------------------------------------------------- /mini-kata/presentation/miniKata/audittable1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/mini-kata/presentation/miniKata/audittable1.png -------------------------------------------------------------------------------- /mini-kata/presentation/miniKata/audittable2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/mini-kata/presentation/miniKata/audittable2.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/AuditOnly1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/AuditOnly1.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/AuditOnly2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/AuditOnly2.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/AuditOnly3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/AuditOnly3.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/PersonUML.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/PersonUML.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/PersonXml.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/PersonXml.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/BiTemporal1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/BiTemporal1.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/BiTemporal2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/BiTemporal2.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/BiTemporal3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/BiTemporal3.png -------------------------------------------------------------------------------- /mini-kata/presentation/miniKata/GeneratedClasses.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/mini-kata/presentation/miniKata/GeneratedClasses.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/Relationships1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/Relationships1.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/Relationships2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/Relationships2.png -------------------------------------------------------------------------------- /mini-kata/presentation/miniKata/CompanyRelationship.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/mini-kata/presentation/miniKata/CompanyRelationship.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/BiTemporalGraph1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/BiTemporalGraph1.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/BiTemporalGraph2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/BiTemporalGraph2.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/BiTemporalGraph3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/BiTemporalGraph3.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/BiTemporalGraph4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/BiTemporalGraph4.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/BiTemporalGraph5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/BiTemporalGraph5.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/BiTemporalGraph6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/BiTemporalGraph6.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/BiTemporalGraph7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/BiTemporalGraph7.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/MithraBuildTargets.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/MithraBuildTargets.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/RelationshipsDDLs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/RelationshipsDDLs.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/MithraDDLGeneration.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/MithraDDLGeneration.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/MithraClassGeneration.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/MithraClassGeneration.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/MithraGenerationDiagram.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/MithraGenerationDiagram.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/MithraXMLAutoComplete.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/MithraXMLAutoComplete.png -------------------------------------------------------------------------------- /main-kata/presentation/reladomoKata/MithraXMLDocumentation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/main-kata/presentation/reladomoKata/MithraXMLDocumentation.png -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/auditonly-intro/auditonly-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/reladomo-tour/tour-doc/src/docbook/auditonly-intro/auditonly-1.png -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/auditonly-intro/auditonly-2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/reladomo-tour/tour-doc/src/docbook/auditonly-intro/auditonly-2.png -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/auditonly-intro/auditonly-31.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/reladomo-tour/tour-doc/src/docbook/auditonly-intro/auditonly-31.png -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/auditonly-intro/auditonly-32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/reladomo-tour/tour-doc/src/docbook/auditonly-intro/auditonly-32.png -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/auditonly-intro/auditonly-41.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/reladomo-tour/tour-doc/src/docbook/auditonly-intro/auditonly-41.png -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/auditonly-intro/auditonly-42.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/reladomo-tour/tour-doc/src/docbook/auditonly-intro/auditonly-42.png -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/bitemporal-intro/bitemporal-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/reladomo-tour/tour-doc/src/docbook/bitemporal-intro/bitemporal-1.png -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/bitemporal-intro/bitemporal-2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/reladomo-tour/tour-doc/src/docbook/bitemporal-intro/bitemporal-2.png -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | main-kata/target/** 2 | mini-kata/target/** 3 | main-kata/.idea/** 4 | mini-kata/.idea/** 5 | .idea/workspace.xml 6 | .idea/misc.xml 7 | .idea/codeStyleSettings.xml 8 | .idea/libraries/** 9 | -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/bitemporal-intro/bitemporal-31.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/reladomo-tour/tour-doc/src/docbook/bitemporal-intro/bitemporal-31.png -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/bitemporal-intro/bitemporal-32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/reladomo-tour/tour-doc/src/docbook/bitemporal-intro/bitemporal-32.png -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/bitemporal-intro/bitemporal-41.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/reladomo-tour/tour-doc/src/docbook/bitemporal-intro/bitemporal-41.png -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/bitemporal-intro/bitemporal-42.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/reladomo-tour/tour-doc/src/docbook/bitemporal-intro/bitemporal-42.png -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/domain-modeling/simplebank-domain.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/reladomo-tour/tour-doc/src/docbook/domain-modeling/simplebank-domain.png -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/domain-modeling/simplebank-generated-ddl.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/reladomo-tour/tour-doc/src/docbook/domain-modeling/simplebank-generated-ddl.png -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/domain-modeling/SimpleBank-generated-nongenerated.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/goldmansachs/reladomo-kata/HEAD/reladomo-tour/tour-doc/src/docbook/domain-modeling/SimpleBank-generated-nongenerated.png -------------------------------------------------------------------------------- /main-kata/src/test/resources/testdata/data_Customer.txt: -------------------------------------------------------------------------------- 1 | class kata.domain.Customer 2 | customerId , name , country 3 | 0 , "Hiro Tanaka" , "JPN" 4 | 1 , "John Smith" , "USA" 5 | 2 , "Yusuke Sato" , "JPN" 6 | 3 , "Yuki Suzuki" , "JPN" 7 | 4 , "Yuri Clark " , "JPN" 8 | -------------------------------------------------------------------------------- /.idea/checkstyle-idea.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 10 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/test/resources/testconfig/SimpleBankTestData.txt: -------------------------------------------------------------------------------- 1 | class simplebank.domain.Customer 2 | customerId, firstName, lastName, country 3 | 1, "mickey", "mouse", "USA" 4 | 2, "minnie", "mouse", "USA" 5 | 3, "peter", "pan", "Neverland" 6 | 7 | class simplebank.domain.CustomerAccount 8 | accountId, customerId, accountName, accountType, balance 9 | 100, 1, "mickey mouse club", "savings", 5000 10 | 101, 2, "retirement", "savings", 10000 11 | 102, 3, "fun stuff", "checking", 3000 12 | 13 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: java 2 | sudo: false 3 | 4 | before_install: echo "MAVEN_OPTS='-Dmaven.repo.local=$HOME/.m2/repository -Xmx1g -Dorg.slf4j.simpleLogger.showDateTime=true -Dorg.slf4j.simpleLogger.dateTimeFormat=HH:mm:ss:SSS'" > ~/.mavenrc 5 | install: 6 | - 7 | 8 | matrix: 9 | fast_finish: true 10 | include: 11 | - jdk: oraclejdk8 12 | env: 13 | - DESC="compile" 14 | - CMD="mvn install -DskipTests=true -Dmaven.javadoc.skip=true -B -V" 15 | 16 | script: eval $CMD 17 | 18 | cache: 19 | directories: 20 | - ~/.m2 21 | -------------------------------------------------------------------------------- /.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /dco/yu_matsubayashi.dco: -------------------------------------------------------------------------------- 1 | 1) I, Yu Matsubayashi, certify that all work committed with the commit message 2 | "covered by: yu_matsubayashi.dco" is my original work and I own the copyright 3 | to this work. I agree to contribute this code under the Apache 2.0 license. 4 | 5 | 2) I understand and agree all contribution including all personal 6 | information I submit with it is maintained indefinitely and may be 7 | redistributed consistent with the open source license(s) involved. 8 | 9 | This certification is effective for all code contributed from 2017-03-21 to 9999-01-01. 10 | -------------------------------------------------------------------------------- /reladomo-tour/reladomo-tour.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/tour-doc.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/tour-examples.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/auditonly-bank/src/test/resources/testconfig/AuditOnlyChainingInActionTestData.txt: -------------------------------------------------------------------------------- 1 | class auditonlybank.domain.Customer 2 | customerId,firstName,lastName,country,processingDateFrom,processingDateTo 3 | 2,"minnie","mouse","usa","2017-01-01 00:00:00.000","9999-12-01 23:59:00.000" 4 | 5 | class auditonlybank.domain.CustomerAccount 6 | accountId,customerId,accountName,accountType,balance,processingDateFrom,processingDateTo 7 | 5678,2,"retirement","savings",100,"2017-01-01 00:00:00.000","2017-01-20 00:00:00.000" 8 | 5678,2,"retirement","savings",300,"2017-01-20 00:00:00.000","2017-01-25 00:00:00.000" 9 | 5678,2,"retirement","savings",350,"2017-01-25 00:00:00.000","9999-12-01 23:59:00.000" -------------------------------------------------------------------------------- /main-kata/src/test/resources/testdata/data_Tasks.txt: -------------------------------------------------------------------------------- 1 | class kata.domain.Task 2 | taskId , name , status , processingDateFrom , processingDateTo 3 | 1 , "Build Bridge" , "In Design", "1965-01-01 06:00:00.0", "1967-01-01 11:30:22.0" 4 | 1 , "Build Bridge" , "Building" , "1967-01-01 11:30:22.0", "1969-12-30 23:59:00.0" 5 | 1 , "Build Bridge" , "Restarted", "1990-01-01 06:00:00.0", "1992-12-01 23:59:00.0" 6 | 2 , "Dam River" , "Damming" , "1991-01-01 06:00:00.0", "1996-12-01 23:59:00.0" 7 | 2 , "Dam River" , "Restarted", "2008-01-01 06:00:00.0", "9999-12-01 23:59:00.0" 8 | 3 , "Colonize Moon", "In Design", "2007-01-01 06:00:00.0", "9999-12-01 23:59:00.0" 9 | 10 | -------------------------------------------------------------------------------- /mini-kata/src/main/java/kata/domain/PetDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class PetDatabaseObject extends PetDatabaseObjectAbstract 20 | { 21 | } 22 | -------------------------------------------------------------------------------- /mini-kata/src/main/java/kata/domain/PersonDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class PersonDatabaseObject extends PersonDatabaseObjectAbstract 20 | { 21 | } 22 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/AllTypesDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class AllTypesDatabaseObject extends AllTypesDatabaseObjectAbstract 20 | { 21 | } 22 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/EmployeeDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class EmployeeDatabaseObject extends EmployeeDatabaseObjectAbstract 20 | { 21 | } 22 | -------------------------------------------------------------------------------- /mini-kata/src/main/java/kata/domain/PetTypeDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class PetTypeDatabaseObject extends PetTypeDatabaseObjectAbstract 20 | { 21 | } 22 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/TaskDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class TaskDatabaseObject 20 | extends TaskDatabaseObjectAbstract 21 | { 22 | } 23 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/PersonDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class PersonDatabaseObject 20 | extends PersonDatabaseObjectAbstract 21 | { 22 | } 23 | -------------------------------------------------------------------------------- /main-kata/src/test/resources/testdata/data_Person.txt: -------------------------------------------------------------------------------- 1 | class kata.domain.Person 2 | personId, name , country, age 3 | 0 , "Hiro Tanaka" , "JPN" , 24 4 | 1 , "John Smith" , "USA" , 36 5 | 2 , "Yusuke Sato" , "JPN" , 11 6 | 3 , "Yuki Suzuki" , "JPN" , 100 7 | 4 , "Yuri Clark" , "JPN" , 37 8 | 5 , "Clark Kent" , "USA" , 38 9 | 6 , "Kent Beck" , "USA" , 52 10 | 7 , "Bob Martin" , "USA" , 55 11 | 8 , "Ada Lovelace" , "UK" , 24 12 | 9 , "Douglas Adams" , "UK" , 42 13 | 10 , "de Rothschild" , "DE" , 41 14 | 11 , "Devon Koch" , "DE" , 41 15 | 12 , "Chuckie Egg" , "AU" , 12 16 | 13 , "Donkey Kong" , "AU" , 13 17 | 14 , "Baby Finster" , "AU" , 5 18 | 15 , "Jango Fett" , "MA" , 25 19 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/CustomerDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class CustomerDatabaseObject 20 | extends CustomerDatabaseObjectAbstract 21 | { 22 | } 23 | -------------------------------------------------------------------------------- /mini-kata/src/main/java/kata/domain/ObjectSequenceDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class ObjectSequenceDatabaseObject extends ObjectSequenceDatabaseObjectAbstract 20 | { 21 | } 22 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/main/java/simplebank/domain/CustomerDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package simplebank.domain; 18 | 19 | public class CustomerDatabaseObject extends CustomerDatabaseObjectAbstract 20 | { 21 | } 22 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/AccountBalanceDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class AccountBalanceDatabaseObject 20 | extends AccountBalanceDatabaseObjectAbstract 21 | { 22 | } 23 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/CustomerAccountDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class CustomerAccountDatabaseObject 20 | extends CustomerAccountDatabaseObjectAbstract 21 | { 22 | } 23 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/ObjectSequenceDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class ObjectSequenceDatabaseObject 20 | extends ObjectSequenceDatabaseObjectAbstract 21 | { 22 | } 23 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/auditonly-bank/src/main/java/auditonlybank/domain/CustomerDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package auditonlybank.domain; 18 | 19 | public class CustomerDatabaseObject extends CustomerDatabaseObjectAbstract 20 | { 21 | } 22 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/main/java/bitemporalbank/domain/CustomerDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package bitemporalbank.domain; 18 | 19 | public class CustomerDatabaseObject extends CustomerDatabaseObjectAbstract 20 | { 21 | } 22 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/main/java/simplebank/domain/CustomerAccountDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package simplebank.domain; 18 | 19 | public class CustomerAccountDatabaseObject extends CustomerAccountDatabaseObjectAbstract 20 | { 21 | } 22 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/auditonly-bank/src/main/java/auditonlybank/domain/CustomerAccountDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package auditonlybank.domain; 18 | 19 | public class CustomerAccountDatabaseObject extends CustomerAccountDatabaseObjectAbstract 20 | { 21 | } 22 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/main/java/bitemporalbank/domain/CustomerAccountDatabaseObject.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package bitemporalbank.domain; 18 | 19 | public class CustomerAccountDatabaseObject extends CustomerAccountDatabaseObjectAbstract 20 | { 21 | } 22 | -------------------------------------------------------------------------------- /.idea/encodings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /.idea/reladomo-kata.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /main-kata/src/test/resources/testdata/data_CustomersAndAccounts.txt: -------------------------------------------------------------------------------- 1 | class kata.domain.Customer 2 | customerId , name , country 3 | 1 , "John Smith" , "USA" 4 | 2 , "Yusuke Sato" , "JPN" 5 | 3 , "Yuki Suzuki" , "JPN" 6 | 4 , "Lisbeth Salander", "SE" 7 | 5 , "Mikael Blomkvist", "SE" 8 | 6 , "Gertrude Smith" , "UK" 9 | 10 | 11 | 12 | 13 | class kata.domain.CustomerAccount 14 | accountId, customerId, accountName , accountType 15 | 100 , 1 , "Smith Running Account" , "Running" 16 | 200 , 1 , "John's Saving Account" , "Savings" 17 | 300 , 1 , "John's Saving Account 2", "Savings" 18 | 400 , 2 , "My Account" , "Savings" 19 | 500 , 3 , "My Account" , "Running" 20 | 600 , 999 , "No customer Account" , "Virtual" 21 | 700 , 6 , "Non-virtual Account" , "Kitty" 22 | 23 | -------------------------------------------------------------------------------- /.idea/copyright/Apache.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 9 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/AllTypes.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class AllTypes extends AllTypesAbstract 20 | { 21 | public AllTypes() 22 | { 23 | super(); 24 | // You must not modify this constructor. Mithra calls this internally. 25 | // You can call this constructor. You can also add new constructors. 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/CustomerAccount.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class CustomerAccount 20 | extends CustomerAccountAbstract 21 | { 22 | public CustomerAccount() 23 | { 24 | super(); 25 | // You must not modify this constructor. Mithra calls this internally. 26 | // You can call this constructor. You can also add new constructors. 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/main/reladomoxml/SimpleBankClassList.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/auditonly-bank/src/main/reladomoxml/AuditOnlyBankClassList.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/main/reladomoxml/BitemporalBankClassList.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/main/java/simplebank/domain/CustomerAccount.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package simplebank.domain; 18 | 19 | public class CustomerAccount extends CustomerAccountAbstract 20 | { 21 | public CustomerAccount() 22 | { 23 | super(); 24 | // You must not modify this constructor. Mithra calls this internally. 25 | // You can call this constructor. You can also add new constructors. 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /mini-kata/src/main/reladomoxml/MithraTestAppClassList.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/AllTypesList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | import com.gs.fw.finder.Operation; 19 | import java.util.*; 20 | 21 | public class AllTypesList extends AllTypesListAbstract 22 | { 23 | public AllTypesList() 24 | { 25 | super(); 26 | } 27 | 28 | public AllTypesList(int initialSize) 29 | { 30 | super(initialSize); 31 | } 32 | 33 | public AllTypesList(Collection c) 34 | { 35 | super(c); 36 | } 37 | 38 | public AllTypesList(Operation operation) 39 | { 40 | super(operation); 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/TaskList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | import java.util.Collection; 21 | 22 | public class TaskList 23 | extends TaskListAbstract 24 | { 25 | public TaskList() 26 | { 27 | super(); 28 | } 29 | 30 | public TaskList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public TaskList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public TaskList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/PersonList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | import java.util.Collection; 21 | 22 | public class PersonList 23 | extends PersonListAbstract 24 | { 25 | public PersonList() 26 | { 27 | super(); 28 | } 29 | 30 | public PersonList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public PersonList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public PersonList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/CustomerList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | import java.util.Collection; 21 | 22 | public class CustomerList 23 | extends CustomerListAbstract 24 | { 25 | public CustomerList() 26 | { 27 | super(); 28 | } 29 | 30 | public CustomerList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public CustomerList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public CustomerList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/AccountBalanceList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | import java.util.Collection; 21 | 22 | public class AccountBalanceList 23 | extends AccountBalanceListAbstract 24 | { 25 | public AccountBalanceList() 26 | { 27 | super(); 28 | } 29 | 30 | public AccountBalanceList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public AccountBalanceList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public AccountBalanceList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/ObjectSequenceList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | import java.util.Collection; 21 | 22 | public class ObjectSequenceList 23 | extends ObjectSequenceListAbstract 24 | { 25 | public ObjectSequenceList() 26 | { 27 | super(); 28 | } 29 | 30 | public ObjectSequenceList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public ObjectSequenceList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public ObjectSequenceList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /mini-kata/src/main/java/kata/domain/PetTypeList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | 21 | import java.util.Collection; 22 | 23 | public class PetTypeList extends PetTypeListAbstract 24 | { 25 | public PetTypeList() 26 | { 27 | super(); 28 | } 29 | 30 | public PetTypeList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public PetTypeList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public PetTypeList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/CustomerAccountList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | import java.util.Collection; 21 | 22 | public class CustomerAccountList 23 | extends CustomerAccountListAbstract 24 | { 25 | public CustomerAccountList() 26 | { 27 | super(); 28 | } 29 | 30 | public CustomerAccountList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public CustomerAccountList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public CustomerAccountList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/EmployeeList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | 21 | import java.util.Collection; 22 | 23 | public class EmployeeList extends EmployeeListAbstract 24 | { 25 | public EmployeeList() 26 | { 27 | super(); 28 | } 29 | 30 | public EmployeeList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public EmployeeList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public EmployeeList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/main/java/bitemporalbank/domain/Customer.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package bitemporalbank.domain; 18 | 19 | import java.sql.Timestamp; 20 | 21 | public class Customer extends CustomerAbstract 22 | { 23 | public Customer(Timestamp businessDate, Timestamp processingDate) 24 | { 25 | super(businessDate, processingDate); 26 | // You must not modify this constructor. Mithra calls this internally. 27 | // You can call this constructor. You can also add new constructors. 28 | } 29 | 30 | public Customer(Timestamp businessDate) 31 | { 32 | super(businessDate); 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/main/java/simplebank/domain/CustomerList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package simplebank.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | 21 | import java.util.Collection; 22 | 23 | public class CustomerList extends CustomerListAbstract 24 | { 25 | public CustomerList() 26 | { 27 | super(); 28 | } 29 | 30 | public CustomerList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public CustomerList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public CustomerList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/auditonly-bank/src/main/java/auditonlybank/domain/Customer.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package auditonlybank.domain; 18 | 19 | import auditonlybank.util.TimestampProvider; 20 | 21 | import java.sql.Timestamp; 22 | 23 | public class Customer extends CustomerAbstract 24 | { 25 | public Customer(Timestamp processingDate) 26 | { 27 | super(processingDate); 28 | // You must not modify this constructor. Mithra calls this internally. 29 | // You can call this constructor. You can also add new constructors. 30 | } 31 | 32 | public Customer() 33 | { 34 | this(TimestampProvider.getInfinityDate()); 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/main/reladomoxml/SimpleBankRuntimeConfiguration.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /.idea/runConfigurations/All_in_Main_Kata.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 8 | 9 | 10 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /.idea/runConfigurations/All_in_Mini_Kata.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 8 | 9 | 10 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /mini-kata/src/main/java/kata/domain/PetType.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class PetType extends PetTypeAbstract 20 | { 21 | public static final int CAT_ID = 1; 22 | public static final int DOG_ID = 2; 23 | public static final int SNAKE_ID = 3; 24 | public static final int BIRD_ID = 4; 25 | public static final int TURTLE_ID = 5; 26 | public static final int HAMSTER_ID = 6; 27 | 28 | public PetType() 29 | { 30 | super(); 31 | // You must not modify this constructor. Mithra calls this internally. 32 | // You can call this constructor. You can also add new constructors. 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/auditonly-bank/src/main/java/auditonlybank/domain/CustomerList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package auditonlybank.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | 21 | import java.util.Collection; 22 | 23 | public class CustomerList extends CustomerListAbstract 24 | { 25 | public CustomerList() 26 | { 27 | super(); 28 | } 29 | 30 | public CustomerList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public CustomerList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public CustomerList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/main/java/bitemporalbank/domain/CustomerList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package bitemporalbank.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | 21 | import java.util.Collection; 22 | 23 | public class CustomerList extends CustomerListAbstract 24 | { 25 | public CustomerList() 26 | { 27 | super(); 28 | } 29 | 30 | public CustomerList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public CustomerList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public CustomerList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/main/java/simplebank/domain/Customer.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package simplebank.domain; 18 | 19 | public class Customer extends CustomerAbstract 20 | { 21 | public Customer() 22 | { 23 | super(); 24 | // You must not modify this constructor. Mithra calls this internally. 25 | // You can call this constructor. You can also add new constructors. 26 | } 27 | 28 | public Customer(int customerId, String firstName, String lastName) 29 | { 30 | super(); 31 | this.setCustomerId(customerId); 32 | this.setFirstName(firstName); 33 | this.setLastName(lastName); 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /mini-kata/src/main/java/kata/domain/ObjectSequenceList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | 21 | import java.util.Collection; 22 | 23 | public class ObjectSequenceList extends ObjectSequenceListAbstract 24 | { 25 | public ObjectSequenceList() 26 | { 27 | super(); 28 | } 29 | 30 | public ObjectSequenceList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public ObjectSequenceList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public ObjectSequenceList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/auditonly-bank/src/main/reladomoxml/AuditOnlyBankRuntimeConfiguration.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/main/java/bitemporalbank/domain/CustomerAccount.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package bitemporalbank.domain; 18 | 19 | import java.sql.Timestamp; 20 | 21 | public class CustomerAccount extends CustomerAccountAbstract 22 | { 23 | public CustomerAccount(Timestamp businessDate, Timestamp processingDate) 24 | { 25 | super(businessDate, processingDate); 26 | // You must not modify this constructor. Mithra calls this internally. 27 | // You can call this constructor. You can also add new constructors. 28 | } 29 | 30 | public CustomerAccount(Timestamp businessDate) 31 | { 32 | super(businessDate); 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/main/reladomoxml/BitemporalBankRuntimeConfiguration.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /main-kata/src/main/reladomoxml/MithraTestAppClassList.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | -------------------------------------------------------------------------------- /mini-kata/src/main/reladomoxml/PetType.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | kata.domain 24 | PetType 25 | PET_TYPE 26 | 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/auditonly-bank/src/main/java/auditonlybank/domain/CustomerAccount.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package auditonlybank.domain; 18 | 19 | import auditonlybank.util.TimestampProvider; 20 | 21 | import java.sql.Timestamp; 22 | 23 | public class CustomerAccount extends CustomerAccountAbstract 24 | { 25 | public CustomerAccount(Timestamp processingDate) 26 | { 27 | super(processingDate); 28 | // You must not modify this constructor. Mithra calls this internally. 29 | // You can call this constructor. You can also add new constructors. 30 | } 31 | 32 | public CustomerAccount() 33 | { 34 | this(TimestampProvider.getInfinityDate()); 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /main-kata/src/main/reladomoxml/ObjectSequence.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | kata.domain 24 | ObjectSequence 25 | OBJECT_SEQUENCE 26 | 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /mini-kata/src/main/reladomoxml/ObjectSequence.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | kata.domain 24 | ObjectSequence 25 | OBJECT_SEQUENCE 26 | 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/main/java/simplebank/domain/CustomerAccountList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package simplebank.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | 21 | import java.util.Collection; 22 | 23 | public class CustomerAccountList extends CustomerAccountListAbstract 24 | { 25 | public CustomerAccountList() 26 | { 27 | super(); 28 | } 29 | 30 | public CustomerAccountList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public CustomerAccountList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public CustomerAccountList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/auditonly-bank/src/main/java/auditonlybank/domain/CustomerAccountList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package auditonlybank.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | 21 | import java.util.Collection; 22 | 23 | public class CustomerAccountList extends CustomerAccountListAbstract 24 | { 25 | public CustomerAccountList() 26 | { 27 | super(); 28 | } 29 | 30 | public CustomerAccountList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public CustomerAccountList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public CustomerAccountList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/main/java/bitemporalbank/domain/CustomerAccountList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package bitemporalbank.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | 21 | import java.util.Collection; 22 | 23 | public class CustomerAccountList extends CustomerAccountListAbstract 24 | { 25 | public CustomerAccountList() 26 | { 27 | super(); 28 | } 29 | 30 | public CustomerAccountList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public CustomerAccountList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public CustomerAccountList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/ObjectSequence.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import com.gs.fw.common.mithra.MithraSequence; 20 | 21 | public class ObjectSequence 22 | extends ObjectSequenceAbstract 23 | implements MithraSequence 24 | { 25 | public ObjectSequence() 26 | { 27 | super(); 28 | } 29 | 30 | public void setSequenceName(String sequenceName) 31 | { 32 | this.setSimulatedSequenceName(sequenceName); 33 | } 34 | 35 | public long getNextId() 36 | { 37 | return this.getNextValue(); 38 | } 39 | 40 | public void setNextId(long nextValue) 41 | { 42 | this.setNextValue(nextValue); 43 | } 44 | } 45 | 46 | -------------------------------------------------------------------------------- /NOTICE.txt: -------------------------------------------------------------------------------- 1 | Reladomo Kata 2 | Copyright 2016 Goldman Sachs 3 | Licensed under Apache 2.0 license 4 | 5 | See the licenses directory for the full text of the licenses. 6 | 7 | This product depends on (links to) the following software: 8 | 9 | Reladomo 10 | Copyright 2016 Goldman Sachs 11 | Licensed under Apache 2.0 license 12 | 13 | Eclipse Collections 14 | Copyright Eclipse Collections 15 | Licensed under Eclipse Public License - v 1.0 16 | 17 | Joda Time 18 | Copyright 2002-2016 Joda.org 19 | This product includes software developed by 20 | Joda.org (http://www.joda.org/). 21 | Licensed under Apache 2.0 license 22 | 23 | slf4j 24 | Copyright (c) 2004-2011 QOS.ch 25 | Licensed under the MIT license 26 | 27 | Apache Geronimo (JTA spec) 28 | Copyright 2003-2008 The Apache Software Foundation 29 | Licensed under Apache 2.0 license 30 | 31 | Apache Ant 32 | Copyright 1999-2016 The Apache Software Foundation 33 | Licensed under Apache 2.0 license 34 | 35 | Apache Maven Distribution 36 | Copyright 2001-2015 The Apache Software Foundation 37 | Licensed under Apache 2.0 license 38 | 39 | JUnit 40 | Copyright © 2002-2016 JUnit. 41 | The JUnit depends on Java Hamcrest (http://hamcrest.org/JavaHamcrest/). 42 | Licensed under Eclipse Public License - v 1.0 43 | 44 | H2 Database 45 | Copyright Thomas Mueller 46 | Licensed under Mozilla Public License 2.0 47 | -------------------------------------------------------------------------------- /main-kata/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright 2017 Goldman Sachs. 3 | # Licensed under the Apache License, Version 2.0 (the "License"); 4 | # you may not use this file except in compliance with the License. 5 | # You may obtain a copy of the License at 6 | # 7 | # http://www.apache.org/licenses/LICENSE-2.0 8 | # 9 | # Unless required by applicable law or agreed to in writing, 10 | # software distributed under the License is distributed on an 11 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | # KIND, either express or implied. See the License for the 13 | # specific language governing permissions and limitations 14 | # under the License. 15 | # 16 | 17 | # Console appender config: 18 | log4j.appender.Console=org.apache.log4j.ConsoleAppender 19 | log4j.appender.Console.target=System.out 20 | log4j.appender.Console.layout=org.apache.log4j.PatternLayout 21 | log4j.appender.Console.layout.ConversionPattern=%d %-5p [%t] %-17c{2} %3x - %m%n 22 | 23 | log4j.rootLogger=FATAL, Console 24 | 25 | log4j.logger.com=INFO 26 | log4j.logger.kata=DEBUG 27 | 28 | log4j.logger.com.gs.fw.common.mithra.sqllogs=DEBUG 29 | #log4j.logger.com.gs.fw.common.mithra.batch.sqllogs=DEBUG 30 | #log4j.logger.com.gs.fw.common.mithra.test.sqllogs=DEBUG 31 | #log4j.logger.com.gs.fw.common.mithra.test.multivm.SlaveVm=DEBUG 32 | 33 | log4j.logger.org=WARN 34 | -------------------------------------------------------------------------------- /mini-kata/src/test/resources/logback.xml: -------------------------------------------------------------------------------- 1 | 2 | 17 | 18 | 19 | 20 | System.out 21 | 22 | %d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /mini-kata/src/main/java/kata/domain/PersonList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2018 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | 21 | import java.util.Collection; 22 | 23 | public class PersonList extends PersonListAbstract 24 | { 25 | public PersonList() 26 | { 27 | super(); 28 | } 29 | 30 | public PersonList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public PersonList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public PersonList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | 45 | @Override 46 | public String toString() 47 | { 48 | return this.asEcList().makeString("\n"); 49 | } 50 | } 51 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/test/resources/testconfig/SimpleBankTestRuntimeConfiguration.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/Task.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import java.sql.Timestamp; 20 | 21 | public class Task extends TaskAbstract 22 | { 23 | public Task(Timestamp processingDate) 24 | { 25 | super(processingDate); 26 | // You must not modify this constructor. Mithra calls this internally. 27 | // You can call this constructor. You can also add new constructors. 28 | } 29 | 30 | @Override 31 | public String toString() 32 | { 33 | return "Task[name=" + this.getName() 34 | + "; from=" + this.getProcessingDateFrom() 35 | + "; to=" + this.getProcessingDateTo() 36 | + "; status=" + this.getStatus() + ']'; 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/auditonly-bank/src/test/resources/testconfig/AuditOnlyBankTestRuntimeConfiguration.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/test/resources/testconfig/BitemporalBankTestData.txt: -------------------------------------------------------------------------------- 1 | class bitemporalbank.domain.Customer 2 | customerId,firstName,lastName,country,businessDateFrom,businessDateTo,processingDateFrom,processingDateTo 3 | 1,"mickey","mouse","usa","2017-01-01 00:00:00.000","9999-12-01 23:59:00.000","2017-01-01 00:00:00.000","9999-12-01 23:59:00.000" 4 | 5 | class bitemporalbank.domain.CustomerAccount 6 | accountId,customerId,accountName,accountType,balance,businessDateFrom,businessDateTo,processingDateFrom,processingDateTo 7 | 12345,1,"retirement","savings",100,"2017-01-01 00:00:00.000","9999-12-01 23:59:00.000","2017-01-01 00:00:00.000","2017-01-20 00:00:00.000" 8 | 12345,1,"retirement","savings",100,"2017-01-01 00:00:00.000","2017-01-20 00:00:00.000","2017-01-20 00:00:00.000","2017-01-25 00:00:00.000" 9 | 12345,1,"retirement","savings",100,"2017-01-01 00:00:00.000","2017-01-17 00:00:00.000","2017-01-25 00:00:00.000","9999-12-01 23:59:00.000" 10 | 12345,1,"retirement","savings",150,"2017-01-17 00:00:00.000","2017-01-20 00:00:00.000","2017-01-25 00:00:00.000","9999-12-01 23:59:00.000" 11 | 12345,1,"retirement","savings",300,"2017-01-20 00:00:00.000","9999-12-01 23:59:00.000","2017-01-20 00:00:00.000","2017-01-25 00:00:00.000" 12 | 12345,1,"retirement","savings",350,"2017-01-20 00:00:00.000","9999-12-01 23:59:00.000","2017-01-25 00:00:00.000","9999-12-01 23:59:00.000" 13 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/test/resources/testconfig/BitemporalBankTestRuntimeConfiguration.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/test/resources/logback.xml: -------------------------------------------------------------------------------- 1 | 16 | 17 | 18 | 19 | 20 | 21 | %logger{0} - %msg%n 22 | 23 | 24 | 25 | 26 | 27 | 28 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/Customer.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class Customer 20 | extends CustomerAbstract 21 | { 22 | public Customer() 23 | { 24 | super(); 25 | // You must not modify this constructor. Mithra calls this internally. 26 | // You can call this constructor. You can also add new constructors. 27 | } 28 | 29 | // Added as a convenience, particularly for ExercisesCrud questions 4, 7, & 8 30 | public Customer(final String name, final String country) 31 | { 32 | this(); 33 | this.setName(name); 34 | this.setCountry(country); 35 | } 36 | 37 | @Override 38 | public String toString() 39 | { 40 | return "Customer[id=" + this.getCustomerId() + "; name=" + this.getName() + "; country=" + this.getCountry() + ']'; 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/main/resources/logback.xml: -------------------------------------------------------------------------------- 1 | 16 | 17 | 18 | 19 | 20 | 21 | %d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n 22 | 23 | 24 | 25 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/auditonly-bank/src/main/resources/logback.xml: -------------------------------------------------------------------------------- 1 | 16 | 17 | 18 | 19 | 20 | 21 | %d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n 22 | 23 | 24 | 25 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/auditonly-bank/src/test/resources/logback.xml: -------------------------------------------------------------------------------- 1 | 16 | 17 | 18 | 19 | 20 | 21 | %d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n 22 | 23 | 24 | 25 | 26 | 27 | 28 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/main/resources/logback.xml: -------------------------------------------------------------------------------- 1 | 16 | 17 | 18 | 19 | 20 | 21 | %d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n 22 | 23 | 24 | 25 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/test/resources/logback.xml: -------------------------------------------------------------------------------- 1 | 16 | 17 | 18 | 19 | 20 | 21 | %d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n 22 | 23 | 24 | 25 | 26 | 27 | 28 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/main/java/simplebank/serialization/SimpleBankJacksonObjectMapperProvider.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package simplebank.serialization; 18 | 19 | import com.fasterxml.jackson.databind.ObjectMapper; 20 | import com.gs.reladomo.serial.jackson.JacksonReladomoModule; 21 | 22 | import javax.ws.rs.ext.ContextResolver; 23 | 24 | public class SimpleBankJacksonObjectMapperProvider implements ContextResolver 25 | { 26 | final ObjectMapper defaultObjectMapper; 27 | 28 | public SimpleBankJacksonObjectMapperProvider() 29 | { 30 | defaultObjectMapper = new ObjectMapper(); 31 | defaultObjectMapper.registerModule(new JacksonReladomoModule()); 32 | } 33 | 34 | @Override 35 | public ObjectMapper getContext(Class type) 36 | { 37 | return defaultObjectMapper; 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /mini-kata/src/main/java/kata/domain/PetList.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import com.gs.fw.finder.Operation; 20 | 21 | import java.util.Collection; 22 | 23 | public class PetList extends PetListAbstract 24 | { 25 | public PetList() 26 | { 27 | super(); 28 | } 29 | 30 | public PetList(int initialSize) 31 | { 32 | super(initialSize); 33 | } 34 | 35 | public PetList(Collection c) 36 | { 37 | super(c); 38 | } 39 | 40 | public PetList(Operation operation) 41 | { 42 | super(operation); 43 | } 44 | 45 | /** 46 | * For each element in the list, print out petName() + " plays". 47 | */ 48 | public void play() 49 | { 50 | throw new UnsupportedOperationException("Implement this as a part of kata.testExercise4Test.makePetsPlay"); 51 | } 52 | } 53 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/main/java/bitemporalbank/serialization/BitemporalBankJacksonObjectMapperProvider.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package bitemporalbank.serialization; 18 | 19 | import com.fasterxml.jackson.databind.ObjectMapper; 20 | import com.gs.reladomo.serial.jackson.JacksonReladomoModule; 21 | 22 | import javax.ws.rs.ext.ContextResolver; 23 | 24 | public class BitemporalBankJacksonObjectMapperProvider implements ContextResolver 25 | { 26 | final ObjectMapper defaultObjectMapper; 27 | 28 | public BitemporalBankJacksonObjectMapperProvider() 29 | { 30 | defaultObjectMapper = new ObjectMapper(); 31 | defaultObjectMapper.registerModule(new JacksonReladomoModule()); 32 | } 33 | 34 | @Override 35 | public ObjectMapper getContext(Class type) 36 | { 37 | return defaultObjectMapper; 38 | } 39 | 40 | } 41 | -------------------------------------------------------------------------------- /mini-kata/src/test/resources/testconfig/TestMithraRuntimeConfig.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | -------------------------------------------------------------------------------- /mini-kata/src/main/java/kata/domain/ObjectSequence.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import com.gs.fw.common.mithra.MithraSequence; 20 | 21 | public class ObjectSequence extends ObjectSequenceAbstract implements MithraSequence 22 | { 23 | public ObjectSequence() 24 | { 25 | super(); 26 | // You must not modify this constructor. Mithra calls this internally. 27 | // You can call this constructor. You can also add new constructors. 28 | } 29 | 30 | @Override 31 | public void setSequenceName(String sequenceName) 32 | { 33 | this.setSimulatedSequenceName(sequenceName); 34 | } 35 | 36 | @Override 37 | public long getNextId() 38 | { 39 | return this.getNextValue(); 40 | } 41 | 42 | @Override 43 | public void setNextId(long nextValue) 44 | { 45 | this.setNextValue(nextValue); 46 | } 47 | } 48 | -------------------------------------------------------------------------------- /mini-kata/src/main/java/kata/domain/Pet.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import kata.util.TimestampProvider; 20 | 21 | import java.sql.Timestamp; 22 | 23 | public class Pet extends PetAbstract 24 | { 25 | public Pet(Timestamp processingDate) 26 | { 27 | super(processingDate); 28 | // You must not modify this constructor. Mithra calls this internally. 29 | // You can call this constructor. You can also add new constructors. 30 | } 31 | 32 | public Pet() 33 | { 34 | this(TimestampProvider.getInfinityDate()); 35 | } 36 | 37 | public Pet(String petName, int personId, int petAge, int petTypeId) 38 | { 39 | this(TimestampProvider.getInfinityDate()); 40 | this.setPetName(petName); 41 | this.setPersonId(personId); 42 | this.setPetAge(petAge); 43 | this.setPetTypeId(petTypeId); 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/pom.xml: -------------------------------------------------------------------------------- 1 | 2 | 17 | 18 | 21 | 22 | reladomo-tour 23 | com.goldmansachs.reladomo 24 | 16.0.0-SNAPSHOT 25 | 26 | 4.0.0 27 | 28 | pom 29 | 30 | Reladomo Tour Examples 31 | 32 | 33 | tour-examples 34 | 35 | 36 | simple-bank 37 | auditonly-bank 38 | bitemporal-bank 39 | 40 | 41 | 42 | -------------------------------------------------------------------------------- /main-kata/src/main/reladomoxml/CustomerAccount.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | kata.domain 24 | CustomerAccount 25 | CUSTOMER_ACCOUNT 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /mini-kata/src/main/java/kata/domain/Person.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | public class Person extends PersonAbstract 20 | { 21 | public Person() 22 | { 23 | super(); 24 | // You must not modify this constructor. Mithra calls this internally. 25 | // You can call this constructor. You can also add new constructors. 26 | } 27 | 28 | public Person(String firstName, String lastName) 29 | { 30 | super(); 31 | this.setFirstName(firstName); 32 | this.setLastName(lastName); 33 | } 34 | 35 | @Override 36 | public String toString() 37 | { 38 | return "Person(" + 39 | "personId=" + this.getPersonId() + 40 | ", firstName='" + this.getFirstName() + '\'' + 41 | ", lastName='" + this.getLastName() + '\'' + 42 | ", pets=" + this.getPets() + 43 | ')'; 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/util/ObjectSequenceObjectFactory.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.util; 18 | 19 | import com.gs.fw.common.mithra.MithraSequence; 20 | import com.gs.fw.common.mithra.MithraSequenceObjectFactory; 21 | import kata.domain.ObjectSequence; 22 | import kata.domain.ObjectSequenceFinder; 23 | 24 | public class ObjectSequenceObjectFactory 25 | implements MithraSequenceObjectFactory 26 | { 27 | public MithraSequence getMithraSequenceObject(String sequenceName, Object sourceAttribute, int initialValue) 28 | { 29 | ObjectSequence objectSequence = ObjectSequenceFinder.findByPrimaryKey(sequenceName); 30 | if (objectSequence == null) 31 | { 32 | objectSequence = new ObjectSequence(); 33 | objectSequence.setSequenceName(sequenceName); 34 | objectSequence.setNextId(initialValue); 35 | objectSequence.insert(); 36 | } 37 | return objectSequence; 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /.idea/compiler.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 37 | -------------------------------------------------------------------------------- /mini-kata/src/main/java/kata/util/ObjectSequenceObjectFactory.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.util; 18 | 19 | import com.gs.fw.common.mithra.MithraSequence; 20 | import com.gs.fw.common.mithra.MithraSequenceObjectFactory; 21 | import kata.domain.ObjectSequence; 22 | import kata.domain.ObjectSequenceFinder; 23 | 24 | public class ObjectSequenceObjectFactory 25 | implements MithraSequenceObjectFactory 26 | { 27 | public MithraSequence getMithraSequenceObject(String sequenceName, Object sourceAttribute, int initialValue) 28 | { 29 | ObjectSequence objectSequence = ObjectSequenceFinder.findByPrimaryKey(sequenceName); 30 | if (objectSequence == null) 31 | { 32 | objectSequence = new ObjectSequence(); 33 | objectSequence.setSimulatedSequenceName(sequenceName); 34 | objectSequence.setNextValue(initialValue); 35 | objectSequence.insert(); 36 | } 37 | return objectSequence; 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /.idea/copyright/profiles_settings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | 8 | 11 | 12 | 15 | 16 | 19 | 20 | 22 | 23 | 25 | 26 | 29 | 30 | 34 | 35 | 37 | 38 | -------------------------------------------------------------------------------- /main-kata/presentation/customization/html.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 0 33 | 34 | 35 | (c) 2016 Copyright Goldman Sachs, Inc. 36 | 37 | 38 | -------------------------------------------------------------------------------- /mini-kata/presentation/customization/html.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 0 33 | 34 | 35 | (c) 2016 Copyright Goldman Sachs, Inc. 36 | 37 | 38 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/AccountBalance.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import java.sql.Timestamp; 20 | 21 | public class AccountBalance extends AccountBalanceAbstract 22 | { 23 | public AccountBalance(Timestamp businessDate, Timestamp processingDate) 24 | { 25 | super(businessDate,processingDate); 26 | // You must not modify this constructor. Mithra calls this internally. 27 | // You can call this constructor. You can also add new constructors. 28 | } 29 | 30 | public AccountBalance(Timestamp businessDate) 31 | { 32 | super(businessDate); 33 | } 34 | 35 | @Override 36 | public String toString() 37 | { 38 | return "AccountBalance[id=" + this.getAccountId() 39 | + "; balance=" + this.getBalance() 40 | + "; busDates=" + this.getBusinessDateFrom() + "->" + this.getBusinessDateTo() 41 | + "; procDates=" + this.getProcessingDateFrom() + "->" + this.getProcessingDateTo() 42 | + ']'; 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/Employee.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import java.sql.Timestamp; 20 | 21 | public class Employee extends EmployeeAbstract 22 | { 23 | public Employee(Timestamp businessDate, Timestamp processingDate) 24 | { 25 | super(businessDate, processingDate 26 | ); 27 | // You must not modify this constructor. Mithra calls this internally. 28 | // You can call this constructor. You can also add new constructors. 29 | } 30 | 31 | public Employee(Timestamp businessDate) 32 | { 33 | super(businessDate); 34 | } 35 | 36 | public Employee( 37 | Timestamp businessDate, 38 | int employeeId, 39 | String firstName, 40 | String lastName, 41 | int age) 42 | { 43 | super(businessDate); 44 | this.setEmployeeId(employeeId); 45 | this.setFirstName(firstName); 46 | this.setLastName(lastName); 47 | this.setAge(age); 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/main/reladomoxml/CustomerAccount.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | simplebank.domain 24 | CustomerAccount 25 | CUSTOMER_ACCOUNT 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/domain/Person.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2018 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.domain; 18 | 19 | import org.eclipse.collections.api.block.procedure.Procedure; 20 | 21 | public class Person 22 | extends PersonAbstract 23 | { 24 | // Added for ExercisesAdvancedFinder question 9 25 | public static final Procedure INCREMENT_AGE = new Procedure() 26 | { 27 | public void value(Person person) 28 | { 29 | person.incrementAge(); 30 | } 31 | }; 32 | 33 | public Person() 34 | { 35 | super(); 36 | // You must not modify this constructor. Mithra calls this internally. 37 | // You can call this constructor. You can also add new constructors. 38 | } 39 | 40 | // Added for ExercisesAdvancedFinder question 9 41 | public void incrementAge() 42 | { 43 | this.setAge(this.getAge() + 1); 44 | } 45 | 46 | @Override 47 | public String toString() 48 | { 49 | return "Person[name=" + this.getName() 50 | + "; country=" + this.getCountry() 51 | + "; age=" + this.getAge() + ']'; 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /main-kata/src/test/resources/testdata/data_Employee.txt: -------------------------------------------------------------------------------- 1 | class kata.domain.Employee 2 | employeeId, firstName, lastName, age, businessDateFrom , businessDateTo , processingDateFrom , processingDateTo 3 | 1 , "Mary" , "Had" , 22 , "2009-03-12 00:00:00.0", "9999-12-01 23:59:00.0", "2009-03-12 12:45:12.0", "2009-03-13 11:30:22.0" 4 | 1 , "Mary" , "A" , 22 , "2009-03-12 00:00:00.0", "2009-03-19 00:00:00.0", "2009-03-13 11:30:22.0", "9999-12-01 23:59:00.0" 5 | 1 , "Mary" , "Little", 22 , "2009-03-19 00:00:00.0", "9999-12-01 23:59:00.0", "2009-03-13 19:35:12.0", "9999-12-01 23:59:00.0" 6 | 2 , "Bob" , "Burger", 29 , "2009-03-12 00:00:00.0", "9999-12-01 23:59:00.0", "2009-03-12 00:00:00.0", "9999-12-01 23:59:00.0" 7 | 4 , "Jake" , "Snake" , 35 , "2009-03-12 00:00:00.0", "9999-12-01 23:59:00.0", "2009-03-12 12:45:12.0", "9999-12-01 23:59:00.0" 8 | 5 , "Mark" , "Bird" , 28 , "2009-03-12 00:00:00.0", "9999-12-01 23:59:00.0", "2009-03-12 12:45:12.0", "9999-12-01 23:59:00.0" 9 | 6 , "Terry" , "Turtle", 19 , "2009-03-12 00:00:00.0", "9999-12-01 23:59:00.0", "2009-03-12 12:45:12.0", "9999-12-01 23:59:00.0" 10 | 11 | /* 12 | Employee Mary = new Employee(infinityDate, 1,"Mary","Lamb",26); 13 | Employee Bob = new Employee(infinityDate, 2,"Bob","Smith",29); 14 | Employee Ted = new Employee(infinityDate, 3,"Ted","Smith",33); 15 | Employee Jake = new Employee(infinityDate, 4,"Jake","Snake",42); 16 | Employee Barry = new Employee(infinityDate, 5,"Barry","Bird",28); 17 | Employee Terry = new Employee(infinityDate, 6,"Terry","Chase",19); 18 | Employee Harry = new Employee(infinityDate, 7,"Harry","White",22); 19 | Employee John = new Employee(infinityDate, 8,"John","Doe",45); 20 | Employee Jane = new Employee(infinityDate, 9,"Jane","Wilson",28); 21 | */ -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/main/reladomoxml/Customer.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | simplebank.domain 24 | Customer 25 | CUSTOMER 26 | 27 | 28 | 29 | 30 | 31 | 32 | 36 | this.customerId = CustomerAccount.customerId 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /main-kata/src/test/resources/testconfig/TestMithraRuntimeConfig.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | -------------------------------------------------------------------------------- /mini-kata/src/test/resources/testdata/data_AllTypes.txt: -------------------------------------------------------------------------------- 1 | class kata.domain.Person 2 | personId, firstName, lastName 3 | 1 , "Mary" , "Smith" 4 | 2 , "Bob" , "Smith" 5 | 3 , "Ted" , "Smith" 6 | 4 , "Jake" , "Snake" 7 | 5 , "Barry" , "Bird" 8 | 6 , "Terry" , "Turtle" 9 | 7 , "Harry" , "Hamster" 10 | 8 , "John" , "Doe" 11 | 12 | class kata.domain.Pet 13 | petName , personId, petAge, petTypeId, processingDateFrom , processingDateTo 14 | "Tabby" , 1 , 2 , 1 , "2014-01-15 10:59:00.0", "2015-01-15 10:59:00.0" 15 | "Dolly" , 2 , 3 , 1 , "2014-03-31 23:59:00.0", "9999-12-01 23:59:00.0" 16 | "Spot" , 2 , 2 , 2 , "2000-08-15 23:59:00.0", "2015-01-01 23:59:00.0" 17 | "Spike" , 3 , 4 , 2 , "1947-08-15 23:59:00.0", "9999-12-01 23:59:00.0" 18 | "Serpy" , 4 , 50 , 3 , "1965-02-01 23:59:00.0", "2015-02-01 23:59:00.0" 19 | "Tweety" , 5 , 2 , 4 , "2015-01-11 23:59:00.0", "9999-12-01 23:59:00.0" 20 | "Speedy" , 6 , 1 , 5 , "1947-08-15 23:59:00.0", "2013-08-15 22:10:00.0" 21 | "Fuzzy" , 7 , 1 , 6 , "2014-11-18 23:59:00.0", "9999-12-01 23:59:00.0" 22 | "Wuzzy" , 7 , 1 , 6 , "1980-02-29 23:59:00.0", "9999-12-01 23:59:00.0" 23 | "Tabby" , 1 , 3 , 1 , "2015-01-15 10:59:00.0", "9999-12-01 23:59:00.0" 24 | "Spot" , 2 , 17 , 2 , "2015-01-01 23:59:00.0", "9999-12-01 23:59:00.0" 25 | "Speedy" , 6 , 67 , 5 , "2013-08-15 22:10:00.0", "2014-08-15 22:10:00.0" 26 | "Speedy" , 6 , 68 , 5 , "2014-08-15 22:10:00.0", "9999-12-01 23:59:00.0" 27 | 28 | class kata.domain.PetType 29 | petTypeId, petType 30 | 1 , "CAT" 31 | 2 , "DOG" 32 | 3 , "SNAKE" 33 | 4 , "BIRD" 34 | 5 , "TURTLE" 35 | 6 , "HAMSTER" 36 | -------------------------------------------------------------------------------- /main-kata/src/main/reladomoxml/AccountBalance.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | kata.domain 24 | AccountBalance 25 | ACCOUNT_BALANCE 26 | 27 | 31 | 32 | 37 | 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /main-kata/src/main/reladomoxml/Person.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | kata.domain 24 | Person 25 | PERSON 26 | 27 | 29 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /main-kata/src/test/resources/testdata/data_AllTypes.txt: -------------------------------------------------------------------------------- 1 | class kata.domain.AllTypes 2 | id, booleanValue, byteValue, shortValue, charValue, intValue, longValue, floatValue, doubleValue, dateValue , timestampValue , stringValue , byteArrayValue 3 | 1, true , 7, 0, " ", 0, 0, 0.0, 0.0, "1967-01-01", "1968-01-01 11:30:22.0", "true byte 7" , "00010001B5BFB5BA00174E5954414D5350316E74616D735F70726F64" 4 | 2, false , 0, 9, " ", 0, 0, 0.0, 0.0, "1969-01-01", "1970-01-01 11:30:22.0", "false short 9" , "00010001B5BFB5BA00174E5954414D5350316E74616D735F70726F64" 5 | 3, true , 0, 0, "A", 0, 0, 0.0, 0.0, "1970-01-01", "1971-01-01 11:30:22.0", "true char A" , "00010001B5BFB5BA00174E5954414D5350316E74616D735F70726F64" 6 | 4, false , 0, 0, " ", 12, 0, 0.0, 0.0, "1972-01-01", "1973-01-01 11:30:22.0", "false int 12" , "00010001B5BFB5BA00174E5954414D5350316E74616D735F70726F64" 7 | 5, true , 0, 0, " ", 0, 16, 0.0, 0.0, "1975-01-01", "1976-01-01 11:30:22.0", "true long 16" , "00010001B5BFB5BA00174E5954414D5350316E74616D735F70726F64" 8 | 6, false , 0, 0, " ", 0, 0, 3.1415, 0.0, "1976-01-01", "1976-01-01 11:30:22.0", "false float pi", "00010001B5BFB5BA00174E5954414D5350316E74616D735F70726F64" 9 | 7, false , 0, 0, " ", 0, 0, 0.0, 2.7189, "1980-01-01", "1981-01-01 11:30:22.0", "false double e", "00010001B5BFB5BA00174E5954414D5350316E74616D735F70726F64" 10 | 8, true , 9, 9, "9", 9, 9, 9.0, 9.0, "1999-01-01", "1999-01-01 11:30:22.0", "all 9s" , "00010001B5BFB5BA00174E5954414D5350316E74616D735F70726F64" 11 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/auditonly-bank/src/main/java/auditonlybank/util/DateUtils.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package auditonlybank.util; 18 | 19 | import org.joda.time.DateTime; 20 | import org.joda.time.format.DateTimeFormat; 21 | import org.joda.time.format.DateTimeFormatter; 22 | 23 | import java.sql.Timestamp; 24 | 25 | public class DateUtils 26 | { 27 | private static final DateTimeFormatter DATE_TIME_FORMATTER = DateTimeFormat.forPattern("YYY-MM-dd"); 28 | 29 | private static final DateTimeFormatter DATE_TIME_FORMATTER_FULL = DateTimeFormat.forPattern("YYY-MM-dd HH:mm:ss.SSS"); 30 | 31 | public static Timestamp parseFull(String dateTimeString) 32 | { 33 | DateTime dateTime = DATE_TIME_FORMATTER_FULL.parseDateTime(dateTimeString); 34 | return new Timestamp(dateTime.toDateTime().getMillis()); 35 | } 36 | 37 | public static String printFull(Timestamp ts) 38 | { 39 | return DATE_TIME_FORMATTER_FULL.print(ts.getTime()); 40 | } 41 | 42 | public static Timestamp parse(String dateTimeString) 43 | { 44 | DateTime dateTime = DATE_TIME_FORMATTER.parseDateTime(dateTimeString); 45 | return new Timestamp(dateTime.toDateTime().getMillis()); 46 | } 47 | 48 | public static String print(Timestamp ts) 49 | { 50 | return DATE_TIME_FORMATTER.print(ts.getTime()); 51 | } 52 | } 53 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/main/java/bitemporalbank/util/DateUtils.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package bitemporalbank.util; 18 | 19 | import org.joda.time.DateTime; 20 | import org.joda.time.format.DateTimeFormat; 21 | import org.joda.time.format.DateTimeFormatter; 22 | 23 | import java.sql.Timestamp; 24 | 25 | public class DateUtils 26 | { 27 | private static final DateTimeFormatter DATE_TIME_FORMATTER = DateTimeFormat.forPattern("YYY-MM-dd"); 28 | 29 | private static final DateTimeFormatter DATE_TIME_FORMATTER_FULL = DateTimeFormat.forPattern("YYY-MM-dd HH:mm:ss.SSS"); 30 | 31 | public static Timestamp parseFull(String dateTimeString) 32 | { 33 | DateTime dateTime = DATE_TIME_FORMATTER_FULL.parseDateTime(dateTimeString); 34 | return new Timestamp(dateTime.toDateTime().getMillis()); 35 | } 36 | 37 | public static String printFull(Timestamp ts) 38 | { 39 | return DATE_TIME_FORMATTER_FULL.print(ts.getTime()); 40 | } 41 | 42 | public static Timestamp parse(String dateTimeString) 43 | { 44 | DateTime dateTime = DATE_TIME_FORMATTER.parseDateTime(dateTimeString); 45 | return new Timestamp(dateTime.toDateTime().getMillis()); 46 | } 47 | 48 | public static String print(Timestamp ts) 49 | { 50 | return DATE_TIME_FORMATTER.print(ts.getTime()); 51 | } 52 | } 53 | -------------------------------------------------------------------------------- /main-kata/src/test/java/kata/test/AbstractMithraTest.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.test; 18 | 19 | import com.gs.fw.common.mithra.test.ConnectionManagerForTests; 20 | import com.gs.fw.common.mithra.test.MithraTestResource; 21 | import org.junit.After; 22 | import org.junit.Before; 23 | 24 | public abstract class AbstractMithraTest 25 | { 26 | private MithraTestResource mithraTestResource; 27 | 28 | protected abstract String[] getTestDataFilenames(); 29 | 30 | protected String getMithraConfigXmlFilename() 31 | { 32 | return "testconfig/TestMithraRuntimeConfig.xml"; 33 | } 34 | 35 | @Before 36 | public void setUp() throws Exception 37 | { 38 | this.mithraTestResource = new MithraTestResource(this.getMithraConfigXmlFilename()); 39 | 40 | final ConnectionManagerForTests connectionManager = ConnectionManagerForTests.getInstanceForDbName("mithra_db"); 41 | this.mithraTestResource.createSingleDatabase(connectionManager); 42 | for (String filename : this.getTestDataFilenames()) 43 | { 44 | this.mithraTestResource.addTestDataToDatabase(filename, connectionManager); 45 | } 46 | 47 | this.mithraTestResource.setUp(); 48 | } 49 | 50 | @After 51 | public void tearDown() throws Exception 52 | { 53 | this.mithraTestResource.tearDown(); 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /mini-kata/src/test/java/kata/test/AbstractMithraTest.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2018 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.test; 18 | 19 | import com.gs.fw.common.mithra.test.ConnectionManagerForTests; 20 | import com.gs.fw.common.mithra.test.MithraTestResource; 21 | import kata.domain.Pet; 22 | import org.eclipse.collections.api.block.function.Function; 23 | import org.junit.After; 24 | import org.junit.Before; 25 | 26 | public class AbstractMithraTest 27 | { 28 | public static final Function TO_PET_NAME = Pet::getPetName; 29 | 30 | private MithraTestResource mithraTestResource; 31 | 32 | protected String getMithraConfigXmlFilename() 33 | { 34 | return "testconfig/TestMithraRuntimeConfig.xml"; 35 | } 36 | 37 | @Before 38 | public void setUp() throws Exception 39 | { 40 | this.mithraTestResource = new MithraTestResource(this.getMithraConfigXmlFilename()); 41 | ConnectionManagerForTests connectionManager = ConnectionManagerForTests.getInstanceForDbName("mithra_db"); 42 | this.mithraTestResource.createSingleDatabase(connectionManager); 43 | this.mithraTestResource.addTestDataToDatabase("testdata/data_AllTypes.txt", connectionManager); 44 | this.mithraTestResource.setUp(); 45 | } 46 | 47 | @After 48 | public void tearDown() throws Exception 49 | { 50 | this.mithraTestResource.tearDown(); 51 | } 52 | } 53 | -------------------------------------------------------------------------------- /main-kata/src/main/reladomoxml/Employee.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | kata.domain 24 | Employee 25 | EMPLOYEE 26 | 27 | 31 | 32 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/main/java/bitemporalbank/app/BitemporalBankApp.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package bitemporalbank.app; 18 | 19 | import com.gs.fw.common.mithra.MithraManager; 20 | import com.gs.fw.common.mithra.MithraManagerProvider; 21 | 22 | import java.io.InputStream; 23 | 24 | public class BitemporalBankApp 25 | { 26 | public BitemporalBankApp() throws Exception 27 | { 28 | this.initReladomo(); 29 | } 30 | 31 | public static void main(String[] args) throws Exception 32 | { 33 | new BitemporalBankApp().start(); 34 | } 35 | 36 | private void initReladomo() throws Exception 37 | { 38 | MithraManager mithraManager = MithraManagerProvider.getMithraManager(); 39 | mithraManager.setTransactionTimeout(60 * 1000); 40 | loadReladomoXML("BitemporalBankRuntimeConfiguration.xml"); 41 | } 42 | 43 | private void loadReladomoXML(String fileName) throws Exception 44 | { 45 | InputStream stream = BitemporalBankApp.class.getClassLoader().getResourceAsStream(fileName); 46 | if (stream == null) 47 | { 48 | throw new Exception("Failed to locate " + fileName + " in classpath"); 49 | } 50 | MithraManagerProvider.getMithraManager().readConfiguration(stream); 51 | stream.close(); 52 | } 53 | 54 | private void start() 55 | { 56 | //implement app logic 57 | } 58 | } 59 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/main/java/simplebank/app/SimpleBankApp.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package simplebank.app; 18 | 19 | import com.gs.fw.common.mithra.MithraManager; 20 | import com.gs.fw.common.mithra.MithraManagerProvider; 21 | 22 | import java.io.InputStream; 23 | 24 | public class SimpleBankApp 25 | { 26 | public SimpleBankApp() throws Exception 27 | { 28 | this.initReladomo(); 29 | } 30 | 31 | public static void main(String[] args) throws Exception 32 | { 33 | new SimpleBankApp().start(); 34 | } 35 | 36 | private void initReladomo() throws Exception 37 | { 38 | MithraManager mithraManager = MithraManagerProvider.getMithraManager(); 39 | mithraManager.setTransactionTimeout(60 * 1000); 40 | InputStream stream = loadReladomoXMLFromClasspath("SimpleBankRuntimeConfiguration.xml"); 41 | MithraManagerProvider.getMithraManager().readConfiguration(stream); 42 | stream.close(); 43 | } 44 | 45 | private InputStream loadReladomoXMLFromClasspath(String fileName) throws Exception 46 | { 47 | InputStream stream = SimpleBankApp.class.getClassLoader().getResourceAsStream(fileName); 48 | if (stream == null) 49 | { 50 | throw new Exception("Failed to locate " + fileName + " in classpath"); 51 | } 52 | return stream; 53 | } 54 | 55 | private void start() 56 | { 57 | //implement app logic 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /mini-kata/src/main/reladomoxml/Pet.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | kata.domain 24 | Pet 25 | PET 26 | 27 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 44 | this.petTypeId = PetType.petTypeId 45 | 46 | 47 | 48 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/auditonly-bank/src/main/reladomoxml/CustomerAccount.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | auditonlybank.domain 24 | CustomerAccount 25 | CUSTOMER_ACCOUNT 26 | 27 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /mini-kata/src/main/reladomoxml/Person.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | kata.domain 24 | Person 25 | PERSON 26 | 27 | 29 | 35 | 36 | 37 | 38 | 39 | 44 | this.personId = Pet.personId 45 | 46 | 47 | 48 | -------------------------------------------------------------------------------- /main-kata/presentation/customization/fo.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 0 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | start 41 | wrap 42 | 43 | 44 | 45 | #F0F0F0 46 | 47 | 48 | 49 | -------------------------------------------------------------------------------- /mini-kata/presentation/customization/fo.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 0 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | start 41 | wrap 42 | 43 | 44 | 45 | #F0F0F0 46 | 47 | 48 | 49 | -------------------------------------------------------------------------------- /main-kata/src/main/reladomoxml/Customer.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | kata.domain 24 | Customer 25 | CUSTOMER 26 | 27 | 29 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/customization/html.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | (c) 2016 Copyright Goldman Sachs, Inc. 37 | 38 | 39 | 40 | 41 | appendix toc,title 42 | article/appendix nop 43 | article toc,title 44 | book toc,title 45 | chapter toc,title 46 | part toc,title 47 | preface toc,title 48 | sect1 toc 49 | sect2 toc 50 | sect3 toc 51 | sect4 toc 52 | 53 | 54 | -------------------------------------------------------------------------------- /main-kata/src/main/reladomoxml/Task.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | kata.domain 24 | Task 25 | TASK 26 | 27 | 32 | 33 | 35 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/auditonly-bank/src/main/reladomoxml/Customer.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | auditonlybank.domain 24 | Customer 25 | CUSTOMER 26 | 27 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 41 | this.customerId = CustomerAccount.customerId 42 | 43 | 44 | 45 | -------------------------------------------------------------------------------- /reladomo-tour/tour-doc/src/docbook/guide.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 21 | 22 | 23 | 24 | Guided Tour Of Reladomo 25 | A hands-on guide for developers 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/main/reladomoxml/CustomerAccount.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | bitemporalbank.domain 24 | CustomerAccount 25 | CUSTOMER_ACCOUNT 26 | 27 | 33 | 34 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/main/reladomoxml/Customer.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | 19 | 22 | 23 | bitemporalbank.domain 24 | Customer 25 | CUSTOMER 26 | 27 | 33 | 34 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 48 | this.customerId = CustomerAccount.customerId 49 | 50 | 51 | 52 | -------------------------------------------------------------------------------- /main-kata/src/test/resources/testdata/data_CustomersAccountsBalances.txt: -------------------------------------------------------------------------------- 1 | class kata.domain.Customer 2 | customerId , name , country 3 | 1 , "John Smith" , "USA" 4 | 2 , "Yusuke Sato" , "JPN" 5 | 3 , "Claire Bennet" , "USA" 6 | 4 , "Diana Prince" , "USA" 7 | 8 | 9 | class kata.domain.CustomerAccount 10 | accountId, customerId, accountName , accountType 11 | 100 , 1 , "Smith Running Account" , "Running" 12 | 200 , 1 , "John's Saving Account" , "Savings" 13 | 300 , 1 , "John's Saving Account 2", "Savings" 14 | 400 , 2 , "My Account" , "Savings" 15 | 10100 , 3 , "Public" , "Daily" 16 | 10200 , 3 , "Private" , "Running" 17 | 20100 , 4 , "Public" , "Daily" 18 | 20200 , 4 , "Private 1" , "Running" 19 | 20300 , 4 , "Private 2" , "Swiss" 20 | 21 | 22 | class kata.domain.AccountBalance 23 | accountId, balance, businessDateFrom , businessDateTo , processingDateFrom , processingDateTo 24 | 100 , 1060, "2009-03-12 00:00:00.0", "9999-12-01 23:59:00.0", "2009-03-12 12:45:12.0", "2009-03-13 11:30:22.0" 25 | 100 , 1000, "2009-03-12 00:00:00.0", "2009-03-19 00:00:00.0", "2009-03-13 11:30:22.0", "9999-12-01 23:59:00.0" 26 | 100 , 2000, "2009-03-19 00:00:00.0", "9999-12-01 23:59:00.0", "2009-03-13 19:35:12.0", "9999-12-01 23:59:00.0" 27 | 200 , -500, "2009-03-12 00:00:00.0", "9999-12-01 23:59:00.0", "2009-03-12 12:45:12.0", "9999-12-01 23:59:00.0" 28 | 400 , -600, "2009-03-12 00:00:00.0", "9999-12-01 23:59:00.0", "2009-03-12 12:45:12.0", "9999-12-01 23:59:00.0" 29 | 10100 , 10000, "2001-01-01 00:00:00.0", "9999-12-01 23:59:00.0", "2001-01-01 14:00:00.0", "9999-12-01 23:59:00.0" 30 | 10200 , 100000, "2001-01-01 00:00:00.0", "2010-12-01 00:00:00.0", "2001-01-01 14:00:00.0", "2010-12-01 14:00:00.0" 31 | 10200 , -500000, "2010-12-01 00:00:00.0", "9999-12-01 23:59:00.0", "2010-12-01 14:00:00.0", "9999-12-01 23:59:00.0" 32 | 20100 , 10000, "2008-02-01 00:00:00.0", "9999-12-01 23:59:00.0", "2008-02-01 14:00:00.0", "9999-12-01 23:59:00.0" 33 | 20200 , -50000, "2008-02-01 00:00:00.0", "2010-10-01 00:00:00.0", "2008-02-01 14:00:00.0", "2010-10-01 14:00:00.0" 34 | 20200 , -800000, "2010-10-01 00:00:00.0", "9999-12-01 23:59:00.0", "2010-12-01 14:00:00.0", "9999-12-01 23:59:00.0" 35 | 20300 , -200000, "2007-10-01 00:00:00.0", "9999-12-01 23:59:00.0", "2007-12-01 14:00:00.0", "9999-12-01 23:59:00.0" 36 | -------------------------------------------------------------------------------- /main-kata/main-kata.iml: -------------------------------------------------------------------------------- 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 | -------------------------------------------------------------------------------- /mini-kata/mini-kata.iml: -------------------------------------------------------------------------------- 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 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/bitemporal-bank/src/main/java/bitemporalbank/web/BitemporalBankServer.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package bitemporalbank.web; 18 | 19 | import bitemporalbank.serialization.BitemporalBankJacksonObjectMapperProvider; 20 | import com.gs.fw.common.mithra.MithraManager; 21 | import com.gs.fw.common.mithra.MithraManagerProvider; 22 | import org.glassfish.grizzly.http.server.HttpServer; 23 | import org.glassfish.jersey.grizzly2.httpserver.GrizzlyHttpServerFactory; 24 | import org.glassfish.jersey.jackson.JacksonFeature; 25 | import org.glassfish.jersey.server.ResourceConfig; 26 | 27 | import javax.ws.rs.core.UriBuilder; 28 | import java.io.IOException; 29 | import java.io.InputStream; 30 | import java.net.URI; 31 | 32 | public class BitemporalBankServer 33 | { 34 | 35 | private ResourceConfig config; 36 | 37 | public BitemporalBankServer(String runtimeConfigXML) throws Exception 38 | { 39 | this.initReladomo(runtimeConfigXML); 40 | } 41 | 42 | public static void main(String[] args) throws Exception 43 | { 44 | String runtimeConfigXML = "reladomoxml/bitemporalbankRuntimeConfiguration.xml"; 45 | new BitemporalBankServer(runtimeConfigXML).start(); 46 | } 47 | 48 | protected void initReladomo(String runtimeConfigXML) throws Exception 49 | { 50 | MithraManager mithraManager = MithraManagerProvider.getMithraManager(); 51 | mithraManager.setTransactionTimeout(60 * 1000); 52 | loadReladomoXML(runtimeConfigXML); 53 | } 54 | 55 | protected void loadReladomoXML(String fileName) throws Exception 56 | { 57 | InputStream stream = BitemporalBankServer.class.getClassLoader().getResourceAsStream(fileName); 58 | if (stream == null) 59 | { 60 | throw new Exception("Failed to locate " + fileName + " in classpath"); 61 | } 62 | MithraManagerProvider.getMithraManager().readConfiguration(stream); 63 | stream.close(); 64 | } 65 | 66 | protected void initResources() 67 | { 68 | this.config = new ResourceConfig(CustomerResource.class); 69 | config.register(JacksonFeature.class); 70 | config.register(BitemporalBankJacksonObjectMapperProvider.class); 71 | } 72 | 73 | public void start() throws IOException 74 | { 75 | initResources(); 76 | URI baseUri = UriBuilder.fromUri("http://localhost/").port(9998).build(); 77 | HttpServer server = GrizzlyHttpServerFactory.createHttpServer(baseUri, config); 78 | server.start(); 79 | } 80 | } 81 | -------------------------------------------------------------------------------- /reladomo-tour/tour-examples/simple-bank/src/main/java/simplebank/web/SimpleBankServer.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2016 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package simplebank.web; 18 | 19 | import com.gs.fw.common.mithra.MithraManager; 20 | import com.gs.fw.common.mithra.MithraManagerProvider; 21 | import org.glassfish.grizzly.http.server.HttpServer; 22 | import org.glassfish.jersey.grizzly2.httpserver.GrizzlyHttpServerFactory; 23 | import org.glassfish.jersey.jackson.JacksonFeature; 24 | import org.glassfish.jersey.server.ResourceConfig; 25 | import simplebank.serialization.SimpleBankJacksonObjectMapperProvider; 26 | 27 | import javax.ws.rs.core.UriBuilder; 28 | import java.io.IOException; 29 | import java.io.InputStream; 30 | import java.net.URI; 31 | 32 | public class SimpleBankServer 33 | { 34 | private ResourceConfig config; 35 | 36 | public SimpleBankServer(String runtimeConfigXML) throws Exception 37 | { 38 | this.initReladomo(runtimeConfigXML); 39 | } 40 | 41 | protected void initReladomo(String runtimeConfigXML) throws Exception 42 | { 43 | MithraManager mithraManager = MithraManagerProvider.getMithraManager(); 44 | mithraManager.setTransactionTimeout(60 * 1000); 45 | InputStream stream = loadReladomoXMLFromClasspath(runtimeConfigXML); 46 | MithraManagerProvider.getMithraManager().readConfiguration(stream); 47 | stream.close(); 48 | } 49 | 50 | private InputStream loadReladomoXMLFromClasspath(String fileName) throws Exception 51 | { 52 | InputStream stream = SimpleBankServer.class.getClassLoader().getResourceAsStream(fileName); 53 | if (stream == null) 54 | { 55 | throw new Exception("Failed to locate " + fileName + " in classpath"); 56 | } 57 | return stream; 58 | } 59 | 60 | protected void initResources() 61 | { 62 | this.config = new ResourceConfig(CustomerResource.class); 63 | config.register(JacksonFeature.class); 64 | config.register(SimpleBankJacksonObjectMapperProvider.class); 65 | } 66 | 67 | public void start() throws IOException 68 | { 69 | initResources(); 70 | URI baseUri = UriBuilder.fromUri("http://localhost/").port(9998).build(); 71 | HttpServer server = GrizzlyHttpServerFactory.createHttpServer(baseUri, config); 72 | server.start(); 73 | } 74 | 75 | public static void main(String[] args) throws Exception 76 | { 77 | String runtimeConfigXML = "reladomoxml/SimpleBankRuntimeConfiguration.xml"; 78 | new SimpleBankServer(runtimeConfigXML).start(); 79 | } 80 | } 81 | -------------------------------------------------------------------------------- /main-kata/src/main/java/kata/util/TimestampProvider.java: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright 2017 Goldman Sachs. 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, 10 | software distributed under the License is distributed on an 11 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 12 | KIND, either express or implied. See the License for the 13 | specific language governing permissions and limitations 14 | under the License. 15 | */ 16 | 17 | package kata.util; 18 | 19 | import java.sql.Timestamp; 20 | import java.util.Calendar; 21 | import java.util.Date; 22 | 23 | public class TimestampProvider 24 | { 25 | private TimestampProvider() 26 | { 27 | throw new UnsupportedOperationException("utility methods only -- not instantiable"); 28 | } 29 | 30 | private static final Timestamp INFINITY_DATE = TimestampProvider.create(9999, 11, 1, Calendar.PM, 23, 59, 0, 0); 31 | 32 | private static Timestamp create(int year, int month, int dayOfMonth, int amPm, int hourOfDay, int minute, int second, int millisecond) 33 | { 34 | Calendar cal = Calendar.getInstance(); 35 | cal.set(Calendar.YEAR, year); 36 | cal.set(Calendar.MONTH, month); 37 | cal.set(Calendar.DAY_OF_MONTH, dayOfMonth); 38 | cal.set(Calendar.AM_PM, amPm); 39 | cal.set(Calendar.HOUR_OF_DAY, hourOfDay); 40 | cal.set(Calendar.MINUTE, minute); 41 | cal.set(Calendar.SECOND, second); 42 | cal.set(Calendar.MILLISECOND, millisecond); 43 | return new Timestamp(cal.getTimeInMillis()); 44 | } 45 | 46 | /** 47 | * Infinity reference date. 48 | * 49 | * @return A timestamp representing date "9999-12-01 23:59:00.0" 50 | */ 51 | public static Timestamp getInfinityDate() 52 | { 53 | return INFINITY_DATE; 54 | } 55 | 56 | public static Timestamp createBusinessDate(Date date) 57 | { 58 | Calendar cal = Calendar.getInstance(); 59 | cal.setTime(date); 60 | setBusinessDateTime(cal); 61 | return new Timestamp(cal.getTimeInMillis()); 62 | } 63 | 64 | private static void setBusinessDateTime(Calendar cal) 65 | { 66 | cal.set(Calendar.AM_PM, Calendar.PM); 67 | cal.set(Calendar.HOUR_OF_DAY, 18); 68 | cal.set(Calendar.MINUTE, 30); 69 | cal.set(Calendar.SECOND, 0); 70 | cal.set(Calendar.MILLISECOND, 0); 71 | } 72 | 73 | /** 74 | * Converts the date passed to a Timestamp that is at 18:30 of the same day as the argument passed. 75 | * @return a timestamp at 18:30 at the same day as the argument 76 | */ 77 | public static Timestamp ensure1830(Date date) 78 | { 79 | return createBusinessDate(date); 80 | } 81 | 82 | public static Timestamp getNextDay(Timestamp businessDay) 83 | { 84 | Calendar cal = Calendar.getInstance(); 85 | cal.setTime(businessDay); 86 | cal.add(Calendar.DATE, 1); 87 | setBusinessDateTime(cal); 88 | return new Timestamp(cal.getTimeInMillis()); 89 | } 90 | } 91 | --------------------------------------------------------------------------------