-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement setters and getters #21
Draft
afuno
wants to merge
11
commits into
main
Choose a base branch
from
features/SRV-111/setter_and_getter
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Added getter and setter Domain Specific Language (DSL) as features to the Datory framework. This change includes creation of new files for getter, setter, and their collection classes. Moreover, adjustments were made in the test files and examples to demonstrate the usage of these newly added features.
Changed attribute name 'formatted_title' to 'formattedTitle' in both product.rb file and product_spec.rb test file. The renaming is consistent with camelCase naming convention, improving readability and standardizing the codebase.
The find_by method in both the setters/collection.rb and getters/collection.rb files has been commented out and is no longer in use. This commit removes these unnecessary lines of code, thus cleaning up the codebase.
…ures/SRV-111/setter_and_getter # Conflicts: # lib/datory/context/workspace.rb
Moved the `add` method logic into a private method `define_setter` to enhance encapsulation within the `Model` class. Updated all usages of the `add` method to call `define_setter` instead, ensuring the setter is defined privately across different classes.
This commit introduces a new 'code' attribute to the season model, derived from the season number. Modifications include updating the schema and test cases to accommodate the new attribute. These changes ensure that each season has a unique code based on its number.
This new method extracts and returns the names from the `from` attributes within the collection. It complements the existing method that fetches the `to` names, enhancing the overall utility of attribute name extraction within the `Collection` class.
Refactor methods in Model and Callable to include `collection_of_attributes` for more robust attribute management. Adjust build method to handle additional attributes, ensuring complete initialization. Update related methods to pass and process `collection_of_attributes` accordingly.
Added comments to indicate that 'getter' methods are for deserialization and 'setter' methods are for serialization in product.rb and season.rb files. This enhances code readability and makes the purpose of these methods clearer.
Added the fullName attribute to language_spec.rb and language.rb to handle serialization and deserialization, ensuring that the full attribute details are included in the outputs and test cases. Also updated the descriptor to handle the presence of include_class correctly.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.