congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
SwaggerTypes
Code IndexAdd Tabnine to your IDE (free)

How to use
SwaggerTypes
in
org.restlet.ext.platform.internal.conversion.swagger.v1_2

Best Java code snippets using org.restlet.ext.platform.internal.conversion.swagger.v1_2.SwaggerTypes (Showing top 20 results out of 315)

origin: org.restlet.jse/org.restlet.ext.platform

/**
 * Converts a Swagger parameter to an instance of
 * {@link org.restlet.ext.platform.internal.model.PathVariable}.
 * 
 * @param parameter
 *            The Swagger parameter.
 * @return An instance of
 *         {@link org.restlet.ext.platform.internal.model.PathVariable}.
 */
private static PathVariable toPathVariable(
    ResourceOperationParameterDeclaration parameter) {
  PathVariable result = new PathVariable();
  result.setName(parameter.getName());
  result.setDescription(parameter.getDescription());
  result.setType(SwaggerTypes.toDefinitionType(new SwaggerTypeFormat(
      parameter.getType(), parameter.getFormat())));
  return result;
}
origin: org.restlet.jee/org.restlet.ext.platform

/**
 * Fills Swagger ResourceOperationDeclaration's
 * ResourceOperationParameterDeclaration from Restlet Web API definition's
 * Resource
 * 
 * @param resource
 *            The Restlet Web API definition's Resource
 * @param rod
 *            The Swagger Swagger ResourceOperationDeclaration
 */
private static void fillApiDeclarationPathVariables(Resource resource,
    ResourceOperationDeclaration rod) {
  // Get path variables
  ResourceOperationParameterDeclaration ropd;
  for (PathVariable pv : resource.getPathVariables()) {
    ropd = new ResourceOperationParameterDeclaration();
    ropd.setParamType("path");
    SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes.toSwaggerType(pv
        .getType());
    ropd.setType(swaggerTypeFormat.getType());
    ropd.setFormat(swaggerTypeFormat.getFormat());
    ropd.setRequired(true);
    ropd.setName(pv.getName());
    ropd.setAllowMultiple(false);
    ropd.setDescription(pv.getDescription());
    rod.getParameters().add(ropd);
  }
}
origin: org.restlet.osgi/org.restlet.ext.platform

/**
 * Fills Swagger ResourceOperationDeclaration's
 * ResourceOperationParameterDeclaration from Restlet Web API definition's
 * Resource
 * 
 * @param resource
 *            The Restlet Web API definition's Resource
 * @param rod
 *            The Swagger Swagger ResourceOperationDeclaration
 */
private static void fillApiDeclarationPathVariables(Resource resource,
    ResourceOperationDeclaration rod) {
  // Get path variables
  ResourceOperationParameterDeclaration ropd;
  for (PathVariable pv : resource.getPathVariables()) {
    ropd = new ResourceOperationParameterDeclaration();
    ropd.setParamType("path");
    SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes.toSwaggerType(pv
        .getType());
    ropd.setType(swaggerTypeFormat.getType());
    ropd.setFormat(swaggerTypeFormat.getFormat());
    ropd.setRequired(true);
    ropd.setName(pv.getName());
    ropd.setAllowMultiple(false);
    ropd.setDescription(pv.getDescription());
    rod.getParameters().add(ropd);
  }
}
origin: org.restlet.gae/org.restlet.ext.platform

/**
 * Converts a Swagger parameter to an instance of
 * {@link org.restlet.ext.platform.internal.model.PathVariable}.
 * 
 * @param parameter
 *            The Swagger parameter.
 * @return An instance of
 *         {@link org.restlet.ext.platform.internal.model.PathVariable}.
 */
private static PathVariable toPathVariable(
    ResourceOperationParameterDeclaration parameter) {
  PathVariable result = new PathVariable();
  result.setName(parameter.getName());
  result.setDescription(parameter.getDescription());
  result.setType(SwaggerTypes.toDefinitionType(new SwaggerTypeFormat(
      parameter.getType(), parameter.getFormat())));
  return result;
}
origin: org.restlet.jse/org.restlet.ext.platform

/**
 * Fills Swagger ResourceOperationDeclaration's
 * ResourceOperationParameterDeclaration from Restlet Web API definition's
 * Resource
 * 
 * @param resource
 *            The Restlet Web API definition's Resource
 * @param rod
 *            The Swagger Swagger ResourceOperationDeclaration
 */
