-
Notifications
You must be signed in to change notification settings - Fork 32
Feature/size and not empty annotation diagnostics #1410
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
Merged
venmanyarun
merged 11 commits into
OpenLiberty:lsp4jakarta-0.2.5-integration
from
Rejoice472:sizAndNotEmpty
Oct 23, 2025
Merged
Changes from all commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
664c150
Introduced validation for size and notEmpty
Rejoice472 48a6039
Update messages.properties
Rejoice472 c3b35e3
size and notEmpty test cases
Rejoice472 5d9b4c3
size and notEmpty test resources
Rejoice472 a96dbb2
pr comments
Rejoice472 a32d502
Update BeanValidationTest.java
Rejoice472 15c417c
corrected diagnostics grammer
Rejoice472 24f8c6e
pr comments
Rejoice472 6e6c09b
pr comments addressed
Rejoice472 1609554
PR comments
Rejoice472 0836782
Merge branch 'lsp4jakarta-0.2.5-integration' into sizAndNotEmpty
Rejoice472 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
40 changes: 40 additions & 0 deletions
40
src/main/java/io/openliberty/tools/intellij/lsp4jakarta/lsp4ij/DiagnosticsUtils.java
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,40 @@ | ||
| /******************************************************************************* | ||
| * Copyright (c) 2025 IBM Corporation | ||
| * | ||
| * This program and the accompanying materials are made available under the | ||
| * terms of the Eclipse Public License v. 2.0 which is available at | ||
| * http://www.eclipse.org/legal/epl-2.0. | ||
| * | ||
| * SPDX-License-Identifier: EPL-2.0 | ||
| * | ||
| * Contributors: | ||
| * IBM Corporation - initial API and implementation | ||
| *******************************************************************************/ | ||
|
|
||
| package io.openliberty.tools.intellij.lsp4jakarta.lsp4ij; | ||
|
|
||
| import com.intellij.openapi.project.Project; | ||
| import com.intellij.psi.*; | ||
| import com.intellij.psi.search.GlobalSearchScope; | ||
|
|
||
| /** | ||
| * Utility class for common IntelliJ PSI-based diagnostic logic. | ||
| */ | ||
| public class DiagnosticsUtils { | ||
|
|
||
| /** | ||
| * inheritsFrom | ||
| * Check if specified superType is present or not in the type hierarchy | ||
| * | ||
| * @param clazz | ||
| * @param fqSuperType | ||
| * @return | ||
| */ | ||
| public static boolean inheritsFrom(PsiClass clazz, String fqSuperType) { | ||
| Project project = clazz.getProject(); | ||
| PsiClass superClass = JavaPsiFacade.getInstance(project) | ||
| .findClass(fqSuperType, GlobalSearchScope.allScope(project)); | ||
| return superClass != null && | ||
| (clazz.isEquivalentTo(superClass) || clazz.isInheritor(superClass, true)); | ||
| } | ||
| } |
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.