com.linkedin.restli.restspec.RestMethodSchemaArray Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of restli-common Show documentation
Show all versions of restli-common Show documentation
Pegasus is a framework for building robust, scalable service architectures using dynamic discovery and simple asychronous type-checked REST + JSON APIs.
package com.linkedin.restli.restspec;
import java.util.Collection;
import java.util.List;
import javax.annotation.Generated;
import com.linkedin.data.DataList;
import com.linkedin.data.schema.ArrayDataSchema;
import com.linkedin.data.schema.PathSpec;
import com.linkedin.data.template.DataTemplateUtil;
import com.linkedin.data.template.WrappingArrayTemplate;
@Generated(value = "com.linkedin.pegasus.generator.JavaCodeUtil", comments = "Rest.li Data Template. Generated from /Users/mnchen/dev/pegasus_trunk/pegasus/restli-common/src/main/pegasus/com/linkedin/restli/restspec/CollectionSchema.pdsc.", date = "Tue Oct 03 15:15:24 PDT 2017")
public class RestMethodSchemaArray
extends WrappingArrayTemplate
{
private final static ArrayDataSchema SCHEMA = ((ArrayDataSchema) DataTemplateUtil.parseSchema("{\"type\":\"array\",\"items\":{\"type\":\"record\",\"name\":\"RestMethodSchema\",\"namespace\":\"com.linkedin.restli.restspec\",\"include\":[{\"type\":\"record\",\"name\":\"CustomAnnotationSchema\",\"doc\":\"Custom annotation for idl\",\"fields\":[{\"name\":\"annotations\",\"type\":{\"type\":\"map\",\"values\":{\"type\":\"record\",\"name\":\"CustomAnnotationContentSchema\",\"doc\":\"Unstructured record that represents arbitrary custom annotations for idl. Actual content is always a map with annotation's overridable member name as key and member value as value\",\"fields\":[]}},\"doc\":\"custom annotation data\",\"optional\":true}]}],\"fields\":[{\"name\":\"method\",\"type\":\"string\",\"doc\":\"Method type for this rest method\"},{\"name\":\"doc\",\"type\":\"string\",\"doc\":\"Documentation for this rest method\",\"optional\":true},{\"name\":\"parameters\",\"type\":{\"type\":\"array\",\"items\":{\"type\":\"record\",\"name\":\"ParameterSchema\",\"include\":[\"CustomAnnotationSchema\"],\"fields\":[{\"name\":\"name\",\"type\":\"string\",\"doc\":\"name of this parameter\"},{\"name\":\"type\",\"type\":\"string\",\"doc\":\"avro type of this parameter\"},{\"name\":\"items\",\"type\":\"string\",\"doc\":\"type of individual items, if this is an array parameter (used for finder parameters)\",\"optional\":true},{\"name\":\"optional\",\"type\":\"boolean\",\"doc\":\"indicates whether this parameter is optional. omitted for required parameters\",\"optional\":true},{\"name\":\"default\",\"type\":\"string\",\"doc\":\"indicates the default value for this parameter\",\"optional\":true},{\"name\":\"doc\",\"type\":\"string\",\"doc\":\"Documentation for this parameter\",\"optional\":true}]}},\"doc\":\"list of query parameters for this method\",\"optional\":true},{\"name\":\"metadata\",\"type\":{\"type\":\"record\",\"name\":\"MetadataSchema\",\"fields\":[{\"name\":\"type\",\"type\":\"string\",\"doc\":\"pegasus type of the metadata\"}]},\"doc\":\"Describes the collection level metadata returned by this method. This is usually set only for GET_ALL method type.\",\"optional\":true},{\"name\":\"pagingSupported\",\"type\":\"boolean\",\"doc\":\"Indicates if this rest method has paging support using the start and count parameters\",\"optional\":true}]}}"));
public RestMethodSchemaArray() {
this(new DataList());
}
public RestMethodSchemaArray(int initialCapacity) {
this(new DataList(initialCapacity));
}
public RestMethodSchemaArray(Collection c) {
this(new DataList(c.size()));
addAll(c);
}
public RestMethodSchemaArray(DataList data) {
super(data, SCHEMA, RestMethodSchema.class);
}
@Override
public RestMethodSchemaArray clone()
throws CloneNotSupportedException
{
return ((RestMethodSchemaArray) super.clone());
}
@Override
public RestMethodSchemaArray copy()
throws CloneNotSupportedException
{
return ((RestMethodSchemaArray) super.copy());
}
public static class Fields
extends PathSpec
{
public Fields(List path, String name) {
super(path, name);
}
public Fields() {
super();
}
public com.linkedin.restli.restspec.RestMethodSchema.Fields items() {
return new com.linkedin.restli.restspec.RestMethodSchema.Fields(getPathComponents(), PathSpec.WILDCARD);
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy