Skip to content

[Feature Request] Support fo boolean for properties #26

Description

@jim-bcom

PROBLEM
Currently when we want a property to be a boolean, we use an int type and a convention to code for boolean values.
This can create inconsistency if the convention change in different locations.

For example 0 means false, but do we allow only 1 as another value, or any int values other than zero means true?
Plus in the code this leads to things like if ( p == 0 ) which is less legible than if ( !p ), for example.

SUGGESTED SOLUTION
Accept strings as boolean and parse valid values?
This parser could accept values like (case insensitive): true/false, yes/no, 0/1, ...

<property name="myBoolPropName1" type="boolean" value="True"/>

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions