content: package im.actor.core.api.updates;
  /*
   *  Generated by the Actor API Scheme generator.  DO NOT EDIT!
   */
  
  import im.actor.runtime.bser.*;
  import im.actor.runtime.collections.*;
  import static im.actor.runtime.bser.Utils.*;
  import im.actor.core.network.parser.*;
  import org.jetbrains.annotations.Nullable;
  import org.jetbrains.annotations.NotNull;
  import com.google.j2objc.annotations.ObjectiveCName;
  import java.io.IOException;
  import java.util.List;
  import java.util.ArrayList;
  import im.actor.core.api.*;
  
  public class UpdateSyncedSetAddedOrUpdated extends Update {
  
      public static final int HEADER = 0x49;
      public static UpdateSyncedSetAddedOrUpdated fromBytes(byte[] data) throws IOException {
          return Bser.parse(new UpdateSyncedSetAddedOrUpdated(), data);
      }
  
      private String setName;
      private List<ApiSyncedValue> addedOrUpdatedValues;
  
      public UpdateSyncedSetAddedOrUpdated(@NotNull String setName, @NotNull List<ApiSyncedValue> addedOrUpdatedValues) {
          this.setName = setName;
          this.addedOrUpdatedValues = addedOrUpdatedValues;
      }
  
      public UpdateSyncedSetAddedOrUpdated() {
  
      }
  
      @NotNull
      public String getSetName() {
          return this.setName;
      }
  
      @NotNull
      public List<ApiSyncedValue> getAddedOrUpdatedValues() {
          return this.addedOrUpdatedValues;
      }
  
      @Override
      public void parse(BserValues values) throws IOException {
          this.setName = values.getString(1);
          List<ApiSyncedValue> _addedOrUpdatedValues = new ArrayList<ApiSyncedValue>();
          for (int i = 0; i < values.getRepeatedCount(2); i ++) {
              _addedOrUpdatedValues.add(new ApiSyncedValue());
          }
          this.addedOrUpdatedValues = values.getRepeatedObj(2, _addedOrUpdatedValues);
      }
  
      @Override
      public void serialize(BserWriter writer) throws IOException {
          if (this.setName == null) {
              throw new IOException();
          }
          writer.writeString(1, this.setName);
          writer.writeRepeatedObj(2, this.addedOrUpdatedValues);
      }
  
      @Override
      public String toString() {
          String res = "update SyncedSetAddedOrUpdated{";
          res += "setName=" + this.setName;
          res += "}";
          return res;
      }
  
      @Override
      public int getHeaderKey() {
          return HEADER;
      }
  }
  