explain.proto 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. // Copyright 2022 Google LLC
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use this file except in compliance with the License.
  5. // You may obtain a copy of the License at
  6. //
  7. // http://www.apache.org/licenses/LICENSE-2.0
  8. //
  9. // Unless required by applicable law or agreed to in writing, software
  10. // distributed under the License is distributed on an "AS IS" BASIS,
  11. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. // See the License for the specific language governing permissions and
  13. // limitations under the License.
  14. syntax = "proto3";
  15. package google.api.expr.v1alpha1;
  16. import "google/api/expr/v1alpha1/value.proto";
  17. option cc_enable_arenas = true;
  18. option go_package = "google.golang.org/genproto/googleapis/api/expr/v1alpha1;expr";
  19. option java_multiple_files = true;
  20. option java_outer_classname = "ExplainProto";
  21. option java_package = "com.google.api.expr.v1alpha1";
  22. // Values of intermediate expressions produced when evaluating expression.
  23. // Deprecated, use `EvalState` instead.
  24. message Explain {
  25. option deprecated = true;
  26. // ID and value index of one step.
  27. message ExprStep {
  28. // ID of corresponding Expr node.
  29. int64 id = 1;
  30. // Index of the value in the values list.
  31. int32 value_index = 2;
  32. }
  33. // All of the observed values.
  34. //
  35. // The field value_index is an index in the values list.
  36. // Separating values from steps is needed to remove redundant values.
  37. repeated Value values = 1;
  38. // List of steps.
  39. //
  40. // Repeated evaluations of the same expression generate new ExprStep
  41. // instances. The order of such ExprStep instances matches the order of
  42. // elements returned by Comprehension.iter_range.
  43. repeated ExprStep expr_steps = 2;
  44. }