Examples of edit()


Examples of com.google.gwt.editor.client.SimpleBeanEditorTest.PersonEditorWithDelegateDriver.edit()

  public void testDirtyWithDelegate() {
    PersonEditorWithDelegate editor = new PersonEditorWithDelegate();
    PersonEditorWithDelegateDriver driver = GWT.create(PersonEditorWithDelegateDriver.class);
    driver.initialize(editor);
    driver.edit(person);

    // Freshly-initialized should not be dirty
    assertFalse(driver.isDirty());

    // Use the delegate to toggle the state
View Full Code Here

Examples of com.google.gwt.editor.client.SimpleBeanEditorTest.PersonEditorWithOptionalAddressDriver.edit()

    PersonEditorWithOptionalAddressEditor editor =
        new PersonEditorWithOptionalAddressEditor(addressEditor);
    PersonEditorWithOptionalAddressDriver driver =
        GWT.create(PersonEditorWithOptionalAddressDriver.class);
    driver.initialize(editor);
    driver.edit(person);

    // Freshly-initialized should not be dirty
    assertFalse(driver.isDirty());

    // Change the instance being edited
View Full Code Here

Examples of com.google.gwt.sample.expenses.shared.ExpenseRequest.edit()

      }
    }

    // Create a delta and sync with the value store.
    ExpenseRequest editRequest = expensesRequestFactory.expenseRequest();
    ExpenseProxy editableRecord = editRequest.edit(record);
    editableRecord.setApproval(approval);
    editableRecord.setReasonDenied(reasonDenied);
    editRequest.persist().using(editableRecord).fire(new Receiver<Void>() {
      @Override
      public void onSuccess(Void ignore) {
View Full Code Here

Examples of com.google.gwt.sample.expenses.shared.ReportRequest.edit()

    // Switch to the pending view.
    setNotesEditState(false, true, pendingNotes);

    // Submit the delta.
    ReportRequest editRequest = expensesRequestFactory.reportRequest();
    ReportProxy editableReport = editRequest.edit(report);
    editableReport.setNotes(pendingNotes);
    editRequest.persist().using(editableReport).fire(new Receiver<Void>() {
      @Override
      public void onSuccess(Void ignore) {
      }
View Full Code Here

Examples of com.google.web.bindery.requestfactory.shared.RequestContext.edit()

  public void testMultipleEdits() {
    RequestContext c1 = req.simpleFooRequest();
    SimpleFooProxy proxy = c1.create(SimpleFooProxy.class);
    // Re-editing is idempotent
    assertSame(proxy, c1.edit(c1.edit(proxy)));

    // Should not allow "crossing the steams"
    RequestContext c2 = req.simpleFooRequest();
    try {
      c2.edit(proxy);
View Full Code Here

Examples of com.google.web.bindery.requestfactory.shared.SimpleBarRequest.edit()

        final EntityProxyId<SimpleBarProxy> id = response.stableId();

        // Make the entity behave as though it's been deleted
        SimpleBarRequest context = req.simpleBarRequest();
        Request<Void> persist = context.persist().using(response);
        context.edit(response).setFindFails(true);
        persist.fire(new Receiver<Void>() {

          @Override
          public void onSuccess(Void response) {
            // Now try fetching the deleted instance
View Full Code Here

Examples of com.google.web.bindery.requestfactory.shared.SimpleFooRequest.edit()

    final SimpleFooEventHandler<SimpleBarProxy> handler =
        new SimpleFooEventHandler<SimpleBarProxy>();
    EntityProxyChange.registerForProxyType(req.getEventBus(), SimpleBarProxy.class, handler);

    Request<SimpleFooProxy> request = context.persistCascadingAndReturnSelf().using(foo);
    SimpleFooProxy editFoo = context.edit(foo);
    editFoo.setOneToManyField(bars);
    editFoo.setSimpleBarKeyMap(barAsKeyMap);
    editFoo.setSimpleBarValueMap(barAsValueMap);

    request.fire(new Receiver<SimpleFooProxy>() {
View Full Code Here

Examples of com.googlecode.gwt.test.editors.AddressEditor.AddressDriver.edit()

      AddressEditor editor = new AddressEditor();
      AddressDriver driver = GWT.create(AddressDriver.class);
      driver.initialize(editor);

      // Test
      driver.edit(address);

      // Assert
      assertEquals("", editor.street().getValue());
      assertEquals("", editor.zipWithPathEditor().getValue());
      assertEquals("", editor.city.getValue());
View Full Code Here

Examples of com.googlecode.gwt.test.editors.PersonEditor.PersonDriver.edit()

      PersonEditor editor = new PersonEditor();
      PersonDriver driver = GWT.create(PersonDriver.class);
      driver.initialize(editor);

      // Test
      driver.edit(Person);

      // Assert
      assertEquals("", editor.firstName.getValue());
      assertEquals("", editor.lastName.getValue());
View Full Code Here

Examples of com.intel.mtwilson.as.controller.MwMleSourceJpaController.edit()

                if (mwMleSource == null) {
                    throw new ASException(ErrorCode.WS_MLE_SOURCE_MAPPING_DOES_NOT_EXIST, mleData.getName());
                }
               
                mwMleSource.setHostName(mleSourceObj.getHostName());       
                mleSourceJpaController.edit(mwMleSource);
               
            } catch (ASException ase) {
                    throw ase;
            } catch (Exception e) {
                throw new ASException(e);
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.