ardielle / ardielle-java Goto Github PK
View Code? Open in Web Editor NEWLicense: Apache License 2.0
License: Apache License 2.0
.. which means suffering if someone tried to stick these into sets and map keys.
$ cat x.rdl
type Foo struct {
String bar;
String baz;
}
$ rdl -ps generate java-model x.rdl
produces
//
// This file generated by rdl 1.4.13. Do not modify!
//
import com.yahoo.rdl.*;
//
// Foo -
//
public class Foo {
public String bar;
public String baz;
public Foo bar(String bar) {
this.bar = bar;
return this;
}
public Foo baz(String baz) {
this.baz = baz;
return this;
}
@Override
public boolean equals(Object another) {
if (this != another) {
if (another == null || another.getClass() != Foo.class) {
return false;
}
Foo a = (Foo) another;
if (bar == null ? a.bar != null : !bar.equals(a.bar)) {
return false;
}
if (baz == null ? a.baz != null : !baz.equals(a.baz)) {
return false;
}
}
return true;
}
}
I have the following definition:
type Entity Struct {
EntityName name; //name of the entity object
Struct value; //value of the entity
}
Entity e = new Entity().setName("test.entity").setValue(new Struct().with("key", "test"));
result = validator.validate(e, "Entity");
I get back failure: Not a valid Struct, com.yahoo.rdl.Struct in data.value expected
If I have the following rdl:
type DomainTemplate Struct {
Array templateNames;
Array params (optional);
}
When validating this object against its schema, it only validates the templateNames array and just ignores params array. Quick look at the code shows that it returns the value of the first array validation rather than only returning if there is a failure and continuing with the other fields.
Hello,
I want to use RDL for writing a java webservice that accepts File input from user via POST call. i.e. support for Consuming MediaType.MULTIPART_FORM_DATA during post call. It seems that RDL currently supports only JSON data consumption. Is there a plan to add this feature?
Thanks,
Milan
Our oss license checker warns this library because rdl-java is not licensed, please add a license.
Needed if the name is actually set on the schema.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.