private static void fillApiDeclarationPathVariables(Resource resource,
    ResourceOperationDeclaration rod) {
  // Get path variables
  ResourceOperationParameterDeclaration ropd;
  for (PathVariable pv : resource.getPathVariables()) {
    ropd = new ResourceOperationParameterDeclaration();
    ropd.setParamType("path");
    SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes.toSwaggerType(pv
        .getType());
    ropd.setType(swaggerTypeFormat.getType());
    ropd.setFormat(swaggerTypeFormat.getFormat());
    ropd.setRequired(true);
    ropd.setName(pv.getName());
    ropd.setAllowMultiple(false);
    ropd.setDescription(pv.getDescription());
    rod.getParameters().add(ropd);
  }
}
origin: org.restlet.osgi/org.restlet.ext.platform

/**
 * Converts a Swagger parameter to an instance of
 * {@link org.restlet.ext.platform.internal.model.PathVariable}.
 * 
 * @param parameter
 *            The Swagger parameter.
 * @return An instance of
 *         {@link org.restlet.ext.platform.internal.model.PathVariable}.
 */
private static PathVariable toPathVariable(
    ResourceOperationParameterDeclaration parameter) {
  PathVariable result = new PathVariable();
  result.setName(parameter.getName());
  result.setDescription(parameter.getDescription());
  result.setType(SwaggerTypes.toDefinitionType(new SwaggerTypeFormat(
      parameter.getType(), parameter.getFormat())));
  return result;
}
origin: org.restlet.gae/org.restlet.ext.platform

/**
 * Fills Swagger ResourceOperationDeclaration's
 * ResourceOperationParameterDeclaration from Restlet Web API definition's
 * Resource
 * 
 * @param resource
 *            The Restlet Web API definition's Resource
 * @param rod
 *            The Swagger Swagger ResourceOperationDeclaration
 */
private static void fillApiDeclarationPathVariables(Resource resource,
    ResourceOperationDeclaration rod) {
  // Get path variables
  ResourceOperationParameterDeclaration ropd;
  for (PathVariable pv : resource.getPathVariables()) {
    ropd = new ResourceOperationParameterDeclaration();
    ropd.setParamType("path");
    SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes.toSwaggerType(pv
        .getType());
    ropd.setType(swaggerTypeFormat.getType());
    ropd.setFormat(swaggerTypeFormat.getFormat());
    ropd.setRequired(true);
    ropd.setName(pv.getName());
    ropd.setAllowMultiple(false);
    ropd.setDescription(pv.getDescription());
    rod.getParameters().add(ropd);
  }
}
origin: org.restlet.jee/org.restlet.ext.platform

/**
 * Converts a Swagger parameter to an instance of
 * {@link org.restlet.ext.platform.internal.model.PathVariable}.
 * 
 * @param parameter
 *            The Swagger parameter.
 * @return An instance of
 *         {@link org.restlet.ext.platform.internal.model.PathVariable}.
 */
private static PathVariable toPathVariable(
    ResourceOperationParameterDeclaration parameter) {
  PathVariable result = new PathVariable();
  result.setName(parameter.getName());
  result.setDescription(parameter.getDescription());
  result.setType(SwaggerTypes.toDefinitionType(new SwaggerTypeFormat(
      parameter.getType(), parameter.getFormat())));
  return result;
}
origin: org.restlet.gae/org.restlet.ext.platform

/**
 * Fills Swagger ResourceOperationDeclaration's
 * ResourceOperationParameterDeclaration from Restlet Web API definition's
 * Operation
 * 
 * @param operation
 *            The Restlet Web API definition's Operation
 * @param rod
 *            The Swagger Swagger ResourceOperationDeclaration
 */
