Skip to content

Commit

Permalink
Add a message for printing the ID of referenced schema.
Browse files Browse the repository at this point in the history
  • Loading branch information
leadpony committed Feb 26, 2019
1 parent 586951a commit 6d0d464
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ enum Message {
INSPECT_SCHEMA,
READ_CATALOG,

SCHEMA_ID_FOUND,
SCHEMA_ID_MISSING,
SCHEMA_ID_INVALID,

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,7 @@ private void addReferencedSchema(Location location) {
console.print(INSPECT_SCHEMA, location);
URI id = identifySchema(location);
if (id != null) {
console.print(SCHEMA_ID_FOUND, id);
catalog.put(id, location);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,24 +17,22 @@
VALIDATE_SCHEMA=Validating the schema "{0}"...
VALIDATE_REFERENCED_SCHEMA=Validating the referenced schema "{0}"...
VALIDATE_INSTANCE=Validating the instance "{0}"...

INSPECT_SCHEMA=Inspecting the referenced schema "{0}"...
READ_CATALOG=Reading the catalog "{0}"...

SCHEMA_ID_FOUND=The schema has an ID of "{0}".
SCHEMA_ID_MISSING=The referenced schema does not contain an "$id" keyword at its root.
SCHEMA_ID_INVALID=The value of the "$id" keyword is not a valid URI.

READ_CATALOG=Reading the catalog "{0}"...

SCHEMA_VALID=No problem was found in the schema "{0}".
SCHEMA_INVALID=At least {1} problem(s) were found in the schema "{0}".

INSTANCE_VALID=No problem was found in the instance "{0}".
INSTANCE_INVALID=At least {1} problem(s) were found in the instance "{0}".

CATALOG_INVALID=At least {1} problem(s) were found in the catalog "{0}".

SCHEMA_NOT_FOUND=The schema file does not exist at "{0}".
INSTANCE_NOT_FOUND=The instance file does not exist at "{0}".
CATALOG_NOT_FOUND=The catalog file does not exist at "{0}".
SCHEMA_MALFORMED=The schema file is not formed correctly.\n{0}
INSTANCE_MALFORMED=The instance file is not formed correctly.\n{0}
CATALOG_MALFORMED=The catalog file is not formed correctly.\n{0}

PATH_OR_URL=path or URL

Expand All @@ -43,9 +41,9 @@ OPTION_MISSING=Required option "{0}" is not specified.
OPTION_ARGUMENT_MISSING=The option "{0}" needs an argument followed.
OPTION_ARGUMENT_INVALID=The argument "{1}" is invalid for the option "{0}".

SCHEMA_MALFORMED=The schema file is not formed correctly.\n{0}
INSTANCE_MALFORMED=The instance file is not formed correctly.\n{0}
CATALOG_MALFORMED=The catalog file is not formed correctly.\n{0}
SCHEMA_NOT_FOUND=The schema file does not exist at "{0}".
INSTANCE_NOT_FOUND=The instance file does not exist at "{0}".
CATALOG_NOT_FOUND=The catalog file does not exist at "{0}".

SCHEMA_FAILED=Program terminated due to schema failure.
CATALOG_FAILED=Program terminated due to catalog failure.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,19 +17,17 @@
VALIDATE_SCHEMA=\u30B9\u30AD\u30FC\u30DE\u3092\u691C\u8A3C\u3057\u3066\u3044\u307E\u3059...: "{0}"
VALIDATE_REFERENCED_SCHEMA=\u53C2\u7167\u30B9\u30AD\u30FC\u30DE\u3092\u691C\u8A3C\u3057\u3066\u3044\u307E\u3059...: "{0}"
VALIDATE_INSTANCE=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u691C\u8A3C\u3057\u3066\u3044\u307E\u3059...: "{0}"

INSPECT_SCHEMA=\u53C2\u7167\u30B9\u30AD\u30FC\u30DE\u3092\u78BA\u8A8D\u3057\u3066\u3044\u307E\u3059...: "{0}"
READ_CATALOG=\u30AB\u30BF\u30ED\u30B0\u3092\u8AAD\u307F\u8FBC\u307F\u4E2D\u3067\u3059...: "{0}"

SCHEMA_ID_FOUND=\u30B9\u30AD\u30FC\u30DE\u306EID\u306F"{0}"\u3067\u3059\u3002
SCHEMA_ID_MISSING=\u53C2\u7167\u30B9\u30AD\u30FC\u30DE\u304C\u30EB\u30FC\u30C8\u306B"$id"\u30AD\u30FC\u30EF\u30FC\u30C9\u3092\u6301\u3063\u3066\u3044\u307E\u305B\u3093\u3002
SCHEMA_ID_INVALID="$id"\u30AD\u30FC\u30EF\u30FC\u30C9\u306E\u5024\u304CURI\u3067\u306F\u3042\u308A\u307E\u305B\u3093\u3002

READ_CATALOG=\u30AB\u30BF\u30ED\u30B0\u3092\u8AAD\u307F\u8FBC\u307F\u4E2D\u3067\u3059...: "{0}"

SCHEMA_VALID=\u30B9\u30AD\u30FC\u30DE\u306B\u554F\u984C\u306F\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3067\u3057\u305F\u3002: "{0}"
SCHEMA_INVALID=\u30B9\u30AD\u30FC\u30DE\u306B\u5C11\u306A\u304F\u3068\u3082{1}\u500B\u306E\u554F\u984C\u304C\u898B\u3064\u304B\u308A\u307E\u3057\u305F\u3002: "{0}"

INSTANCE_VALID=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306B\u554F\u984C\u306F\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3067\u3057\u305F\u3002: "{0}"
INSTANCE_INVALID=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306B\u5C11\u306A\u304F\u3068\u3082{1}\u500B\u306E\u554F\u984C\u304C\u898B\u3064\u304B\u308A\u307E\u3057\u305F\u3002: "{0}"

CATALOG_INVALID=\u30AB\u30BF\u30ED\u30B0\u306B\u5C11\u306A\u304F\u3068\u3082{1}\u500B\u306E\u554F\u984C\u304C\u898B\u3064\u304B\u308A\u307E\u3057\u305F\u3002: "{0}"

SCHEMA_MALFORMED=\u30B9\u30AD\u30FC\u30DE\u30D5\u30A1\u30A4\u30EB\u304C\u6B63\u3057\u3044JSON\u5F62\u5F0F\u3067\u306F\u3042\u308A\u307E\u305B\u3093\u3002\n{0}
Expand Down

0 comments on commit 6d0d464

Please sign in to comment.