private void add(final EnumType.ValidValue value, final PrimitiveType encodingType)
    {
        final Encoding encoding = new Encoding.Builder()
            .byteOrder(schema.byteOrder())
            .primitiveType(encodingType)
            .constValue(value.primitiveValue())
            .build();

        final Token.Builder builder = new Token.Builder()
            .signal(Signal.VALID_VALUE)
            .name(value.name())
            .version(value.sinceVersion())
            .deprecated(value.deprecated())
            .description(value.description())
            .encoding(encoding);

        tokenList.add(builder.build());
    }
Generate a complete {@link uk.co.real_logic.sbe.ir.Ir} for a given schema.

@param schema from which the {@link uk.co.real_logic.sbe.ir.Ir} should be generated.
@return complete {@link uk.co.real_logic.sbe.ir.Ir} for a given schema.
sbe-tool/src/main/java/uk/co/real_logic/sbe/xml/IrGenerator.java