{"action":"created","issue":{"url":"https://api.github.com/repos/SpongePowered/SpongeAPI/issues/577","labels_url":"https://api.github.com/repos/SpongePowered/SpongeAPI/issues/577/labels{/name}","comments_url":"https://api.github.com/repos/SpongePowered/SpongeAPI/issues/577/comments","events_url":"https://api.github.com/repos/SpongePowered/SpongeAPI/issues/577/events","html_url":"https://github.com/SpongePowered/SpongeAPI/pull/577","id":69274814,"number":577,"title":"[WIP] Revamp selectors","user":{"login":"kenzierocks","id":2093023,"avatar_url":"https://avatars.githubusercontent.com/u/2093023?v=3","gravatar_id":"","url":"https://api.github.com/users/kenzierocks","html_url":"https://github.com/kenzierocks","followers_url":"https://api.github.com/users/kenzierocks/followers","following_url":"https://api.github.com/users/kenzierocks/following{/other_user}","gists_url":"https://api.github.com/users/kenzierocks/gists{/gist_id}","starred_url":"https://api.github.com/users/kenzierocks/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kenzierocks/subscriptions","organizations_url":"https://api.github.com/users/kenzierocks/orgs","repos_url":"https://api.github.com/users/kenzierocks/repos","events_url":"https://api.github.com/users/kenzierocks/events{/privacy}","received_events_url":"https://api.github.com/users/kenzierocks/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/SpongePowered/SpongeAPI/labels/commands","name":"commands","color":"006E5E"},{"url":"https://api.github.com/repos/SpongePowered/SpongeAPI/labels/enhancement","name":"enhancement","color":"84b6eb"}],"state":"open","locked":false,"assignee":{"login":"zml2008","id":629092,"avatar_url":"https://avatars.githubusercontent.com/u/629092?v=3","gravatar_id":"","url":"https://api.github.com/users/zml2008","html_url":"https://github.com/zml2008","followers_url":"https://api.github.com/users/zml2008/followers","following_url":"https://api.github.com/users/zml2008/following{/other_user}","gists_url":"https://api.github.com/users/zml2008/gists{/gist_id}","starred_url":"https://api.github.com/users/zml2008/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zml2008/subscriptions","organizations_url":"https://api.github.com/users/zml2008/orgs","repos_url":"https://api.github.com/users/zml2008/repos","events_url":"https://api.github.com/users/zml2008/events{/privacy}","received_events_url":"https://api.github.com/users/zml2008/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/SpongePowered/SpongeAPI/milestones/3","html_url":"https://github.com/SpongePowered/SpongeAPI/milestones/Revision%202.1","labels_url":"https://api.github.com/repos/SpongePowered/SpongeAPI/milestones/3/labels","id":1006894,"number":3,"title":"Revision 2.1","description":"This is the first revision of the second stable revision of the Sponge API, 2.1.","creator":{"login":"Zidane","id":744482,"avatar_url":"https://avatars.githubusercontent.com/u/744482?v=3","gravatar_id":"","url":"https://api.github.com/users/Zidane","html_url":"https://github.com/Zidane","followers_url":"https://api.github.com/users/Zidane/followers","following_url":"https://api.github.com/users/Zidane/following{/other_user}","gists_url":"https://api.github.com/users/Zidane/gists{/gist_id}","starred_url":"https://api.github.com/users/Zidane/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Zidane/subscriptions","organizations_url":"https://api.github.com/users/Zidane/orgs","repos_url":"https://api.github.com/users/Zidane/repos","events_url":"https://api.github.com/users/Zidane/events{/privacy}","received_events_url":"https://api.github.com/users/Zidane/received_events","type":"User","site_admin":false},"open_issues":11,"closed_issues":5,"state":"open","created_at":"2015-03-05T02:35:45Z","updated_at":"2015-05-05T19:03:53Z","due_on":null,"closed_at":null},"comments":8,"created_at":"2015-04-18T06:19:19Z","updated_at":"2015-05-06T01:35:26Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/SpongePowered/SpongeAPI/pulls/577","html_url":"https://github.com/SpongePowered/SpongeAPI/pull/577","diff_url":"https://github.com/SpongePowered/SpongeAPI/pull/577.diff","patch_url":"https://github.com/SpongePowered/SpongeAPI/pull/577.patch"},"body":"Required revamp to make selectors implementable without lots of hacks. Requirement of SpongePowered/Sponge#243.\r\n\r\n#### More details\r\nThere was a problem with having `Vector3` as an `ArgumentType`. Because it was an `ArgumentType`  but it's `x/y/z` parts were also `ArgumentTypes` it was unclear which types would be put into the internal `ArgumentType->Argument` map. This resolves the ambiguity by adding an `ArgumentHolder` interface, which is extended by both `Vector3` and `Limit`. This interface is also extended by `ArgumentType`, as any `ArgumentType` \"holds\" itself. This also allows for `Limit` to have a more strict upper bound on its maximum and minimum to allow a `Limit<Vector3>`.\r\n\r\nAdditionally, `ArgumentType` was generic and not a part of the `CatalogType` system. This still holds, so `ArgumentTypes` now allows retrieval of an `ArgumentType` via `valueOf(String)` and the (current) set via `values()`.\r\n\r\n#### Summary\r\n- `Vector3` and `Limit` are now `ArgumentHolders`\r\n- `ArgumentType` also is a holder, with itself as the only element.\r\n- `ArgumentTypes` has `valueOf` and `values`\r\n- An `ArgumentHolder` can be passed to create a `Set` of arguments (although I think the implementation currently doesn't support using `Limit` as the holder).\r\n- Scoreboard is in Selectors (#516)\r\n- Probably a few other things"},"comment":{"url":"https://api.github.com/repos/SpongePowered/SpongeAPI/issues/comments/99282866","html_url":"https://github.com/SpongePowered/SpongeAPI/pull/577#issuecomment-99282866","issue_url":"https://api.github.com/repos/SpongePowered/SpongeAPI/issues/577","id":99282866,"user":{"login":"kenzierocks","id":2093023,"avatar_url":"https://avatars.githubusercontent.com/u/2093023?v=3","gravatar_id":"","url":"https://api.github.com/users/kenzierocks","html_url":"https://github.com/kenzierocks","followers_url":"https://api.github.com/users/kenzierocks/followers","following_url":"https://api.github.com/users/kenzierocks/following{/other_user}","gists_url":"https://api.github.com/users/kenzierocks/gists{/gist_id}","starred_url":"https://api.github.com/users/kenzierocks/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kenzierocks/subscriptions","organizations_url":"https://api.github.com/users/kenzierocks/orgs","repos_url":"https://api.github.com/users/kenzierocks/repos","events_url":"https://api.github.com/users/kenzierocks/events{/privacy}","received_events_url":"https://api.github.com/users/kenzierocks/received_events","type":"User","site_admin":false},"created_at":"2015-05-06T01:35:26Z","updated_at":"2015-05-06T01:35:26Z","body":"Added `has(ArgumentType)` and `isInverted(ArgumentType.Invertible)` for convenience, patched above gap."}}