Class WatchResponse.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<WatchResponse.Builder>
com.authzed.api.v1.WatchResponse.Builder
All Implemented Interfaces:
WatchResponseOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
WatchResponse

public static final class WatchResponse.Builder extends com.google.protobuf.GeneratedMessage.Builder<WatchResponse.Builder> implements WatchResponseOrBuilder
 WatchResponse contains all tuple modification events in ascending
 timestamp order, from the requested start snapshot to a snapshot
 encoded in the watch response. The client can use the snapshot to resume
 watching where the previous watch response left off.
 
Protobuf type authzed.api.v1.WatchResponse
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<WatchResponse.Builder>
    • clear

      public WatchResponse.Builder clear()
      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessage.Builder<WatchResponse.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<WatchResponse.Builder>
    • getDefaultInstanceForType

      public WatchResponse getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public WatchResponse build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public WatchResponse buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public WatchResponse.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<WatchResponse.Builder>
    • mergeFrom

      public WatchResponse.Builder mergeFrom(WatchResponse other)
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage.Builder<WatchResponse.Builder>
    • mergeFrom

      public WatchResponse.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<WatchResponse.Builder>
      Throws:
      IOException
    • getUpdatesList

      public List<RelationshipUpdate> getUpdatesList()
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
      Specified by:
      getUpdatesList in interface WatchResponseOrBuilder
    • getUpdatesCount

      public int getUpdatesCount()
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
      Specified by:
      getUpdatesCount in interface WatchResponseOrBuilder
    • getUpdates

      public RelationshipUpdate getUpdates(int index)
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
      Specified by:
      getUpdates in interface WatchResponseOrBuilder
    • setUpdates

      public WatchResponse.Builder setUpdates(int index, RelationshipUpdate value)
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
    • setUpdates

      public WatchResponse.Builder setUpdates(int index, RelationshipUpdate.Builder builderForValue)
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
    • addUpdates

      public WatchResponse.Builder addUpdates(RelationshipUpdate value)
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
    • addUpdates

      public WatchResponse.Builder addUpdates(int index, RelationshipUpdate value)
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
    • addUpdates

      public WatchResponse.Builder addUpdates(RelationshipUpdate.Builder builderForValue)
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
    • addUpdates

      public WatchResponse.Builder addUpdates(int index, RelationshipUpdate.Builder builderForValue)
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
    • addAllUpdates

      public WatchResponse.Builder addAllUpdates(Iterable<? extends RelationshipUpdate> values)
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
    • clearUpdates

      public WatchResponse.Builder clearUpdates()
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
    • removeUpdates

      public WatchResponse.Builder removeUpdates(int index)
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
    • getUpdatesBuilder

      public RelationshipUpdate.Builder getUpdatesBuilder(int index)
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
    • getUpdatesOrBuilder

      public RelationshipUpdateOrBuilder getUpdatesOrBuilder(int index)
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
      Specified by:
      getUpdatesOrBuilder in interface WatchResponseOrBuilder
    • getUpdatesOrBuilderList

      public List<? extends RelationshipUpdateOrBuilder> getUpdatesOrBuilderList()
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
      Specified by:
      getUpdatesOrBuilderList in interface WatchResponseOrBuilder
    • addUpdatesBuilder

      public RelationshipUpdate.Builder addUpdatesBuilder()
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
    • addUpdatesBuilder

      public RelationshipUpdate.Builder addUpdatesBuilder(int index)
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
    • getUpdatesBuilderList

      public List<RelationshipUpdate.Builder> getUpdatesBuilderList()
       updates are the RelationshipUpdate events that have occurred since the
       last watch response.
       
      repeated .authzed.api.v1.RelationshipUpdate updates = 1;
    • hasChangesThrough

      public boolean hasChangesThrough()
       changes_through is the ZedToken that represents the point in time
       that the watch response is current through. This token can be used
       in a subsequent WatchRequest to resume watching from this point.
       
      .authzed.api.v1.ZedToken changes_through = 2;
      Specified by:
      hasChangesThrough in interface WatchResponseOrBuilder
      Returns:
      Whether the changesThrough field is set.
    • getChangesThrough

      public ZedToken getChangesThrough()
       changes_through is the ZedToken that represents the point in time
       that the watch response is current through. This token can be used
       in a subsequent WatchRequest to resume watching from this point.
       
      .authzed.api.v1.ZedToken changes_through = 2;
      Specified by:
      getChangesThrough in interface WatchResponseOrBuilder
      Returns:
      The changesThrough.
    • setChangesThrough

      public WatchResponse.Builder setChangesThrough(ZedToken value)
       changes_through is the ZedToken that represents the point in time
       that the watch response is current through. This token can be used
       in a subsequent WatchRequest to resume watching from this point.
       
      .authzed.api.v1.ZedToken changes_through = 2;
    • setChangesThrough

      public WatchResponse.Builder setChangesThrough(ZedToken.Builder builderForValue)
       changes_through is the ZedToken that represents the point in time
       that the watch response is current through. This token can be used
       in a subsequent WatchRequest to resume watching from this point.
       
      .authzed.api.v1.ZedToken changes_through = 2;
    • mergeChangesThrough

      public WatchResponse.Builder mergeChangesThrough(ZedToken value)
       changes_through is the ZedToken that represents the point in time
       that the watch response is current through. This token can be used
       in a subsequent WatchRequest to resume watching from this point.
       
      .authzed.api.v1.ZedToken changes_through = 2;
    • clearChangesThrough

      public WatchResponse.Builder clearChangesThrough()
       changes_through is the ZedToken that represents the point in time
       that the watch response is current through. This token can be used
       in a subsequent WatchRequest to resume watching from this point.
       
      .authzed.api.v1.ZedToken changes_through = 2;
    • getChangesThroughBuilder

      public ZedToken.Builder getChangesThroughBuilder()
       changes_through is the ZedToken that represents the point in time
       that the watch response is current through. This token can be used
       in a subsequent WatchRequest to resume watching from this point.
       
      .authzed.api.v1.ZedToken changes_through = 2;
    • getChangesThroughOrBuilder

      public ZedTokenOrBuilder getChangesThroughOrBuilder()
       changes_through is the ZedToken that represents the point in time
       that the watch response is current through. This token can be used
       in a subsequent WatchRequest to resume watching from this point.
       
      .authzed.api.v1.ZedToken changes_through = 2;
      Specified by:
      getChangesThroughOrBuilder in interface WatchResponseOrBuilder
    • hasOptionalTransactionMetadata

      public boolean hasOptionalTransactionMetadata()
       optional_transaction_metadata is an optional field that returns the transaction metadata
       given to SpiceDB during the transaction that produced the changes in this response.
       This field may not exist if no transaction metadata was provided.
       
      .google.protobuf.Struct optional_transaction_metadata = 3;
      Specified by:
      hasOptionalTransactionMetadata in interface WatchResponseOrBuilder
      Returns:
      Whether the optionalTransactionMetadata field is set.
    • getOptionalTransactionMetadata

      public com.google.protobuf.Struct getOptionalTransactionMetadata()
       optional_transaction_metadata is an optional field that returns the transaction metadata
       given to SpiceDB during the transaction that produced the changes in this response.
       This field may not exist if no transaction metadata was provided.
       
      .google.protobuf.Struct optional_transaction_metadata = 3;
      Specified by:
      getOptionalTransactionMetadata in interface WatchResponseOrBuilder
      Returns:
      The optionalTransactionMetadata.
    • setOptionalTransactionMetadata

      public WatchResponse.Builder setOptionalTransactionMetadata(com.google.protobuf.Struct value)
       optional_transaction_metadata is an optional field that returns the transaction metadata
       given to SpiceDB during the transaction that produced the changes in this response.
       This field may not exist if no transaction metadata was provided.
       
      .google.protobuf.Struct optional_transaction_metadata = 3;
    • setOptionalTransactionMetadata

      public WatchResponse.Builder setOptionalTransactionMetadata(com.google.protobuf.Struct.Builder builderForValue)
       optional_transaction_metadata is an optional field that returns the transaction metadata
       given to SpiceDB during the transaction that produced the changes in this response.
       This field may not exist if no transaction metadata was provided.
       
      .google.protobuf.Struct optional_transaction_metadata = 3;
    • mergeOptionalTransactionMetadata

      public WatchResponse.Builder mergeOptionalTransactionMetadata(com.google.protobuf.Struct value)
       optional_transaction_metadata is an optional field that returns the transaction metadata
       given to SpiceDB during the transaction that produced the changes in this response.
       This field may not exist if no transaction metadata was provided.
       
      .google.protobuf.Struct optional_transaction_metadata = 3;
    • clearOptionalTransactionMetadata

      public WatchResponse.Builder clearOptionalTransactionMetadata()
       optional_transaction_metadata is an optional field that returns the transaction metadata
       given to SpiceDB during the transaction that produced the changes in this response.
       This field may not exist if no transaction metadata was provided.
       
      .google.protobuf.Struct optional_transaction_metadata = 3;
    • getOptionalTransactionMetadataBuilder

      public com.google.protobuf.Struct.Builder getOptionalTransactionMetadataBuilder()
       optional_transaction_metadata is an optional field that returns the transaction metadata
       given to SpiceDB during the transaction that produced the changes in this response.
       This field may not exist if no transaction metadata was provided.
       
      .google.protobuf.Struct optional_transaction_metadata = 3;
    • getOptionalTransactionMetadataOrBuilder

      public com.google.protobuf.StructOrBuilder getOptionalTransactionMetadataOrBuilder()
       optional_transaction_metadata is an optional field that returns the transaction metadata
       given to SpiceDB during the transaction that produced the changes in this response.
       This field may not exist if no transaction metadata was provided.
       
      .google.protobuf.Struct optional_transaction_metadata = 3;
      Specified by:
      getOptionalTransactionMetadataOrBuilder in interface WatchResponseOrBuilder