eclipse-jdt / eclipse-jdt/eclipse.jdt.ui

Support other accessor styles besides traditional getter/setter (e.g. Record style)

Open
#69 0 comments 0 reactions 1 assignee Claimed by @jjohnstn View on GitHub
enhancement
Dominant language
Java
Stars
59
Forks
127
Avg merge
23h 30m
Merged PRs (30d)
35

Description

With Java now going more in the direction of Records and traditional Java Beans not as popular I have been seeing more desire to make accessor methods that do not follow the traditional get/set prefix.

Currently you can configure getter/setter body and comment style but you cannot configure the method names.

For example if I have a class like:

```java
public SomeClass {
private String name;

}
```

I would like to generate accessors just like a Record where there is no get or set:

```java
public SomeClass {
private String name;

public String name() { return this.name; }
public void name(String name) { this.name = name; }
}
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.