private static void fillApiDeclarationQueryParameters(Operation operation,
    ResourceOperationDeclaration rod) {
  // Get query parameters
  ResourceOperationParameterDeclaration ropd;
  for (QueryParameter qp : operation.getQueryParameters()) {
    ropd = new ResourceOperationParameterDeclaration();
    ropd.setParamType("query");
    SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes.toSwaggerType(qp
        .getType());
    ropd.setType(swaggerTypeFormat.getType());
    ropd.setFormat(swaggerTypeFormat.getFormat());
    ropd.setName(qp.getName());
    ropd.setAllowMultiple(true);
    ropd.setDescription(qp.getDescription());
    ropd.setEnum_(qp.getEnumeration());
    ropd.setDefaultValue(qp.getDefaultValue());
    ropd.setRequired(qp.isRequired());
    rod.getParameters().add(ropd);
  }
}
origin: org.restlet.jse/org.restlet.ext.platform

/**
 * Fills Swagger ResourceOperationDeclaration's
 * ResourceOperationParameterDeclaration from Restlet Web API definition's
 * Operation
 * 
 * @param operation
 *            The Restlet Web API definition's Operation
 * @param rod
 *            The Swagger Swagger ResourceOperationDeclaration
 */
private static void fillApiDeclarationQueryParameters(Operation operation,
    ResourceOperationDeclaration rod) {
  // Get query parameters
  ResourceOperationParameterDeclaration ropd;
  for (QueryParameter qp : operation.getQueryParameters()) {
    ropd = new ResourceOperationParameterDeclaration();
    ropd.setParamType("query");
    SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes.toSwaggerType(qp
        .getType());
    ropd.setType(swaggerTypeFormat.getType());
    ropd.setFormat(swaggerTypeFormat.getFormat());
    ropd.setName(qp.getName());
    ropd.setAllowMultiple(true);
    ropd.setDescription(qp.getDescription());
    ropd.setEnum_(qp.getEnumeration());
    ropd.setDefaultValue(qp.getDefaultValue());
    ropd.setRequired(qp.isRequired());
    rod.getParameters().add(ropd);
  }
}
origin: org.restlet.osgi/org.restlet.ext.platform

