diff options
author | Jon Bratseth <bratseth@verizonmedia.com> | 2019-12-04 05:26:01 -0800 |
---|---|---|
committer | Jon Bratseth <bratseth@verizonmedia.com> | 2019-12-04 05:26:01 -0800 |
commit | e4bce25aba236f4c0a5929acce15da424ea674c4 (patch) | |
tree | 8ea4d1a4c2196802ca72ce5bef166a238a3b953e /vespajlib | |
parent | a71001d66ada9eaf4ae89d896fea60a39ea2056b (diff) |
Cleanup and update ABI spec
Diffstat (limited to 'vespajlib')
-rw-r--r-- | vespajlib/abi-spec.json | 19 | ||||
-rw-r--r-- | vespajlib/src/main/java/com/yahoo/tensor/functions/Generate.java | 2 | ||||
-rw-r--r-- | vespajlib/src/main/java/com/yahoo/tensor/functions/ToStringContext.java | 9 |
3 files changed, 25 insertions, 5 deletions
diff --git a/vespajlib/abi-spec.json b/vespajlib/abi-spec.json index 8aca75ac1be..63cae3904e3 100644 --- a/vespajlib/abi-spec.json +++ b/vespajlib/abi-spec.json @@ -2495,6 +2495,21 @@ ], "fields": [] }, + "com.yahoo.tensor.functions.ToStringContext$EmptyStringContext": { + "superClass": "java.lang.Object", + "interfaces": [ + "com.yahoo.tensor.functions.ToStringContext" + ], + "attributes": [ + "public" + ], + "methods": [ + "public void <init>()", + "public java.lang.String getBinding(java.lang.String)", + "public com.yahoo.tensor.functions.ToStringContext parent()" + ], + "fields": [] + }, "com.yahoo.tensor.functions.ToStringContext": { "superClass": "java.lang.Object", "interfaces": [], @@ -2504,7 +2519,9 @@ "abstract" ], "methods": [ - "public static com.yahoo.tensor.functions.ToStringContext empty()" + "public static com.yahoo.tensor.functions.ToStringContext empty()", + "public abstract java.lang.String getBinding(java.lang.String)", + "public abstract com.yahoo.tensor.functions.ToStringContext parent()" ], "fields": [] }, diff --git a/vespajlib/src/main/java/com/yahoo/tensor/functions/Generate.java b/vespajlib/src/main/java/com/yahoo/tensor/functions/Generate.java index ac6621ce78b..fa3d70a4ddf 100644 --- a/vespajlib/src/main/java/com/yahoo/tensor/functions/Generate.java +++ b/vespajlib/src/main/java/com/yahoo/tensor/functions/Generate.java @@ -190,7 +190,7 @@ public class Generate<NAMETYPE extends Name> extends PrimitiveTensorFunction<NAM } @Override - public ToStringContext wrapped() { return context; } + public ToStringContext parent() { return context; } } diff --git a/vespajlib/src/main/java/com/yahoo/tensor/functions/ToStringContext.java b/vespajlib/src/main/java/com/yahoo/tensor/functions/ToStringContext.java index c09631d36d7..634ba4fe6ab 100644 --- a/vespajlib/src/main/java/com/yahoo/tensor/functions/ToStringContext.java +++ b/vespajlib/src/main/java/com/yahoo/tensor/functions/ToStringContext.java @@ -13,8 +13,11 @@ public interface ToStringContext { /** Returns the name an identifier is bound to, or null if not bound in this context */ String getBinding(String name); - /** Returns another context this wraps, or null if none is wrapped */ - ToStringContext wrapped(); + /** + * Returns the parent context of this (the context we're in scope of when this is created), + * or null if this is the root. + */ + ToStringContext parent(); class EmptyStringContext implements ToStringContext { @@ -22,7 +25,7 @@ public interface ToStringContext { public String getBinding(String name) { return null; } @Override - public ToStringContext wrapped() { return null; } + public ToStringContext parent() { return null; } } |