Package com.linkedin.restli.examples.groups.api

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


  @Test(groups = {TestConstants.TESTNG_GROUP_KNOWN_ISSUE})
  void testRoundtripModifyEscapedField() throws Exception
  {
    Group g1 = new Group();
    g1.data().put("$foo", new DataMap());

    Group g2 = new Group(g1.data().copy());
    ((DataMap)g2.data().get("$foo")).put("bar", 42);
    PatchTree update = PatchCreator.diff(g1, g2);
    assertEquals(update.toString(), "{$$foo={$set={bar=42}}}");
View Full Code Here

  {
    Group g1 = new Group();
    g1.data().put("$foo", new DataMap());

    Group g2 = new Group(g1.data().copy());
    ((DataMap)g2.data().get("$foo")).put("bar", 42);
    PatchTree update = PatchCreator.diff(g1, g2);
    assertEquals(update.toString(), "{$$foo={$set={bar=42}}}");
    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.