Andy Bierman <a...@yumaworks.com> writes: > Back before there was YANG 1.0 I proposed the concept of constants in YANG > but this was seen as too complicated. This is the exact use-case I had in > mind. > The YANG module would #define the constants (maybe with a default or no > value) > and they could be used in statements. The vendors would set the constants at > build or maybe the operators can set them at module load-time.
The difficulty in the scenario we are discussing (I think) is that the list of valid values can be updated by the device, though presumably infrequently (e.g., when the software is updated). So the valid values aren't determined by the module itself. > #define SUPPORTED_COMPRESSION_METHODS > > must "compression-method ... SUPPORTED_COMPRESSION_METHODS"; I assume you can do this by writing the list of values directly in the Xpath expression. Not at all as nice, but at least it would work. Dale _______________________________________________ netmod mailing list netmod@ietf.org https://www.ietf.org/mailman/listinfo/netmod