Getting Starting
Example
Template For LAMM
- How should I create projects on this architecture? (Github Template)
Documentation
- In general, I will try to describe the architecture in detail (Modification of MVVM). But before reading the documentation, please read the entire example
General Rules
- Forbidden words ():
-
- And
-
- Or
-
- Where
-
- For
-
- From
-
- Parameter/Parameters
- Alternative to forbidden words ():
-
- W
- Exception to forbidden words in some situations ():
-
- And
- Try/catch only at 'NamedUtility','ModelRepository'
Architectural Objects
- We create and write architectural objects in the order in which it will be faster and better for the developer to run all this code. Example: We wrote the design and basic setup in the 'NamedVM' class, and then we started writing 'DataForNamed' to add simple logic for the data loading simulator and displaying a list, and maybe add error, and only then we write 'Model', 'ListModel' to show the concretive data in the list that we need it, and at the end we write 'NamedService' and 'ModelRepository' to load real data (We take into account that we will return to these objects. Example: you write 'DataForNamed' and started writing a 'Model', and then returned to 'DataForNamed' to add this 'Model'.)
- To cache temporary data and then share it, that is, the class 'TempCacheService'
Number. Name - Inheritance | Refactoring
123456 . NamedUtility - Refactoring
- NamedVM - Refactoring
- DataForNamed - Refactoring
- Model - Inheritance
- ListModel - Inheritance
- NamedService - Refactoring
- ModelRepository - Inheritance
NamedUtility
- KeysNamedServiceUtility - a class where the keys of a specific service are stored, and the keys are distributed across models:
-
- Example - Model 'IPAddress', Key 'Ip', Code 'static const String iPAddressQQIp = "ip"':
-
-
- QQ - needed as a separator that helps to quickly understand what this constant does
-
- KeysNamedUtility - a class whose keys belong to other classes and are attached to methods and can be used to store errors and various successes, etc...:
-
- Example - Class 'DataForAntiDDosSystemView', Key 'GetExceptionInStringWhereNotEqualsParametersCodeAndInputCode', Code 'static const String dataForAntiDDosSystemViewQQGetExceptionInStringWhereNotEqualsParametersCodeAndInputCode = "dataForAntiDDosSystemViewQQGetExceptionInStringWhereNotEqualsParametersCodeAndInputCode"':
-
-
- QQ - needed as a separator that helps to quickly understand what this constant does
-
- KeysAPIUtility - exception, where the key is the name of the service you are using (not the class)
-
- Example - Service 'Firebase', Key 'ProjectName', Code 'static const String firebaseQQProjectName = "example"'
-
-
- QQ - needed as a separator that helps to quickly understand what this constant does
-
- NamedUtility - it could be anything:
-
- Example - TimerUtility,InsertUserUtility (To NamedService), etc...
- Methods names:
-
- Get:
-
-
- get(Named)(WhereNamed)
ParameterNamed
:
- get(Named)(WhereNamed)
-
-
-
-
- () - optional
-
-
-
-
-
- [] - if available
-
-
-
-
-
- get - required word
-
-
-
-
-
- (Named) - we get primitive type or another model or briefly describe what we are taking
-
-
-
-
-
- (WhereNamed) - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
ParameterNamed
- what global variables were used ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - getNamedWhereNamedFromOneParametersTwo))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
-
-
- Local variable name - named(WhereNamed)
ParameterNamed
- Local variable name - named(WhereNamed)
-
-
-
- Void:
-
-
- operation
OtherModelOrPrimitiveType
(WhereNamed)ParameterNamed
- operation
-
-
-
-
- () - optional
-
-
-
-
-
- [] - if available
-
-
-
-
-
- operation - insert, update, delete, set, init, etc...
-
-
-
-
-
OtherModelOrPrimitiveType
- if your class has a model list or primitive type list parameter. But if you specify a different model or primitive type inFromNamed
then there is no point in specifying that. If you add the same "Model" to your "ListModel" then there is no point in specifying this
-
-
-
-
-
- (WhereNamed) - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
ParameterNamed
- what global variables were used ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - operationOtherModelOrPrimitiveTypeWhereNamedFromOneParameterOne))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
- Bool:
-
-
- isWhereNamed
ParameterNamed
:
- isWhereNamed
-
-
-
-
- [] - if available
-
-
-
-
-
- isWhereNamed - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
ParameterNamed
- what global variables were used ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - isWhereNamedFromOneParametersTwo))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
-
-
- Local variable name - isWhereNamed
ParameterNamed
- Local variable name - isWhereNamed
-
-
NamedVM
- A 'NamedVM' called from another 'NamedVM' will be named by its 'Named' as a prefix of 'NamedWNamedVM', and the directories will also be located:
-
- Example:
-
-
- UserVM
-
-
-
-
- UserWMoviesVM
-
-
-
-
-
-
- UserWMoviesWActorsVM
-
-
-
- Private methods that are invoked by other methods using if (Not layout/UI/design methods):
-
- Summary in the form of variables: | Example:
-
-
- Summary in the form of variables:
-
-
-
-
- numberQQ${In which "method" did this madness begin ?}QQ${What "method" started this madness ?}
-
-
-
-
-
-
- numberBranchNumberQQ${In which "method" did this madness begin ?}QQ${What "method" started this madness ?}
-
-
-
-
-
-
-
-
- numberBranchNumberBranchNumberQQ${In which "method" did this madness begin ?}QQ${What "method" started this madness ?}
-
-
-
-
-
-
- Example:
-
-
-
-
- firstQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
- firstBranchOneQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
- firstBranchOneBranchOneQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
- Explanation:
-
-
- Private methods created in this way allow you to write complex logic and readable code
-
-
-
- Minimum and maximum two 'QQ' - needed as a separator that helps to quickly understand what this method does
-
-
-
- 'if' create methods:
-
-
-
-
- firstQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService:
-
-
-
-
-
-
- firstBranchOneQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService:
-
-
-
-
-
-
-
-
- firstBranchOneBranchOneQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- firstBranchOneBranchTwoQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- firstBranchOneBranchThreeQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
- firstBranchTwoQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService:
-
-
-
-
-
-
-
-
- firstBranchTwoBranchOneQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- firstBranchTwoBranchTwoQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- firstBranchTwoBranchThreeQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
- firstBranchThreeQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService:
-
-
-
-
-
-
-
-
- firstBranchThreeBranchOneQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- firstBranchThreeBranchTwoQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- firstBranchThreeBranchThreeQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
- secondQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService:
-
-
-
-
-
-
- secondBranchOneQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService:
-
-
-
-
-
-
-
-
- secondBranchOneBranchOneQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- secondBranchOneBranchTwoQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- secondBranchOneBranchThreeQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
- secondBranchTwoQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService:
-
-
-
-
-
-
-
-
- secondBranchTwoBranchOneQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- secondBranchTwoBranchTwoQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- secondBranchTwoBranchThreeQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
- secondBranchThreeQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService:
-
-
-
-
-
-
-
-
- secondBranchThreeBranchOneQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- secondBranchThreeBranchTwoQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- secondBranchThreeBranchThreeQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
- thirdQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService:
-
-
-
-
-
-
- thirdBranchOneQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService:
-
-
-
-
-
-
-
-
- thirdBranchOneBranchOneQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- thirdBranchOneBranchTwoQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- thirdBranchOneBranchThreeQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
- thirdBranchTwoQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService:
-
-
-
-
-
-
-
-
- thirdBranchTwoBranchOneQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- thirdBranchTwoBranchTwoQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- thirdBranchTwoBranchThreeQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
- thirdBranchThreeQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService:
-
-
-
-
-
-
-
-
- thirdBranchThreeBranchOneQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- thirdBranchThreeBranchTwoQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
-
-
-
-
-
- thirdBranchThreeBranchThreeQQInitReleaseCallbackQQGetIPAddressWhereJsonipAPIParameterHttpClientService
-
-
-
-
DataForNamed
- Methods names:
-
- Get:
-
-
- get(Named)(WhereNamed)
ParameterNamed
:
- get(Named)(WhereNamed)
-
-
-
-
- () - optional
-
-
-
-
-
- [] - if available
-
-
-
-
-
- get - required word
-
-
-
-
-
- (Named) - we get primitive type or another model or briefly describe what we are taking
-
-
-
-
-
- (WhereNamed) - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
ParameterNamed
- what global variables were used ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - getNamedWhereNamedFromOneParametersTwo))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
-
-
- Local variable name - named(WhereNamed)
ParameterNamed
- Local variable name - named(WhereNamed)
-
-
-
- Void:
-
-
- operation
OtherModelOrPrimitiveType
(WhereNamed)ParameterNamed
- operation
-
-
-
-
- () - optional
-
-
-
-
-
- [] - if available
-
-
-
-
-
- operation - insert, update, delete, set, init, etc...
-
-
-
-
-
OtherModelOrPrimitiveType
- if your class has a model list or primitive type list parameter. But if you specify a different model or primitive type inFromNamed
then there is no point in specifying that. If you add the same "Model" to your "ListModel" then there is no point in specifying this
-
-
-
-
-
- (WhereNamed) - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
ParameterNamed
- what global variables were used ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - operationOtherModelOrPrimitiveTypeWhereNamedFromOneParameterOne))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
- Bool:
-
-
- isWhereNamed
ParameterNamed
:
- isWhereNamed
-
-
-
-
- [] - if available
-
-
-
-
-
- isWhereNamed - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
ParameterNamed
- what global variables were used ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - isWhereNamedFromOneParametersTwo))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
-
-
- Local variable name - isWhereNamed
ParameterNamed
- Local variable name - isWhereNamed
-
-
Model
- If complex logic is needed, then inside a certain model we create model catalogs with the prefix of a certain model (ModelWNamed):
-
- Example:
-
-
- Matches:
-
-
-
-
- MatchesWDebut
-
-
-
-
-
- MatchesWMiddlegame
-
-
-
-
-
- MatchesWEndgame
-
-
- Inheritance classes:
-
- Names of inherited classes:
-
-
- ModelNumber:
-
-
-
-
- Model - The name of the model itself. Example: 'User', 'Movie', etc...
-
-
-
-
-
- Number - 'First','Second','Third', etc...
-
-
-
- Inheritance goes along one branch:
-
-
- User -> UserFirst -> UserSecond -> UserThird
-
-
- When inheriting, we also inherit:
-
-
- 'ListModel'
-
-
-
- 'ModelRepository'
-
-
-
- 'ModelWNamedWNamedWNamedIterator' if exists
-
- Methods names:
-
- Get:
-
-
- get(Named)(WhereNamed)
ParameterNamed
:
- get(Named)(WhereNamed)
-
-
-
-
- () - optional
-
-
-
-
-
- [] - if available
-
-
-
-
-
- get - required word
-
-
-
-
-
- (Named) - we get primitive type or another model or briefly describe what we are taking
-
-
-
-
-
- (WhereNamed) - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
ParameterNamed
- what global variables were used ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - getNamedWhereNamedFromOneParametersTwo))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
-
-
- Local variable name - named(WhereNamed)
ParameterNamed
- Local variable name - named(WhereNamed)
-
-
-
-
- getModel(WhereNamed)
FromNamed
- getModel(WhereNamed)
-
-
-
-
- () - optional
-
-
-
-
-
- [] - if available
-
-
-
-
-
- getModel - when we return an object of our own class
-
-
-
-
-
- (WhereNamed) - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - getModelWhereNamedFromOne))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
-
-
- Local variable name - model(WhereNamed)
FromNamed
- Local variable name - model(WhereNamed)
-
-
-
- Void:
-
-
- operation
OtherModelOrPrimitiveType
(WhereNamed)ParameterNamed
- operation
-
-
-
-
- () - optional
-
-
-
-
-
- [] - if available
-
-
-
-
-
- operation - insert, update, delete, set, init, etc...
-
-
-
-
-
OtherModelOrPrimitiveType
- if your class has a model list or primitive type list parameter. But if you specify a different model or primitive type inFromNamed
then there is no point in specifying that. If you add the same "Model" to your "ListModel" then there is no point in specifying this
-
-
-
-
-
- (WhereNamed) - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
ParameterNamed
- what global variables were used ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - operationOtherModelOrPrimitiveTypeWhereNamedFromOneParameterOne))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
- Bool:
-
-
- isWhereNamed
ParameterNamed
:
- isWhereNamed
-
-
-
-
- [] - if available
-
-
-
-
-
- isWhereNamed - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
ParameterNamed
- what global variables were used ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - isWhereNamedFromOneParametersTwo))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
-
-
- Local variable name - isWhereNamed
ParameterNamed
- Local variable name - isWhereNamed
-
-
ListModel
- Inheritance classes:
-
- Names of inherited classes:
-
-
- ListModelNumber:
-
-
-
-
- ListModel - The name of the model itself. Example - 'ListUser', 'ListMovie', etc...
-
-
-
-
-
- Number - 'First','Second','Third', etc...
-
-
-
- Inheritance goes along one branch:
-
-
- ListUser -> ListUserFirst -> ListUserSecond -> ListUserThird
-
-
- When inheriting, we also inherit:
-
-
- 'Model'
-
-
-
- 'ModelRepository'
-
-
-
- 'ModelWNamedWNamedWNamedIterator' if exists
-
- Methods names:
-
- Get:
-
-
- get(Named)(WhereNamed)
ParameterNamed
:
- get(Named)(WhereNamed)
-
-
-
-
- () - optional
-
-
-
-
-
- [] - if available
-
-
-
-
-
- get - required word
-
-
-
-
-
- (Named) - we get primitive type or another model or briefly describe what we are taking
-
-
-
-
-
- (WhereNamed) - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
ParameterNamed
- what global variables were used ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - getNamedWhereNamedFromOneParametersTwo))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
-
-
- Local variable name - named(WhereNamed)
ParameterNamed
- Local variable name - named(WhereNamed)
-
-
-
- Void:
-
-
- operation
OtherModelOrPrimitiveType
(WhereNamed)ParameterNamed
- operation
-
-
-
-
- () - optional
-
-
-
-
-
- [] - if available
-
-
-
-
-
- operation - insert, update, delete, set, init, etc...
-
-
-
-
-
OtherModelOrPrimitiveType
- if your class has a model list or primitive type list parameter. But if you specify a different model or primitive type inFromNamed
then there is no point in specifying that. If you add the same "Model" to your "ListModel" then there is no point in specifying this
-
-
-
-
-
- (WhereNamed) - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
ParameterNamed
- what global variables were used ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - operationOtherModelOrPrimitiveTypeWhereNamedFromOneParameterOne))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
- Bool:
-
-
- isWhereNamed
ParameterNamed
:
- isWhereNamed
-
-
-
-
- [] - if available
-
-
-
-
-
- isWhereNamed - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
ParameterNamed
- what global variables were used ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - isWhereNamedFromOneParametersTwo))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
-
-
- Local variable name - isWhereNamed
ParameterNamed
- Local variable name - isWhereNamed
-
-
NamedService
- Methods names:
-
- Get:
-
-
- get(Named)(WhereNamed)
ParameterNamed
:
- get(Named)(WhereNamed)
-
-
-
-
- () - optional
-
-
-
-
-
- [] - if available
-
-
-
-
-
- get - required word
-
-
-
-
-
- (Named) - we get primitive type or another model or briefly describe what we are taking
-
-
-
-
-
- (WhereNamed) - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
ParameterNamed
- what global variables were used ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - getNamedWhereNamedFromOneParametersTwo))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
-
-
- Local variable name - named(WhereNamed)
ParameterNamed
- Local variable name - named(WhereNamed)
-
-
-
- Void:
-
-
- operation
OtherModelOrPrimitiveType
(WhereNamed)ParameterNamed
- operation
-
-
-
-
- () - optional
-
-
-
-
-
- [] - if available
-
-
-
-
-
- operation - insert, update, delete, set, init, etc...
-
-
-
-
-
OtherModelOrPrimitiveType
- if your class has a model list or primitive type list parameter. But if you specify a different model or primitive type inFromNamed
then there is no point in specifying that. If you add the same "Model" to your "ListModel" then there is no point in specifying this
-
-
-
-
-
- (WhereNamed) - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
ParameterNamed
- what global variables were used ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - operationOtherModelOrPrimitiveTypeWhereNamedFromOneParameterOne))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
- Bool:
-
-
- isWhereNamed
ParameterNamed
:
- isWhereNamed
-
-
-
-
- [] - if available
-
-
-
-
-
- isWhereNamed - describe in as much detail as possible what this method does ( And - for iteration)
-
-
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
-
-
ParameterNamed
- what global variables were used ( And - for iteration)
-
-
-
-
-
- Method name length - no more than 100 characters (if more than 100, then use numbers (Example - isWhereNamedFromOneParametersTwo))
-
-
-
-
-
- Regarding duplicates - at the end add 'First', 'Second', etc...
-
-
-
-
-
- Local variable name - isWhereNamed
ParameterNamed
- Local variable name - isWhereNamed
-
-
ModelRepository
- Inheritance classes:
-
- Names of inherited classes:
-
-
- ModelNumberRepository:
-
-
-
-
- Number - 'First','Second','Third', etc...
-
-
-
- Inheritance goes along one branch:
-
-
- UserRepository -> UserFirstRepository -> UserSecondRepository -> UserThirdRepository
-
-
- When inheriting, we also inherit:
-
-
- 'Model'
-
-
-
- 'ListModel'
-
-
-
- 'ModelWNamedWNamedWNamedIterator' if exists
-
- Methods names:
-
- OperationModel(WhereNamed)
FromNamed
ParameterNamed:
- OperationModel(WhereNamed)
-
-
- () - optional
-
-
-
- [] - if available
-
-
-
- Operation - insert, update, delete, set, init, etc...
-
-
-
- Model - name model
-
-
-
- (WhereNamed) - describe in as much detail as possible what this class does ( And - for iteration)
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
- ParameterNamed - services and other parameters ( And - for iteration)
-
-
-
- Local variable names - operationModel(WhereNamed)
FromNamed
ParameterNamed
- Local variable names - operationModel(WhereNamed)
-
-
- OperationModel(WhereNamed)
FromNamed
ParameterNumber:
- OperationModel(WhereNamed)
-
-
- () - optional
-
-
-
- [] - if available
-
-
-
- Operation - insert, update, delete, set, init, etc...
-
-
-
- Model - name model
-
-
-
- (WhereNamed) - describe in as much detail as possible what this class does ( And - for iteration)
-
-
-
FromNamed
- if the method has parameters, then list ( And - for iteration)
-
-
-
- ParameterNumber - when a service or other parameters are still unknown, at the initial stage of development, we designate it with a number; the more services and other parameters, the larger the number. In the future we will not need to refactor the class
-
-
-
- Local variable names - operationModel(WhereNamed)
FromNamed
ParameterNumber
- Local variable names - operationModel(WhereNamed)
-
- Additional names of methods that are needed by the main method:
-
- OperationModel(WhereNamed)
FromNamed
ParameterNamedWReleaseCallback:
- OperationModel(WhereNamed)
-
-
- See the example to understand exactly how these methods should be written and how to use them.
-
-
- OperationModel(WhereNamed)
FromNamed
ParameterNamedWTestCallback:
- OperationModel(WhereNamed)
-
-
- See the example to understand exactly how these methods should be written and how to use them.
-
-
- OperationModel(WhereNamed)
FromNamed
ParameterNamedWListKeys:
- OperationModel(WhereNamed)
-
-
- See the example to understand exactly how these methods should be written and how to use them.
-
-
- OperationModel(WhereNamed)
FromNamed
ParameterNumberWReleaseCallback:
- OperationModel(WhereNamed)
-
-
- See the example to understand exactly how these methods should be written and how to use them.
-
-
- OperationModel(WhereNamed)
FromNamed
ParameterNumberWTestCallback:
- OperationModel(WhereNamed)
-
-
- See the example to understand exactly how these methods should be written and how to use them.
-
-
- OperationModel(WhereNamed)
FromNamed
ParameterNumberWListKeys:
- OperationModel(WhereNamed)
-
-
- See the example to understand exactly how these methods should be written and how to use them.
-
Design Patterns
- Design patterns used in 'LAMM' (-Design Patterns/--Classes):
-
- Observer:
-
-
- BaseNamedStreamWState
-
-
-
- DefaultStreamWState
-
-
- Similar to 'Pub/Sub':
-
-
- TempCacheService
-
-
- Singleton:
-
-
- TempCacheService
-
-
- Factory method:
-
-
- BaseModelWNamedWNamedWNamedIterator
-
-
-
- BaseException
-
-
-
- BaseModelRepository
-
-
- Prototype:
-
-
- BaseModel
-
-
-
- BaseListModel
-
-
- Similar to 'Adapter':
-
-
- ExceptionController
-
-
- Similar to 'Strategy':
-
-
- EnumRWTMode
-
-
-
- BaseModelRepository
-
Software Architecture Evaluation Theory
- We need to understand which classes to inherit and which classes to refactor, because if we inherit everything, we will waste a lot of time making the bodies of all methods abstract (i.e., encapsulate the code in the second methods), and If we refactor everything, we will lose the quality of the code, and this will lead to errors in the program, so it is necessary to balance between inheritance and refactoring
- Refactoring Of Architectural Components (ROAC):
-
- Code rules
- Inheritance Of Architectural Components (IOAC):
-
- SOLID principles
-
- Design Patterns
-
- Code rules
- Calculation formula:
-
- Inaccurate calculation
-
- Input:
-
-
- ROAC = 4 (NamedUtility, NamedVM, DataForNamed, NamedService)
-
-
-
- IOAC = 3 (Model, ListModel, ModelRepository)
-
-
-
-
- Formula:
-
-
-
-
-
-
- IOAC / (ROAC + IOAC) * 100 = 43%:
-
-
-
-
-
-
-
-
- 0-30% or 70-100% - this is bad
-
-
-
-
-
-
-
-
-
- 50-55% - it's perfect
-
-
-
-
- Note: We take into account that inheritance and refactoring must be correctly implemented, and the program must combine everything necessary, otherwise your architecture will not be able to take part in the evaluation, since it does not meet the needs of modern applications
Libraries
- library_architecture_mvvm_modify
- We load all other files into this file, and then use it in the application where we need it Where to use ? - Anywhere