Class MutateInResult


  • public class MutateInResult
    extends MutationResult
    This result is returned from successful KeyValue subdocument mutation responses.
    Since:
    3.0.0
    • Method Detail

      • contentAs

        public <T> T contentAs​(int index,
                               Class<T> target)
        Decodes the content at the given index into the target class with the default decoder.
        Parameters:
        index - the index of the subdoc value to decode.
        target - the target type to decode into.
        Returns:
        the decoded content into the generic type requested.
      • contentAs

        public <T> T contentAs​(int index,
                               TypeRef<T> target)
        Decodes the content at the given index into an instance of the target type with the default decoder.
        Parameters:
        index - the index of the subdoc value to decode.
        target - the target type to decode into.
        Returns:
        the decoded content into the generic type requested.
      • contentAs

        public <T> T contentAs​(int index,
                               Class<T> target,
                               JsonSerializer serializer)
        Decodes the content at the given index into an instance of the target class with a custom decoder.
        Parameters:
        index - the index of the subdoc value to decode.
        target - the target type to decode into.
        serializer - the custom JsonSerializer that will be used.
        Returns:
        the decoded content into the generic type requested.
      • contentAs

        public <T> T contentAs​(int index,
                               TypeRef<T> target,
                               JsonSerializer serializer)
        Decodes the content at the given index into an instance of the target type with a custom decoder.
        Parameters:
        index - the index of the subdoc value to decode.
        target - the target type to decode into.
        serializer - the custom JsonSerializer that will be used.
        Returns:
        the decoded content into the generic type requested.