GitHub PullRequestReviewCommentEvent at 2014-09-12 05:24:59
Repository: maestro
Actor: stephanh
Payload: {"action":"created","comment":{"url":"https://api.github.com/repos/CommBank/maestro/pulls/comments/17463514","id":17463514,"diff_hunk":"@@ -0,0 +1,200 @@\n+//   Copyright 2014 Commonwealth Bank of Australia\n+//\n+//   Licensed under the Apache License, Version 2.0 (the \"License\");\n+//   you may not use this file except in compliance with the License.\n+//   You may obtain a copy of the License at\n+//\n+//     http://www.apache.org/licenses/LICENSE-2.0\n+//\n+//   Unless required by applicable law or agreed to in writing, software\n+//   distributed under the License is distributed on an \"AS IS\" BASIS,\n+//   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n+//   See the License for the specific language governing permissions and\n+//   limitations under the License.\n+package au.com.cba.omnia.maestro.schema\n+\n+import scala.collection.immutable._\n+\n+import au.com.cba.omnia.maestro.schema.syntax._\n+\n+\n+/** A concrete syntax that we identify as something more specific than \n+ *  a random collection of characters.\n+ * \n+ *  A syntax may describe a single Tope, though each Tope can have many syntaxes.\n+ *\n+ *  A syntax may not describe a Tope at all. For example, if some field is \n+ *  always a collection of digits then we identify that as a specific syntax \n+ *  without knowing what external entity it refers to.\n+ */\n+abstract class Syntax \n+{\n+  /** Printable name for a syntax.\n+      This can be displayed to the user, as well as used for a key for maps. */\n+  def name: String\n+\n+  /** Sort order to use when printing schemas.\n+      Lower is earlier. */\n+  def sortOrder: Int\n+    = 0\n+\n+  /** Yield how well the syntax matches this String.\n+   *  In the range [0.0, 1.0].\n+   *  If 0.0 it definately does not match, if 1.0 it definately does. */\n+  def likeness(s: String): Double\n+\n+  /** Check if this string completely matches the Tope, or not. */\n+  def matches(s: String): Boolean\n+    = likeness(s) >= 1.0\n+\n+  /** If this syntax matches the given string, then so do these parent syntaxes.\n+   *  This information is used in the squashParents process, to remove\n+   *  parent nodes where there is a child node with the same count. */\n+  val parents: Set[Syntax]\n+\n+  /** These child syntaxes are non-overlapping and completely partition\n+   * this parent syntax.\n+   * This information is used in the squashPartitions process, to remove\n+   * child nodes that exactly partition a parent node. */\n+  val partitions: Set[Syntax]\n+\n+  /** Values that match this syntax are guaranteed not to match \n+      with any other syntax. */\n+  val isolate: Boolean\n+    = false\n+\n+}\n+\n+\n+/** All the syntaxes we support, and functions on them. */\n+object Syntaxes\n+{\n+  /** All the generic syntaxes that we know about.\n+   *  These are standard formats and encodings, that we use when we can't\n+   *  identify what Tope a String refers to. */\n+  val syntaxes  = Array(\n+    Any,\n+    Empty,\n+    Null,\n+    White,\n+    Upper,\n+    Lower,\n+    Alpha,\n+    AlphaNum,\n+    Integer,\n+    Nat,\n+    NegInt, \n+    Real,\n+    NegReal,\n+    PosReal,\n+\n+    // Null disasters.\n+    Exact(\"NULL\"),\n+    Exact(\"null\"),\n+\n+    // Stupid placeholders.","path":"maestro-schema/src/main/scala/au/com/cba/omnia/maestro/schema/Syntax.scala","position":95,"original_position":95,"commit_id":"e00797fe12e12a8090f90cf478ef61b8911f3e7b","original_commit_id":"e00797fe12e12a8090f90cf478ef61b8911f3e7b","user":{"login":"stephanh","id":376868,"avatar_url":"https://avatars.githubusercontent.com/u/376868?v=2","gravatar_id":"788a9ad3374370466f62f8003abad77b","url":"https://api.github.com/users/stephanh","html_url":"https://github.com/stephanh","followers_url":"https://api.github.com/users/stephanh/followers","following_url":"https://api.github.com/users/stephanh/following{/other_user}","gists_url":"https://api.github.com/users/stephanh/gists{/gist_id}","starred_url":"https://api.github.com/users/stephanh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stephanh/subscriptions","organizations_url":"https://api.github.com/users/stephanh/orgs","repos_url":"https://api.github.com/users/stephanh/repos","events_url":"https://api.github.com/users/stephanh/events{/privacy}","received_events_url":"https://api.github.com/users/stephanh/received_events","type":"User","site_admin":false},"body":"I love these comments :smile:.","created_at":"2014-09-12T05:24:59Z","updated_at":"2014-09-12T05:24:59Z","html_url":"https://github.com/CommBank/maestro/pull/173#discussion_r17463514","pull_request_url":"https://api.github.com/repos/CommBank/maestro/pulls/173","_links":{"self":{"href":"https://api.github.com/repos/CommBank/maestro/pulls/comments/17463514"},"html":{"href":"https://github.com/CommBank/maestro/pull/173#discussion_r17463514"},"pull_request":{"href":"https://api.github.com/repos/CommBank/maestro/pulls/173"}}},"pull_request":{"url":"https://api.github.com/repos/CommBank/maestro/pulls/173","id":21068224,"html_url":"https://github.com/CommBank/maestro/pull/173","diff_url":"https://github.com/CommBank/maestro/pull/173.diff","patch_url":"https://github.com/CommBank/maestro/pull/173.patch","issue_url":"https://api.github.com/repos/CommBank/maestro/issues/173","number":173,"state":"open","locked":false,"title":"Add schemas code","user":{"login":"benl23x5","id":515656,"avatar_url":"https://avatars.githubusercontent.com/u/515656?v=2","gravatar_id":"8f55a6b2bd66d75384b77cd98ec8185d","url":"https://api.github.com/users/benl23x5","html_url":"https://github.com/benl23x5","followers_url":"https://api.github.com/users/benl23x5/followers","following_url":"https://api.github.com/users/benl23x5/following{/other_user}","gists_url":"https://api.github.com/users/benl23x5/gists{/gist_id}","starred_url":"https://api.github.com/users/benl23x5/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benl23x5/subscriptions","organizations_url":"https://api.github.com/users/benl23x5/orgs","repos_url":"https://api.github.com/users/benl23x5/repos","events_url":"https://api.github.com/users/benl23x5/events{/privacy}","received_events_url":"https://api.github.com/users/benl23x5/received_events","type":"User","site_admin":false},"body":"","created_at":"2014-09-11T06:09:17Z","updated_at":"2014-09-12T05:24:59Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f2af76a2f57d7b1b8ff05bec36354b515a7554b7","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/CommBank/maestro/pulls/173/commits","review_comments_url":"https://api.github.com/repos/CommBank/maestro/pulls/173/comments","review_comment_url":"https://api.github.com/repos/CommBank/maestro/pulls/comments/{number}","comments_url":"https://api.github.com/repos/CommBank/maestro/issues/173/comments","statuses_url":"https://api.github.com/repos/CommBank/maestro/statuses/e00797fe12e12a8090f90cf478ef61b8911f3e7b","head":{"label":"CommBank:schemasquash","ref":"schemasquash","sha":"e00797fe12e12a8090f90cf478ef61b8911f3e7b","user":{"login":"CommBank","id":4240076,"avatar_url":"https://avatars.githubusercontent.com/u/4240076?v=2","gravatar_id":"89f708e8d47ed24762e84ba83347a044","url":"https://api.github.com/users/CommBank","html_url":"https://github.com/CommBank","followers_url":"https://api.github.com/users/CommBank/followers","following_url":"https://api.github.com/users/CommBank/following{/other_user}","gists_url":"https://api.github.com/users/CommBank/gists{/gist_id}","starred_url":"https://api.github.com/users/CommBank/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CommBank/subscriptions","organizations_url":"https://api.github.com/users/CommBank/orgs","repos_url":"https://api.github.com/users/CommBank/repos","events_url":"https://api.github.com/users/CommBank/events{/privacy}","received_events_url":"https://api.github.com/users/CommBank/received_events","type":"Organization","site_admin":false},"repo":{"id":17347463,"name":"maestro","full_name":"CommBank/maestro","owner":{"login":"CommBank","id":4240076,"avatar_url":"https://avatars.githubusercontent.com/u/4240076?v=2","gravatar_id":"89f708e8d47ed24762e84ba83347a044","url":"https://api.github.com/users/CommBank","html_url":"https://github.com/CommBank","followers_url":"https://api.github.com/users/CommBank/followers","following_url":"https://api.github.com/users/CommBank/following{/other_user}","gists_url":"https://api.github.com/users/CommBank/gists{/gist_id}","starred_url":"https://api.github.com/users/CommBank/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CommBank/subscriptions","organizations_url":"https://api.github.com/users/CommBank/orgs","repos_url":"https://api.github.com/users/CommBank/repos","events_url":"https://api.github.com/users/CommBank/events{/privacy}","received_events_url":"https://api.github.com/users/CommBank/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/CommBank/maestro","description":"Data Pipelines that are well typed and enforce good convention","fork":false,"url":"https://api.github.com/repos/CommBank/maestro","forks_url":"https://api.github.com/repos/CommBank/maestro/forks","keys_url":"https://api.github.com/repos/CommBank/maestro/keys{/key_id}","collaborators_url":"https://api.github.com/repos/CommBank/maestro/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/CommBank/maestro/teams","hooks_url":"https://api.github.com/repos/CommBank/maestro/hooks","issue_events_url":"https://api.github.com/repos/CommBank/maestro/issues/events{/number}","events_url":"https://api.github.com/repos/CommBank/maestro/events","assignees_url":"https://api.github.com/repos/CommBank/maestro/assignees{/user}","branches_url":"https://api.github.com/repos/CommBank/maestro/branches{/branch}","tags_url":"https://api.github.com/repos/CommBank/maestro/tags","blobs_url":"https://api.github.com/repos/CommBank/maestro/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/CommBank/maestro/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/CommBank/maestro/git/refs{/sha}","trees_url":"https://api.github.com/repos/CommBank/maestro/git/trees{/sha}","statuses_url":"https://api.github.com/repos/CommBank/maestro/statuses/{sha}","languages_url":"https://api.github.com/repos/CommBank/maestro/languages","stargazers_url":"https://api.github.com/repos/CommBank/maestro/stargazers","contributors_url":"https://api.github.com/repos/CommBank/maestro/contributors","subscribers_url":"https://api.github.com/repos/CommBank/maestro/subscribers","subscription_url":"https://api.github.com/repos/CommBank/maestro/subscription","commits_url":"https://api.github.com/repos/CommBank/maestro/commits{/sha}","git_commits_url":"https://api.github.com/repos/CommBank/maestro/git/commits{/sha}","comments_url":"https://api.github.com/repos/CommBank/maestro/comments{/number}","issue_comment_url":"https://api.github.com/repos/CommBank/maestro/issues/comments/{number}","contents_url":"https://api.github.com/repos/CommBank/maestro/contents/{+path}","compare_url":"https://api.github.com/repos/CommBank/maestro/compare/{base}...{head}","merges_url":"https://api.github.com/repos/CommBank/maestro/merges","archive_url":"https://api.github.com/repos/CommBank/maestro/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/CommBank/maestro/downloads","issues_url":"https://api.github.com/repos/CommBank/maestro/issues{/number}","pulls_url":"https://api.github.com/repos/CommBank/maestro/pulls{/number}","milestones_url":"https://api.github.com/repos/CommBank/maestro/milestones{/number}","notifications_url":"https://api.github.com/repos/CommBank/maestro/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/CommBank/maestro/labels{/name}","releases_url":"https://api.github.com/repos/CommBank/maestro/releases{/id}","created_at":"2014-03-02T21:34:53Z","updated_at":"2014-09-02T14:32:54Z","pushed_at":"2014-09-12T04:15:27Z","git_url":"git://github.com/CommBank/maestro.git","ssh_url":"git@github.com:CommBank/maestro.git","clone_url":"https://github.com/CommBank/maestro.git","svn_url":"https://github.com/CommBank/maestro","homepage":"https://commbank.github.io/maestro","size":10745,"stargazers_count":14,"watchers_count":14,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":true,"forks_count":7,"mirror_url":null,"open_issues_count":58,"forks":7,"open_issues":58,"watchers":14,"default_branch":"master"}},"base":{"label":"CommBank:master","ref":"master","sha":"ac9ad1f5ac07a463ba3a08ec7c5807611ebbf6cb","user":{"login":"CommBank","id":4240076,"avatar_url":"https://avatars.githubusercontent.com/u/4240076?v=2","gravatar_id":"89f708e8d47ed24762e84ba83347a044","url":"https://api.github.com/users/CommBank","html_url":"https://github.com/CommBank","followers_url":"https://api.github.com/users/CommBank/followers","following_url":"https://api.github.com/users/CommBank/following{/other_user}","gists_url":"https://api.github.com/users/CommBank/gists{/gist_id}","starred_url":"https://api.github.com/users/CommBank/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CommBank/subscriptions","organizations_url":"https://api.github.com/users/CommBank/orgs","repos_url":"https://api.github.com/users/CommBank/repos","events_url":"https://api.github.com/users/CommBank/events{/privacy}","received_events_url":"https://api.github.com/users/CommBank/received_events","type":"Organization","site_admin":false},"repo":{"id":17347463,"name":"maestro","full_name":"CommBank/maestro","owner":{"login":"CommBank","id":4240076,"avatar_url":"https://avatars.githubusercontent.com/u/4240076?v=2","gravatar_id":"89f708e8d47ed24762e84ba83347a044","url":"https://api.github.com/users/CommBank","html_url":"https://github.com/CommBank","followers_url":"https://api.github.com/users/CommBank/followers","following_url":"https://api.github.com/users/CommBank/following{/other_user}","gists_url":"https://api.github.com/users/CommBank/gists{/gist_id}","starred_url":"https://api.github.com/users/CommBank/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CommBank/subscriptions","organizations_url":"https://api.github.com/users/CommBank/orgs","repos_url":"https://api.github.com/users/CommBank/repos","events_url":"https://api.github.com/users/CommBank/events{/privacy}","received_events_url":"https://api.github.com/users/CommBank/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/CommBank/maestro","description":"Data Pipelines that are well typed and enforce good convention","fork":false,"url":"https://api.github.com/repos/CommBank/maestro","forks_url":"https://api.github.com/repos/CommBank/maestro/forks","keys_url":"https://api.github.com/repos/CommBank/maestro/keys{/key_id}","collaborators_url":"https://api.github.com/repos/CommBank/maestro/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/CommBank/maestro/teams","hooks_url":"https://api.github.com/repos/CommBank/maestro/hooks","issue_events_url":"https://api.github.com/repos/CommBank/maestro/issues/events{/number}","events_url":"https://api.github.com/repos/CommBank/maestro/events","assignees_url":"https://api.github.com/repos/CommBank/maestro/assignees{/user}","branches_url":"https://api.github.com/repos/CommBank/maestro/branches{/branch}","tags_url":"https://api.github.com/repos/CommBank/maestro/tags","blobs_url":"https://api.github.com/repos/CommBank/maestro/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/CommBank/maestro/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/CommBank/maestro/git/refs{/sha}","trees_url":"https://api.github.com/repos/CommBank/maestro/git/trees{/sha}","statuses_url":"https://api.github.com/repos/CommBank/maestro/statuses/{sha}","languages_url":"https://api.github.com/repos/CommBank/maestro/languages","stargazers_url":"https://api.github.com/repos/CommBank/maestro/stargazers","contributors_url":"https://api.github.com/repos/CommBank/maestro/contributors","subscribers_url":"https://api.github.com/repos/CommBank/maestro/subscribers","subscription_url":"https://api.github.com/repos/CommBank/maestro/subscription","commits_url":"https://api.github.com/repos/CommBank/maestro/commits{/sha}","git_commits_url":"https://api.github.com/repos/CommBank/maestro/git/commits{/sha}","comments_url":"https://api.github.com/repos/CommBank/maestro/comments{/number}","issue_comment_url":"https://api.github.com/repos/CommBank/maestro/issues/comments/{number}","contents_url":"https://api.github.com/repos/CommBank/maestro/contents/{+path}","compare_url":"https://api.github.com/repos/CommBank/maestro/compare/{base}...{head}","merges_url":"https://api.github.com/repos/CommBank/maestro/merges","archive_url":"https://api.github.com/repos/CommBank/maestro/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/CommBank/maestro/downloads","issues_url":"https://api.github.com/repos/CommBank/maestro/issues{/number}","pulls_url":"https://api.github.com/repos/CommBank/maestro/pulls{/number}","milestones_url":"https://api.github.com/repos/CommBank/maestro/milestones{/number}","notifications_url":"https://api.github.com/repos/CommBank/maestro/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/CommBank/maestro/labels{/name}","releases_url":"https://api.github.com/repos/CommBank/maestro/releases{/id}","created_at":"2014-03-02T21:34:53Z","updated_at":"2014-09-02T14:32:54Z","pushed_at":"2014-09-12T04:15:27Z","git_url":"git://github.com/CommBank/maestro.git","ssh_url":"git@github.com:CommBank/maestro.git","clone_url":"https://github.com/CommBank/maestro.git","svn_url":"https://github.com/CommBank/maestro","homepage":"https://commbank.github.io/maestro","size":10745,"stargazers_count":14,"watchers_count":14,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":true,"forks_count":7,"mirror_url":null,"open_issues_count":58,"forks":7,"open_issues":58,"watchers":14,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/CommBank/maestro/pulls/173"},"html":{"href":"https://github.com/CommBank/maestro/pull/173"},"issue":{"href":"https://api.github.com/repos/CommBank/maestro/issues/173"},"comments":{"href":"https://api.github.com/repos/CommBank/maestro/issues/173/comments"},"review_comments":{"href":"https://api.github.com/repos/CommBank/maestro/pulls/173/comments"},"review_comment":{"href":"https://api.github.com/repos/CommBank/maestro/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/CommBank/maestro/pulls/173/commits"},"statuses":{"href":"https://api.github.com/repos/CommBank/maestro/statuses/e00797fe12e12a8090f90cf478ef61b8911f3e7b"}}}}