Skip to content
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

Reduce IConvertableToPath and String used for properties to a single common type #2223

Open
homedirectory opened this issue Mar 28, 2024 · 0 comments · May be fixed by #2226
Open

Reduce IConvertableToPath and String used for properties to a single common type #2223

homedirectory opened this issue Mar 28, 2024 · 0 comments · May be fixed by #2226

Comments

@homedirectory
Copy link
Contributor

homedirectory commented Mar 28, 2024

Description

Paths of entity properties can be represented in 2 ways:

  • via the traditional String
  • via the compile-time safe IConvertableToPath

Due to the existence of 2 separate representations, it has been necessary to create 2 respective method signatures whenever the method needed to accept property paths as arguments.

It is proposed to eliminate this necessity by reducing these 2 types to a single common type that can represent property paths: java.lang.CharSequence.
Since String already implements CharSequence, this will only require IConvertableToPath to implement CharSequence.

This API change will also require recompilation of additional dependencies beside the TG applications, such as JMC.

Expected outcome

Method signatures declaring parameter types String and IConvertableToPath that represent properties are reduced to a single signature declaring CharSequence.

@homedirectory homedirectory self-assigned this Mar 28, 2024
homedirectory added a commit that referenced this issue Mar 29, 2024
…ath` by a single signature with `CharSequence`
homedirectory added a commit that referenced this issue Apr 1, 2024
homedirectory added a commit that referenced this issue Apr 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant