null
java.lang.StackOverflowError
at gnu.trove.TObjectCanonicalHashingStrategy.computeHashCode(TObjectCanonicalHashingStrategy.java:8)
at com.intellij.util.containers.ConcurrentWeakKeySoftValueHashMap.createHardKey(ConcurrentWeakKeySoftValueHashMap.java:214)
at com.intellij.util.containers.ConcurrentWeakKeySoftValueHashMap.get(ConcurrentWeakKeySoftValueHashMap.java:222)
at com.intellij.util.containers.ConcurrentFactoryMap.get(ConcurrentFactoryMap.java:60)
at com.intellij.psi.impl.file.impl.ResolveScopeManagerImpl.getResolveScopeFromProviders(ResolveScopeManagerImpl.java:62)
at com.intellij.psi.impl.file.impl.ResolveScopeManagerImpl.getResolveScope(ResolveScopeManagerImpl.java:124)
at com.intellij.psi.impl.ResolveScopeManager.getElementResolveScope(ResolveScopeManager.java:51)
at com.intellij.psi.impl.PsiElementBase.getResolveScope(PsiElementBase.java:184)
at com.intellij.psi.impl.PsiClassImplUtil.withSubstitutors(PsiClassImplUtil.java:991)
at com.intellij.psi.impl.PsiClassImplUtil.getAllWithSubstitutorsByMap(PsiClassImplUtil.java:185)
at com.intellij.psi.impl.PsiClassImplUtil.getAllByMap(PsiClassImplUtil.java:190)
at com.intellij.psi.impl.PsiClassImplUtil.getAllFields(PsiClassImplUtil.java:74)
at com.intellij.psi.impl.compiled.ClsClassImpl.getAllFields(ClsClassImpl.java:259)
at com.linsage.Java2JsonAction.getFields(Java2JsonAction.java:74)
at com.linsage.Java2JsonAction.getFields(Java2JsonAction.java:107)
at com.linsage.Java2JsonAction.getFields(Java2JsonAction.java:107)
at com.linsage.Java2JsonAction.getFields(Java2JsonAction.java:107)
at com.linsage.Java2JsonAction.getFields(Java2JsonAction.java:107)
at com.linsage.Java2JsonAction.getFields(Java2JsonAction.java:107)
at com.linsage.Java2JsonAction.getFields(Java2JsonAction.java:107)
at com.linsage.Java2JsonAction.getFields(Java2JsonAction.java:107)
at com.linsage.Java2JsonAction.getFields(Java2JsonAction.java:107)
[etc]
Example class for conversion (a frame to test validation responses):
import javax.validation.constraints.*;
import java.math.BigDecimal;
import java.time.LocalDate;
import java.util.List;
public class ErrorRequest {
@AssertFalse
protected boolean assertFalse = false;
@AssertTrue
protected boolean assertTrue = true;
@DecimalMax("1")
protected BigDecimal decimalMax1 = new BigDecimal("1.00");
@DecimalMin("1")
protected BigDecimal decimalMin1 = new BigDecimal("1.00");
@Digits(integer = 1, fraction = 2)
protected BigDecimal digits = new BigDecimal("1.11");
@Email
protected String email = "someone@somewhere";
@Future
protected LocalDate future = LocalDate.now().plusDays(1);
@FutureOrPresent
protected LocalDate futureOfPresent = LocalDate.now();
@Past
protected LocalDate past = LocalDate.now().minusDays(1);
@PastOrPresent
protected LocalDate pastOfPresent = LocalDate.now();
@Max(1)
protected long max = 1;
@Min(1)
protected long min = 1;
@Negative
protected long negative = -1;
@NegativeOrZero
protected long negativeOrZero = -1;
@Positive
protected long positive = 1;
@PositiveOrZero
protected long positiveOrZero = 1;
@NotBlank
protected String notBlank = "non-blank-value";
@NotEmpty
protected List<String> notEmpty = List.of("item1", "item2");
@NotNull
protected String notNull = "non-null-value";
@Null
protected String nullValue = null;
@Pattern(regexp = "^p.*")
protected String pattern = "pattern-value";
@Size(max=2)
protected List<String> sizeMax2 = List.of("item1", "item2");
public boolean isAssertFalse() {
return assertFalse;
}
public void setAssertFalse(boolean assertFalse) {
this.assertFalse = assertFalse;
}
public boolean isAssertTrue() {
return assertTrue;
}
public void setAssertTrue(boolean assertTrue) {
this.assertTrue = assertTrue;
}
public BigDecimal getDecimalMax1() {
return decimalMax1;
}
public void setDecimalMax1(BigDecimal decimalMax1) {
this.decimalMax1 = decimalMax1;
}
public BigDecimal getDecimalMin1() {
return decimalMin1;
}
public void setDecimalMin1(BigDecimal decimalMin1) {
this.decimalMin1 = decimalMin1;
}
public BigDecimal getDigits() {
return digits;
}
public void setDigits(BigDecimal digits) {
this.digits = digits;
}
public String getEmail() {
return email;
}
public void setEmail(String email) {
this.email = email;
}
public LocalDate getFuture() {
return future;
}
public void setFuture(LocalDate future) {
this.future = future;
}
public LocalDate getFutureOfPresent() {
return futureOfPresent;
}
public void setFutureOfPresent(LocalDate futureOfPresent) {
this.futureOfPresent = futureOfPresent;
}
public LocalDate getPast() {
return past;
}
public void setPast(LocalDate past) {
this.past = past;
}
public LocalDate getPastOfPresent() {
return pastOfPresent;
}
public void setPastOfPresent(LocalDate pastOfPresent) {
this.pastOfPresent = pastOfPresent;
}
public long getMax() {
return max;
}
public void setMax(long max) {
this.max = max;
}
public long getMin() {
return min;
}
public void setMin(long min) {
this.min = min;
}
public long getNegative() {
return negative;
}
public void setNegative(long negative) {
this.negative = negative;
}
public long getNegativeOrZero() {
return negativeOrZero;
}
public void setNegativeOrZero(long negativeOrZero) {
this.negativeOrZero = negativeOrZero;
}
public long getPositive() {
return positive;
}
public void setPositive(long positive) {
this.positive = positive;
}
public long getPositiveOrZero() {
return positiveOrZero;
}
public void setPositiveOrZero(long positiveOrZero) {
this.positiveOrZero = positiveOrZero;
}
public String getNotBlank() {
return notBlank;
}
public void setNotBlank(String notBlank) {
this.notBlank = notBlank;
}
public List<String> getNotEmpty() {
return notEmpty;
}
public void setNotEmpty(List<String> notEmpty) {
this.notEmpty = notEmpty;
}
public String getNotNull() {
return notNull;
}
public void setNotNull(String notNull) {
this.notNull = notNull;
}
public String getNullValue() {
return nullValue;
}
public void setNullValue(String nullValue) {
this.nullValue = nullValue;
}
public String getPattern() {
return pattern;
}
public void setPattern(String pattern) {
this.pattern = pattern;
}
public List<String> getSizeMax2() {
return sizeMax2;
}
public void setSizeMax2(List<String> sizeMax2) {
this.sizeMax2 = sizeMax2;
}
}
In idea 2018.1.3:
Example class for conversion (a frame to test validation responses):