Skip to content
This repository has been archived by the owner on May 9, 2019. It is now read-only.

Ensure @Value annotation on immutable classes #46

Merged
merged 3 commits into from
Mar 8, 2017

Conversation

yg-apaza
Copy link
Contributor

Fixes #9

Copy link
Contributor

@ignasi35 ignasi35 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think replacing some code caused the API to change slightly.

@@ -10,6 +12,8 @@
/**
* The auction state.
*/
@Value
@Wither
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this @Wither added more methods than there where originally. Before this PR, only withStatus was available.


/**
*
*/
@Value
public class Query {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The classes modelling the API to ElasticSearch don't always need the @Value annotation.

@@ -1,11 +1,13 @@
package com.example.auction.transaction.api;

import java.util.UUID;
import lombok.Value;

public abstract class TransactionEvent {

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All the code in transaction-xxx is WIP and it'd be good to not add more complexity on it until we have a clear idea what is it we want to do with it.


@Value
public final class TransactionMessage {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See comment above


@Value
public final class TransactionInfo {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See comment above

@ignasi35
Copy link
Contributor

ignasi35 commented Mar 7, 2017

This clashes with #52

Copy link
Contributor

@TimMoore TimMoore left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, @yg-apaza. Just a couple of fixes to make to the whitespace formatting.

@@ -5,7 +5,7 @@
public abstract class TransactionEvent {

private TransactionEvent() {}

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like some extraneous whitespace changes snuck in.

Here are some instructions for configuring Eclipse to strip trailing whitespace on save: http://stackoverflow.com/a/14178860


import java.util.Optional;

public interface UserCommand extends Jsonable {
@Value
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like some files are indenting with tab characters instead of space characters.

Here are instructions for configuring Eclipse to use spaces instead of tabs: http://stackoverflow.com/a/408449

@yg-apaza
Copy link
Contributor Author

yg-apaza commented Mar 8, 2017

😅 I forgot to configure properly formatting in Eclipse, now I fixed it.

Copy link
Contributor

@TimMoore TimMoore left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@TimMoore
Copy link
Contributor

TimMoore commented Mar 8, 2017

@ignasi35 I'll let you have one last look before merging

libraryDependencies += lagomJavadslApi
libraryDependencies ++= Seq(
lagomJavadslApi,
lombok
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this dependency is not used ATM.

@ignasi35 ignasi35 merged commit 11a9613 into lagom:master Mar 8, 2017
@yg-apaza yg-apaza deleted the lombok branch March 9, 2017 00:52
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants