Skip to content

Instantly share code, notes, and snippets.

@kroepke
Created August 30, 2013 10:31
Show Gist options
  • Save kroepke/6388514 to your computer and use it in GitHub Desktop.
Save kroepke/6388514 to your computer and use it in GitHub Desktop.
graylog2 api class interface proposal
GetMessageResponse r0 = Api.get("/messages/" + index + "/" + id, GetMessageResponse.class);
GetMessageResponse r1 = Api.get("/messages/{0}/{1}", GetMessageResponse.class, index, id);
GetMessageResponse r2 = Api.get(GetMessageResponse.class)
.path("/messages/{0}/{1}")
.pathParams(index, id)
.execute();
@lennartkoopmann
Copy link

That's pretty nice stuff! :)

@lennartkoopmann
Copy link

Has this been pushed to master yet? Couldn't find anything and used the deprecated urlEncode for now. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment