Skip to content

Replace atom Symbol with Integer constant comparison - #827

Merged
egonw merged 15 commits into
masterfrom
patch/atomic-nums
Feb 8, 2022
Merged

Replace atom Symbol with Integer constant comparison#827
egonw merged 15 commits into
masterfrom
patch/atomic-nums

Conversation

@johnmay

@johnmay johnmay commented Feb 7, 2022

Copy link
Copy Markdown
Member

Gotta catch em all... I think I got the vast majority of them. Resolves #546

I do wonder longer (CDK v3.0/v4.0) term if may making it just store and compare the enum.

atom.setElement(Element.H);

Mainly because interface constants are a bit of a bad pattern but it is quite handy.

@johnmay

johnmay commented Feb 8, 2022

Copy link
Copy Markdown
Member Author

Will look at the sonar cloud issues - expected since this touched a lot of classes

…he original paper we see this is meant to be the SQRT(RADII) where this is different for each atom type.
@sonarqubecloud

sonarqubecloud Bot commented Feb 8, 2022

Copy link
Copy Markdown

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 13 Code Smells

0.0% 0.0% Coverage
11.6% 11.6% Duplication

@egonw

egonw commented Feb 8, 2022

Copy link
Copy Markdown
Member

Thanks. Looks good. This was not possible in the past, because atomic numbers were not automatically set.

@egonw
egonw merged commit 650002d into master Feb 8, 2022
@johnmay
johnmay deleted the patch/atomic-nums branch February 9, 2022 15:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Compare atomic number rather than symbol.

2 participants