aboutsummaryrefslogtreecommitdiffstats
path: root/config-model/src/test/derived/imported_struct_fields/child.sd
blob: c83eac6aa83f4c7bf7e25aa4e7d5246cf8636166 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
schema child {
  document child {
    field parent_ref type reference<parent> {
      indexing: attribute | summary
    }
  }
  import field parent_ref.elem_array as my_elem_array {}
  import field parent_ref.elem_map as my_elem_map {}
  import field parent_ref.str_int_map as my_str_int_map {}

  document-summary mysummary {
    summary documentid type string {}
    summary my_elem_array type array<elem> {}
    summary my_elem_map type map<string, elem> {}
    summary my_str_int_map type map<string, int> {}
  }

  document-summary filtered {
    summary elem_array_filtered type array<elem> {
      source: my_elem_array
      matched-elements-only
    }
    summary elem_map_filtered type map<string, elem> {
      source: my_elem_map
      matched-elements-only
    }
    summary str_int_map_filtered type map<string, int> {
      source: my_str_int_map
      matched-elements-only
    }
  }
}