autorest/Samples/test/hidden-methods
Garrett Serack d43c07052d work-in-progress 2019-01-28 10:34:19 -08:00
..
Client work-in-progress 2019-01-28 10:34:19 -08:00
ClientFancy work-in-progress 2019-01-28 10:34:19 -08:00
shell More info (#2801) 2018-01-12 16:59:57 -08:00
hidden-methods.yaml
readme.md Next gen stuff (WIP) (#2639) 2017-10-05 17:36:44 -07:00

readme.md

Hide certain methods from the end user

see https://aka.ms/autorest

input-file: hidden-methods.yaml
output-artifact: code-model-v1.yaml

Regular run

csharp:
  - output-folder: Client

Hide method

csharp:
  - output-folder: ClientFancy
    directive:
      from: code-model-v1
      where-operation: Cowbell_Add
      transform: $.hidden = true

The directive activates the hidden flag for method Cowbell_Add. As a result, the C# generator will mark associated methods as internal which can be useful to hide methods for which a convenience layer was provided.