{"action":"created","issue":{"url":"https://api.github.com/repos/yegor256/takes/issues/284","labels_url":"https://api.github.com/repos/yegor256/takes/issues/284/labels{/name}","comments_url":"https://api.github.com/repos/yegor256/takes/issues/284/comments","events_url":"https://api.github.com/repos/yegor256/takes/issues/284/events","html_url":"https://github.com/yegor256/takes/issues/284","id":76181711,"number":284,"title":"FkAgent","user":{"login":"yegor256","id":526301,"avatar_url":"https://avatars.githubusercontent.com/u/526301?v=3","gravatar_id":"","url":"https://api.github.com/users/yegor256","html_url":"https://github.com/yegor256","followers_url":"https://api.github.com/users/yegor256/followers","following_url":"https://api.github.com/users/yegor256/following{/other_user}","gists_url":"https://api.github.com/users/yegor256/gists{/gist_id}","starred_url":"https://api.github.com/users/yegor256/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yegor256/subscriptions","organizations_url":"https://api.github.com/users/yegor256/orgs","repos_url":"https://api.github.com/users/yegor256/repos","events_url":"https://api.github.com/users/yegor256/events{/privacy}","received_events_url":"https://api.github.com/users/yegor256/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-05-14T00:56:48Z","updated_at":"2015-07-10T17:23:13Z","closed_at":null,"body":"Let's create a new \"fork\" `org.takes.facets.fork.agent.FkAgent`, which will make a decision based on `User-Agent` HTTP header, if it's present:\r\n\r\n```java\r\nnew FkAgent(\r\n  take, // or fork\r\n  new AmOr(\r\n    new AmVersion(\r\n      \"Chrome\", \">11.0\"\r\n    )\r\n  )\r\n);\r\n```\r\n\r\nHere is how `AgentMatch` interface should look like:\r\n\r\n```java\r\ninterface AgentMatch {\r\n  boolean matches(String token, String version, String comment);\r\n}\r\n```\r\n\r\nFor example, in this `User-Agent` string:\r\n\r\n```\r\nMozilla/5.0 (Linux; U; Android 4.0.3; de-ch; HTC Sensation Build/IML74K) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30\r\n```\r\n\r\nWe have these token:\r\n\r\n```\r\nMozilla/5.0 (Linux; U; Android 4.0.3; de-ch; HTC Sensation Build/IML74K)\r\nAppleWebKit/534.30 (KHTML, like Gecko)\r\nVersion/4.0\r\nMobile\r\nSafari/534.30\r\n```"},"comment":{"url":"https://api.github.com/repos/yegor256/takes/issues/comments/120464872","html_url":"https://github.com/yegor256/takes/issues/284#issuecomment-120464872","issue_url":"https://api.github.com/repos/yegor256/takes/issues/284","id":120464872,"user":{"login":"davvd","id":6305016,"avatar_url":"https://avatars.githubusercontent.com/u/6305016?v=3","gravatar_id":"","url":"https://api.github.com/users/davvd","html_url":"https://github.com/davvd","followers_url":"https://api.github.com/users/davvd/followers","following_url":"https://api.github.com/users/davvd/following{/other_user}","gists_url":"https://api.github.com/users/davvd/gists{/gist_id}","starred_url":"https://api.github.com/users/davvd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davvd/subscriptions","organizations_url":"https://api.github.com/users/davvd/orgs","repos_url":"https://api.github.com/users/davvd/repos","events_url":"https://api.github.com/users/davvd/events{/privacy}","received_events_url":"https://api.github.com/users/davvd/received_events","type":"User","site_admin":false},"created_at":"2015-07-10T17:23:13Z","updated_at":"2015-07-10T17:23:13Z","body":"> @davvd let's postpone this for now\n\n@yegor256 OK, we'll postpone it"}}