if (Types.isPrimitiveType(type)) {
  SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes
      .toSwaggerType(type);
  tpd.getItems().setType(swaggerTypeFormat.getType());
  tpd.getItems().setFormat(swaggerTypeFormat.getFormat());
if (Types.isPrimitiveType(type)) {
  SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes
      .toSwaggerType(type);
  tpd.setType(swaggerTypeFormat.getType());
  tpd.setFormat(swaggerTypeFormat.getFormat());
origin: org.restlet.osgi/org.restlet.ext.platform

if (Types.isPrimitiveType(itemsType)) {
  SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes
      .toSwaggerType(itemsType);
  items.setType(swaggerTypeFormat.getType());
  items.setFormat(swaggerTypeFormat.getFormat());
origin: org.restlet.jee/org.restlet.ext.platform

if (Types.isPrimitiveType(itemsType)) {
  SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes
      .toSwaggerType(itemsType);
  items.setType(swaggerTypeFormat.getType());
  items.setFormat(swaggerTypeFormat.getFormat());
origin: org.restlet.jee/org.restlet.ext.platform

if (Types.isPrimitiveType(type)) {
  SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes
      .toSwaggerType(type);
  tpd.getItems().setType(swaggerTypeFormat.getType());
  tpd.getItems().setFormat(swaggerTypeFormat.getFormat());
if (Types.isPrimitiveType(type)) {
  SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes
      .toSwaggerType(type);
  tpd.setType(swaggerTypeFormat.getType());
  tpd.setFormat(swaggerTypeFormat.getFormat());
origin: org.restlet.jse/org.restlet.ext.platform

if (Types.isPrimitiveType(type)) {
  SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes
      .toSwaggerType(type);
  tpd.getItems().setType(swaggerTypeFormat.getType());
  tpd.getItems().setFormat(swaggerTypeFormat.getFormat());
if (Types.isPrimitiveType(type)) {
  SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes
      .toSwaggerType(type);
  tpd.setType(swaggerTypeFormat.getType());
  tpd.setFormat(swaggerTypeFormat.getFormat());
origin: org.restlet.gae/org.restlet.ext.platform

if (Types.isPrimitiveType(type)) {
  SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes
      .toSwaggerType(type);
  tpd.getItems().setType(swaggerTypeFormat.getType());
  tpd.getItems().setFormat(swaggerTypeFormat.getFormat());
if (Types.isPrimitiveType(type)) {
  SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes
      .toSwaggerType(type);
  tpd.setType(swaggerTypeFormat.getType());
  tpd.setFormat(swaggerTypeFormat.getFormat());
origin: org.restlet.jee/org.restlet.ext.platform

/**
 * Fills Swagger ResourceOperationDeclaration's
 * ResourceOperationParameterDeclaration from Restlet Web API definition's
 * Operation
 * 
 * @param operation
 *            The Restlet Web API definition's Operation
 * @param rod
 *            The Swagger Swagger ResourceOperationDeclaration
 */
private static void fillApiDeclarationQueryParameters(Operation operation,
    ResourceOperationDeclaration rod) {
  // Get query parameters
  ResourceOperationParameterDeclaration ropd;
  for (QueryParameter qp : operation.getQueryParameters()) {
    ropd = new ResourceOperationParameterDeclaration();
    ropd.setParamType("query");
    SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes.toSwaggerType(qp
        .getType());
    ropd.setType(swaggerTypeFormat.getType());
    ropd.setFormat(swaggerTypeFormat.getFormat());
    ropd.setName(qp.getName());
    ropd.setAllowMultiple(true);
    ropd.setDescription(qp.getDescription());
    ropd.setEnum_(qp.getEnumeration());
    ropd.setDefaultValue(qp.getDefaultValue());
    ropd.setRequired(qp.isRequired());
    rod.getParameters().add(ropd);
  }
}
origin: org.restlet.osgi/org.restlet.ext.platform

/**
 * Fills Swagger ResourceOperationDeclaration's
 * ResourceOperationParameterDeclaration from Restlet Web API definition's
 * Operation
 * 
 * @param operation
 *            The Restlet Web API definition's Operation
 * @param rod
 *            The Swagger Swagger ResourceOperationDeclaration
 */
private static void fillApiDeclarationQueryParameters(Operation operation,
    ResourceOperationDeclaration rod) {
  // Get query parameters
  ResourceOperationParameterDeclaration ropd;
  for (QueryParameter qp : operation.getQueryParameters()) {
    ropd = new ResourceOperationParameterDeclaration();
    ropd.setParamType("query");
    SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes.toSwaggerType(qp
        .getType());
    ropd.setType(swaggerTypeFormat.getType());
    ropd.setFormat(swaggerTypeFormat.getFormat());
    ropd.setName(qp.getName());
    ropd.setAllowMultiple(true);
    ropd.setDescription(qp.getDescription());
    ropd.setEnum_(qp.getEnumeration());
    ropd.setDefaultValue(qp.getDefaultValue());
    ropd.setRequired(qp.isRequired());
    rod.getParameters().add(ropd);
  }
}
origin: org.restlet.jse/org.restlet.ext.platform

if (Types.isPrimitiveType(itemsType)) {
  SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes
      .toSwaggerType(itemsType);
  items.setType(swaggerTypeFormat.getType());
  items.setFormat(swaggerTypeFormat.getFormat());
origin: org.restlet.gae/org.restlet.ext.platform

if (Types.isPrimitiveType(itemsType)) {
  SwaggerTypeFormat swaggerTypeFormat = SwaggerTypes
      .toSwaggerType(itemsType);
  items.setType(swaggerTypeFormat.getType());
  items.setFormat(swaggerTypeFormat.getFormat());
org.restlet.ext.platform.internal.conversion.swagger.v1_2SwaggerTypes

Most used methods

  • toDefinitionType
    Converts Swagger types to Java types
  • toSwaggerType
    Converts Java types to Swagger types

Popular in Java

  • Reactive rest calls using spring rest template
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • getSystemService (Context)
  • getSupportFragmentManager (FragmentActivity)
  • DecimalFormat (java.text)
    A concrete subclass of NumberFormat that formats decimal numbers. It has a variety of features desig
  • Arrays (java.util)
    This class contains various methods for manipulating arrays (such as sorting and searching). This cl
  • HashSet (java.util)
    HashSet is an implementation of a Set. All optional operations (adding and removing) are supported.
  • Iterator (java.util)
    An iterator over a sequence of objects, such as a collection.If a collection has been changed since
  • Modifier (javassist)
    The Modifier class provides static methods and constants to decode class and member access modifiers
  • Scheduler (org.quartz)
    This is the main interface of a Quartz Scheduler. A Scheduler maintains a registry of org.quartz.Job
  • 21 Best Atom Packages for 2021
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now