diff options
author | Francois-Rene Rideau <tunes@google.com> | 2015-04-10 18:56:21 +0000 |
---|---|---|
committer | Lukacs Berki <lberki@google.com> | 2015-04-13 11:46:41 +0000 |
commit | 4a8da557b5878db1bcf66da32f48a0f97ca37e7a (patch) | |
tree | b3131bec195c9962ad96ddfa80b772b6946e96b4 /src/main/java/com/google/devtools/build/lib/rules/SkylarkRuleContext.java | |
parent | e6a46b82e8e4e402fc70848f761d5486d2316d8f (diff) |
Skylark builtin function cleanups
Clean up related to Skylark builtin functions.
Replace "hidden" field of some annotations with a "documented" field
(with reversed semantics).
--
MOS_MIGRATED_REVID=90827020
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/rules/SkylarkRuleContext.java')
-rw-r--r-- | src/main/java/com/google/devtools/build/lib/rules/SkylarkRuleContext.java | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/rules/SkylarkRuleContext.java b/src/main/java/com/google/devtools/build/lib/rules/SkylarkRuleContext.java index ec00b301ef..28eaf79401 100644 --- a/src/main/java/com/google/devtools/build/lib/rules/SkylarkRuleContext.java +++ b/src/main/java/com/google/devtools/build/lib/rules/SkylarkRuleContext.java @@ -407,7 +407,7 @@ public final class SkylarkRuleContext { return ruleContext.getLabel().toString(); } - @SkylarkCallable(doc = "Splits a shell command to a list of tokens.", hidden = true) + @SkylarkCallable(doc = "Splits a shell command to a list of tokens.", documented = false) public List<String> tokenize(String optionString) throws FuncallException { List<String> options = new ArrayList<>(); try { @@ -421,7 +421,7 @@ public final class SkylarkRuleContext { @SkylarkCallable(doc = "Expands all references to labels embedded within a string for all files using a mapping " + "from definition labels (i.e. the label in the output type attribute) to files. Deprecated.", - hidden = true) + documented = false) public String expand(@Nullable String expression, List<Artifact> artifacts, Label labelResolver) throws FuncallException { try { @@ -446,7 +446,7 @@ public final class SkylarkRuleContext { } // Kept for compatibility with old code. - @SkylarkCallable(hidden = true, doc = "") + @SkylarkCallable(documented = false) public Artifact newFile(Root root, String filename) { PathFragment fragment = ruleContext.getLabel().getPackageFragment(); for (String pathFragmentString : filename.split("/")) { @@ -465,19 +465,19 @@ public final class SkylarkRuleContext { } // Kept for compatibility with old code. - @SkylarkCallable(hidden = true, doc = "") + @SkylarkCallable(documented = false) public Artifact newFile(Root root, Artifact baseArtifact, String suffix) { PathFragment original = baseArtifact.getRootRelativePath(); PathFragment fragment = original.replaceName(original.getBaseName() + suffix); return ruleContext.getAnalysisEnvironment().getDerivedArtifact(fragment, root); } - @SkylarkCallable(doc = "", hidden = true) + @SkylarkCallable(documented = false) public NestedSet<Artifact> middleMan(String attribute) { return AnalysisUtils.getMiddlemanFor(ruleContext, attribute); } - @SkylarkCallable(doc = "", hidden = true) + @SkylarkCallable(documented = false) public boolean checkPlaceholders(String template, List<String> allowedPlaceholders) { List<String> actualPlaceHolders = new LinkedList<>(); Set<String> allowedPlaceholderSet = ImmutableSet.copyOf(allowedPlaceholders); @@ -527,14 +527,14 @@ public final class SkylarkRuleContext { return executableRunfilesMap.get(executable); } - @SkylarkCallable(name = "info_file", structField = true, hidden = true, + @SkylarkCallable(name = "info_file", structField = true, documented = false, doc = "Returns the file that is used to hold the non-volatile workspace status for the " + "current build request.") public Artifact getStableWorkspaceStatus() { return ruleContext.getAnalysisEnvironment().getStableWorkspaceStatusArtifact(); } - @SkylarkCallable(name = "version_file", structField = true, hidden = true, + @SkylarkCallable(name = "version_file", structField = true, documented = false, doc = "Returns the file that is used to hold the volatile workspace status for the " + "current build request.") public Artifact getVolatileWorkspaceStatus() { |