Examples of data()


Examples of com.jagpdf.ImageDef.data()

                checker_bytes[i] = 0;
            else
                checker_bytes[i] = (byte)255;
        }
        ImageDef imgdef = doc.image_definition();
        imgdef.data(checker_bytes, img_dim * img_dim);
        imgdef.dimensions(img_dim, img_dim);
        imgdef.color_space(ColorSpaceType.CS_DEVICE_GRAY);
        imgdef.bits_per_component(8);
        imgdef.dpi(9, 9);
        imgdef.format(ImageFormat.IMAGE_FORMAT_NATIVE);
View Full Code Here

Examples of com.linkedin.data.template.DataTemplate.data()

    }
    else if (param instanceof DataTemplate)
    {
      @SuppressWarnings("rawtypes")
      final DataTemplate dataTemplate = (DataTemplate)param;
      return dataTemplate.data();
    }
    else if (param instanceof DataComplex)
    {
      return param;
    }
View Full Code Here

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

  public Object[] buildArguments(RestLiRequestData requestData, RoutingResult routingResult)
  {
    ResourceMethodDescriptor resourceMethodDescriptor = routingResult.getResourceMethod();
    List<Parameter<?>> parameters = resourceMethodDescriptor.getParameters();
    DynamicRecordTemplate template = (DynamicRecordTemplate) requestData.getEntity();
    DataMap data = template.data();
    Object[] arguments = new Object[parameters.size()];
    int i = 0;
    for (Parameter<?> param : parameters)
    {
      Object value;
View Full Code Here

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

          assertTrue(requestContext.getFilterScratchpad().get(spKey) == spValue);
          RecordTemplate entity = responseContext.getResponseData().getEntityResponse();
          if (entity != null && requestContext.getMethodType() == ResourceMethod.GET
              && responseContext.getHttpStatus() == HttpStatus.S_200_OK)
          {
            Greeting greeting = new Greeting(entity.data());
            if (greeting.hasTone())
            {
              greeting.setTone(mapToneForOutgoingResponse(greeting.getTone()));
              responseContext.getResponseData().setEntityResponse(greeting);
            }
View Full Code Here

Examples of com.linkedin.pegasus.generator.examples.Foo.data()

    CollectionResult<Foo, Foo> collectionResult = new CollectionResult<Foo, Foo>(generatedList, generatedList.size(), metadata);

    return new Object[][]
        {
            {generatedList, null},
            {collectionResult, metadata.data()},
        };
  }

  @SuppressWarnings("unchecked")
  @Test(dataProvider = "testData")
View Full Code Here

Examples of com.linkedin.restli.client.test.TestRecord.data()

    final TestRecord record = new TestRecord().setId(id);

    byte[] mapBytes;
    try
    {
      mapBytes = new JacksonDataCodec().mapToBytes(record.data());
    }
    catch (final IOException e)
    {
      throw new RuntimeException(e);
    }
View Full Code Here

Examples of com.linkedin.restli.common.CollectionMetadata.data()

    //see the lack of total in their paging path spec and then decide to set total to null. We will then also exclude it
    //when we project paging.
    //If the client decides they want total in their paging response, then the resource method will see total in their
    //paging path spec and then decide to set total to a non null value. We will then also include it when we project
    //paging.
    final RecordTemplate anyRecord = new AnyRecord(RestUtils.projectFields(paging.data(),
        ProjectionMode.AUTOMATIC, resourceContext.getPagingProjectionMask()));
    final CollectionMetadata projectedPaging = new CollectionMetadata(anyRecord.data());

    //For root object entities
    List<AnyRecord> processedElements = new ArrayList<AnyRecord>(elements.size());
View Full Code Here

Examples of com.linkedin.restli.common.ErrorResponse.data()

    er.setServiceErrorCode(appCode);

    final byte[] mapBytes;
    try
    {
      mapBytes = new JacksonDataCodec().mapToBytes(er.data());
    }
    catch (final IOException e)
    {
      throw new RuntimeException(e);
    }
View Full Code Here

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

      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 com.linkedin.restli.examples.groups.api.Group.data()

    Group g1 = new Group();
    g1.setId(17);
    g1.setDescription("Some description");

    Group g2 = new Group(g1.data().copy());
    g2.data().put("$foo", "value");
    PatchTree update = PatchCreator.diff(g1, g2);
    assertEquals(update.toString(), "{$set={$foo=value}}");
    assertFalse(g1.equals(g2));

    DataComplexProcessor processor = new DataComplexProcessor(new Patch(), update.getDataMap(), g1.data());
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.