8000 immutable: Add support for bean-style accessors · Issue #33 · immutables/immutables · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
immutable: Add support for bean-style accessors #33
Closed
@bhamiltoncx

Description

@bhamiltoncx

Our code style currently depends on value types with accessors named "getFoo()" and builders with setters named "setFoo()".

I can emulate the getters in the generated types with @Value.Getters, but the top-level interface then isn't useful (it will be missing the getters).

I can't emulate the setters in generated builders as far as I can tell.

It'd be really nice if we could do something like:

@Value.Immutable
@Value.GettersAndSetters
public interface Type {
  int getFoo();
  String getBar();
}

which would generate an ImmutableType with getFoo() and getBar(), and an ImmutableType.Builder with setFoo() and setBar().

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0