Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CLI support for functional API #243

Closed
jeromesimeon opened this issue Mar 19, 2021 · 1 comment
Closed

CLI support for functional API #243

jeromesimeon opened this issue Mar 19, 2021 · 1 comment
Assignees
Labels
Difficulty: Medium Type: Enhancement ✨ Improvement to process or efficiency

Comments

@jeromesimeon
Copy link
Member

Description

Since Concerto 1.0.0-alpha, we have two validation APIs:

  • "Object Style Validate": Type -> Data -> ValidatedData
  • The experimental "Functional Style Validate": Type -> Data -> Boolean

The CLI only supports the former. It might be useful for testing / experimentation / usability to offer an option on the command line which would use the Functional Style validation.

@jeromesimeon
Copy link
Member Author

Addressed in #246:

zsh-5.8$ more test.cto
namespace org.test

concept C identified by id {
        o String name
        o String id
}
zsh-5.8$ more test.json
{
    "$class": "org.test.C",
    "name": "John"
}
2:16:01 PM - INFO: Input is invalid
2:16:01 PM - ERROR: Instance org.test.C#undefined has an empty identifier.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Difficulty: Medium Type: Enhancement ✨ Improvement to process or efficiency
Projects
None yet
Development

No branches or pull requests

1 participant