Examples of schema()


Examples of com.fasterxml.jackson.module.jsonSchema.annotation.Link.schema()

                    .setHref(pathStart + link.href())
                    .setRel(link.rel())
                    .setMethod(ignoreDefaults && "GET".equals(link.method()) ? null : link.method())
                    .setEnctype(ignoreDefaults && "application/json".equals(link.enctype()) ? null : link.enctype())
                    .setTargetSchema(fetchSchema(link.targetSchema()))
                    .setSchema(fetchSchema(link.schema()))
                    .setMediaType(ignoreDefaults && "application/json".equals(link.mediaType()) ? null : link.mediaType())
                    .setTitle(link.title());
            }
            SimpleTypeSchema simpleTypeSchema = schema.asSimpleTypeSchema();
            simpleTypeSchema.setLinks(linkDescriptionObjects);
View Full Code Here

Examples of com.foundationdb.qp.operator.StoreAdapter.schema()

            for(GroupIndex groupIndex : groupIndexes) {
                if(columnDifferences == null || groupIndex.columnsOverlap(table, columnDifferences)) {
                    StoreGIMaintenance plan = StoreGIMaintenancePlans
                            .forAis(table.getAIS())
                            .forRowType(groupIndex, adapter.schema().tableRowType(table));
                    plan.run(action, persistitHKey, rowData, adapter, handler);
                } else {
                    SKIP_GI_MAINTENANCE.hit();
                }
            }
View Full Code Here

Examples of com.linkedin.data.template.DoubleArray.schema()

    RecordDataSchema recordDataSchema = record.schema();

    DoubleArray doubleArray = new DoubleArray();
    record.setDoubleRefArray(doubleArray);
    doubleArray = record.getDoubleRefArray();
    assertEquals(doubleArray.schema(), DataTemplateUtil.getSchema(DoubleArray.class));
    assertNotEquals(recordDataSchema.getField("doubleRefArray").getType(), doubleArray.schema());

    IntegerArray intArray = new IntegerArray();
    record.setIntArray(intArray);
    intArray = record.getIntArray();
View Full Code Here

Examples of com.linkedin.data.template.DoubleMap.schema()

    RecordDataSchema recordDataSchema = record.schema();

    DoubleMap doubleMap = new DoubleMap();
    record.setDoubleRefMap(doubleMap);
    doubleMap = record.getDoubleRefMap();
    assertEquals(doubleMap.schema(), DataTemplateUtil.getSchema(DoubleMap.class));
    assertNotEquals(recordDataSchema.getField("doubleRefMap").getType(), doubleMap.schema());

    IntegerMap intMap = new IntegerMap();
    record.setIntMap(intMap);
    intMap = record.getIntMap();
View Full Code Here

Examples of com.linkedin.data.template.DynamicRecordTemplate.schema()

    {
      data = DataMapUtils.readMap(request);
    }
    DynamicRecordTemplate template = new DynamicRecordTemplate(data, resourceMethodDescriptor.getRequestDataSchema());
    ValidationResult result =
        ValidateDataAgainstSchema.validate(data, template.schema(), new ValidationOptions(RequiredMode.IGNORE,
                                                                                          CoercionMode.NORMAL));
    if (!result.isValid())
    {
      throw new RoutingException("Parameters of method '" + resourceMethodDescriptor.getActionName()
          + "' failed validation with error '" + result.getMessages() + "'", HttpStatus.S_400_BAD_REQUEST.getCode());
View Full Code Here

Examples of com.linkedin.data.template.IntegerArray.schema()

    assertNotEquals(recordDataSchema.getField("doubleRefArray").getType(), doubleArray.schema());

    IntegerArray intArray = new IntegerArray();
    record.setIntArray(intArray);
    intArray = record.getIntArray();
    assertEquals(intArray.schema(), DataTemplateUtil.getSchema(IntegerArray.class));
    assertNotEquals(recordDataSchema.getField("intArray").getType(), intArray.schema());

    record.setIntRefArray(intArray);
    intArray = record.getIntRefArray();
    assertEquals(intArray.schema(), DataTemplateUtil.getSchema(IntegerArray.class));
View Full Code Here

Examples of com.linkedin.data.template.IntegerMap.schema()

    assertNotEquals(recordDataSchema.getField("doubleRefMap").getType(), doubleMap.schema());

    IntegerMap intMap = new IntegerMap();
    record.setIntMap(intMap);
    intMap = record.getIntMap();
    assertEquals(intMap.schema(), DataTemplateUtil.getSchema(IntegerMap.class));
    assertNotEquals(recordDataSchema.getField("intMap").getType(), intMap.schema());

    record.setIntRefMap(intMap);
    intMap = record.getIntRefMap();
    assertEquals(intMap.schema(), DataTemplateUtil.getSchema(IntegerMap.class));
View Full Code Here

Examples of com.linkedin.data.template.RecordTemplate.schema()

  public static ComplexResourceKey<?, ?> fixUpComplexKeySingletonArray(ComplexResourceKey<?,?> complexResourceKey)
  {
    RecordTemplate key = complexResourceKey.getKey();
    DataMap dataMap = key.data();

    for (RecordDataSchema.Field f : key.schema().getFields())
    {
      DataSchema.Type type = f.getType().getType();
      String fieldName = f.getName();

      if (type == DataSchema.Type.ARRAY && dataMap.containsKey(fieldName))
View Full Code Here

Examples of com.linkedin.restli.examples.greetings.api.Greeting.schema()

      greeting.setTone(mapToneForIncomingRequest(tone));
    }
    greeting.setId(createdId);
    Request<Greeting> getRequest = builders.get().id(createdId).build();
    Greeting getReturnedGreeting = REST_CLIENT.sendRequest(getRequest).getResponse().getEntity();
    ValidateDataAgainstSchema.validate(getReturnedGreeting.data(), getReturnedGreeting.schema(),
                                       new ValidationOptions());
    assertEquals(getReturnedGreeting, greeting);
    deleteAndVerifyTestData(builders, createdId);
    verifyFilters(tone, responseFilter);
  }
View Full Code Here

Examples of hex.ModelBuilder.schema()

      int i = 0;
      for (Map.Entry<String, ModelBuilder> entry: m.model_builders.entrySet()) {
        ModelBuilder model_builder = entry.getValue();
        String algo = entry.getKey();
        this.model_builders.put(algo, model_builder.schema().fillFromImpl(entry.getValue()));
      }
    }
    return this;
  }
}
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.